Skip to content

[Lens] Keep suggestions up to date with the main workspace#221901

Merged
dej611 merged 5 commits intoelastic:mainfrom
dej611:fix/178571
May 30, 2025
Merged

[Lens] Keep suggestions up to date with the main workspace#221901
dej611 merged 5 commits intoelastic:mainfrom
dej611:fix/178571

Conversation

@dej611
Copy link
Contributor

@dej611 dej611 commented May 29, 2025

Summary

Fixes #178571

This PR reverts #221248 adding the missing part on it to make the bug found in #178571 disappear.
In fact there was just a single line missing who was meant to keep the suggestion frame version up to date with the latest workspace state.

lens_suggestion_bug_fix

I've tried to add a unit test but it was so hard to actually follow the code underneath, so I settled to add a FTR, which led to few more extras:

  • subtype selector now has test ids
  • Lens page now has few more utility helpers for layer cloning and sub type selector

Checklist

@dej611 dej611 requested a review from a team as a code owner May 29, 2025 10:25
@dej611 dej611 added Team:Visualizations Team label for Lens, elastic-charts, Graph, legacy editors (TSVB, Visualize, Timelion) t// release_note:skip Skip the PR/issue when compiling release notes Feature:Lens backport:version Backport to applied version labels v9.1.0 v8.19.0 labels May 29, 2025
@elasticmachine
Copy link
Contributor

Pinging @elastic/kibana-visualizations (Team:Visualizations)

@elasticmachine
Copy link
Contributor

💚 Build Succeeded

Metrics [docs]

Async chunks

Total size of all lazy-loaded chunks that will be downloaded as the user navigates the app

id before after diff
lens 1.5MB 1.5MB +580.0B

@dej611 dej611 self-assigned this May 30, 2025
@dej611 dej611 merged commit 0bcd7ff into elastic:main May 30, 2025
24 checks passed
@kibanamachine
Copy link
Contributor

Starting backport for target branches: 8.19

https://github.com/elastic/kibana/actions/runs/15348726377

@kibanamachine
Copy link
Contributor

💔 All backports failed

Status Branch Result
8.19 Backport failed because of merge conflicts

Manual backport

To create the backport manually run:

node scripts/backport --pr 221901

Questions ?

Please refer to the Backport tool documentation

@kibanamachine kibanamachine added the backport missing Added to PRs automatically when the are determined to be missing a backport. label Jun 3, 2025
@kibanamachine
Copy link
Contributor

Friendly reminder: Looks like this PR hasn’t been backported yet.
To create automatically backports add a backport:* label or prevent reminders by adding the backport:skip label.
You can also create backports manually by running node scripts/backport --pr 221901 locally
cc: @dej611

dej611 added a commit to dej611/kibana that referenced this pull request Jun 3, 2025
…21901)

## Summary

Fixes elastic#178571

This PR reverts elastic#221248 adding the missing part on it to make the bug
found in elastic#178571 disappear.
In fact there was just a single line missing who was meant to keep the
suggestion frame version up to date with the latest workspace state.

![lens_suggestion_bug_fix](https://github.com/user-attachments/assets/ff59e4d6-cfac-4801-857a-a79b1c98762d)

I've tried to add a unit test but it was so hard to actually follow the
code underneath, so I settled to add a FTR, which led to few more
extras:

* subtype selector now has test ids
* Lens page now has few more utility helpers for layer cloning and sub
type selector

### Checklist

- [x] [Unit or functional
tests](https://www.elastic.co/guide/en/kibana/master/development-tests.html)
were updated or added to match the most common scenarios

(cherry picked from commit 0bcd7ff)

# Conflicts:
#	x-pack/test/functional/page_objects/lens_page.ts
@dej611
Copy link
Contributor Author

dej611 commented Jun 3, 2025

💚 All backports created successfully

Status Branch Result
8.19

Note: Successful backport PRs will be merged automatically after passing CI.

Questions ?

Please refer to the Backport tool documentation

dej611 added a commit that referenced this pull request Jun 3, 2025
…21901) (#222380)

# Backport

This will backport the following commits from `main` to `8.19`:
- [[Lens] Keep suggestions up to date with the main workspace
(#221901)](#221901)

<!--- Backport version: 10.0.0 -->

### Questions ?
Please refer to the [Backport tool
documentation](https://github.com/sorenlouv/backport)

<!--BACKPORT [{"author":{"name":"Marco
Liberati","email":"dej611@users.noreply.github.com"},"sourceCommit":{"committedDate":"2025-05-30T14:14:32Z","message":"[Lens]
Keep suggestions up to date with the main workspace (#221901)\n\n##
Summary\n\nFixes #178571 \n\nThis PR reverts #221248 adding the missing
part on it to make the bug\nfound in #178571 disappear.\nIn fact there
was just a single line missing who was meant to keep the\nsuggestion
frame version up to date with the latest workspace
state.\n\n\n![lens_suggestion_bug_fix](https://github.com/user-attachments/assets/ff59e4d6-cfac-4801-857a-a79b1c98762d)\n\nI've
tried to add a unit test but it was so hard to actually follow the\ncode
underneath, so I settled to add a FTR, which led to few
more\nextras:\n\n* subtype selector now has test ids\n* Lens page now
has few more utility helpers for layer cloning and sub\ntype
selector\n\n### Checklist\n\n- [x] [Unit or
functional\ntests](https://www.elastic.co/guide/en/kibana/master/development-tests.html)\nwere
updated or added to match the most common
scenarios","sha":"0bcd7ffcddb706da6407337ad3e3e85e0713fb13","branchLabelMapping":{"^v9.1.0$":"main","^v(\\d+).(\\d+).\\d+$":"$1.$2"}},"sourcePullRequest":{"labels":["Team:Visualizations","release_note:skip","Feature:Lens","backport
missing","backport:version","v9.1.0","v8.19.0"],"title":"[Lens] Keep
suggestions up to date with the main
workspace","number":221901,"url":"https://github.com/elastic/kibana/pull/221901","mergeCommit":{"message":"[Lens]
Keep suggestions up to date with the main workspace (#221901)\n\n##
Summary\n\nFixes #178571 \n\nThis PR reverts #221248 adding the missing
part on it to make the bug\nfound in #178571 disappear.\nIn fact there
was just a single line missing who was meant to keep the\nsuggestion
frame version up to date with the latest workspace
state.\n\n\n![lens_suggestion_bug_fix](https://github.com/user-attachments/assets/ff59e4d6-cfac-4801-857a-a79b1c98762d)\n\nI've
tried to add a unit test but it was so hard to actually follow the\ncode
underneath, so I settled to add a FTR, which led to few
more\nextras:\n\n* subtype selector now has test ids\n* Lens page now
has few more utility helpers for layer cloning and sub\ntype
selector\n\n### Checklist\n\n- [x] [Unit or
functional\ntests](https://www.elastic.co/guide/en/kibana/master/development-tests.html)\nwere
updated or added to match the most common
scenarios","sha":"0bcd7ffcddb706da6407337ad3e3e85e0713fb13"}},"sourceBranch":"main","suggestedTargetBranches":["8.19"],"targetPullRequestStates":[{"branch":"main","label":"v9.1.0","branchLabelMappingKey":"^v9.1.0$","isSourceBranch":true,"state":"MERGED","url":"https://github.com/elastic/kibana/pull/221901","number":221901,"mergeCommit":{"message":"[Lens]
Keep suggestions up to date with the main workspace (#221901)\n\n##
Summary\n\nFixes #178571 \n\nThis PR reverts #221248 adding the missing
part on it to make the bug\nfound in #178571 disappear.\nIn fact there
was just a single line missing who was meant to keep the\nsuggestion
frame version up to date with the latest workspace
state.\n\n\n![lens_suggestion_bug_fix](https://github.com/user-attachments/assets/ff59e4d6-cfac-4801-857a-a79b1c98762d)\n\nI've
tried to add a unit test but it was so hard to actually follow the\ncode
underneath, so I settled to add a FTR, which led to few
more\nextras:\n\n* subtype selector now has test ids\n* Lens page now
has few more utility helpers for layer cloning and sub\ntype
selector\n\n### Checklist\n\n- [x] [Unit or
functional\ntests](https://www.elastic.co/guide/en/kibana/master/development-tests.html)\nwere
updated or added to match the most common
scenarios","sha":"0bcd7ffcddb706da6407337ad3e3e85e0713fb13"}},{"branch":"8.19","label":"v8.19.0","branchLabelMappingKey":"^v(\\d+).(\\d+).\\d+$","isSourceBranch":false,"state":"NOT_CREATED"}]}]
BACKPORT-->
@kibanamachine kibanamachine removed the backport missing Added to PRs automatically when the are determined to be missing a backport. label Jun 3, 2025
zacharyparikh pushed a commit to zacharyparikh/kibana that referenced this pull request Jun 4, 2025
…21901)

## Summary

Fixes elastic#178571 

This PR reverts elastic#221248 adding the missing part on it to make the bug
found in elastic#178571 disappear.
In fact there was just a single line missing who was meant to keep the
suggestion frame version up to date with the latest workspace state.


![lens_suggestion_bug_fix](https://github.com/user-attachments/assets/ff59e4d6-cfac-4801-857a-a79b1c98762d)

I've tried to add a unit test but it was so hard to actually follow the
code underneath, so I settled to add a FTR, which led to few more
extras:

* subtype selector now has test ids
* Lens page now has few more utility helpers for layer cloning and sub
type selector

### Checklist

- [x] [Unit or functional
tests](https://www.elastic.co/guide/en/kibana/master/development-tests.html)
were updated or added to match the most common scenarios
nickpeihl pushed a commit to nickpeihl/kibana that referenced this pull request Jun 12, 2025
…21901)

## Summary

Fixes elastic#178571 

This PR reverts elastic#221248 adding the missing part on it to make the bug
found in elastic#178571 disappear.
In fact there was just a single line missing who was meant to keep the
suggestion frame version up to date with the latest workspace state.


![lens_suggestion_bug_fix](https://github.com/user-attachments/assets/ff59e4d6-cfac-4801-857a-a79b1c98762d)

I've tried to add a unit test but it was so hard to actually follow the
code underneath, so I settled to add a FTR, which led to few more
extras:

* subtype selector now has test ids
* Lens page now has few more utility helpers for layer cloning and sub
type selector

### Checklist

- [x] [Unit or functional
tests](https://www.elastic.co/guide/en/kibana/master/development-tests.html)
were updated or added to match the most common scenarios
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

backport:version Backport to applied version labels Feature:Lens release_note:skip Skip the PR/issue when compiling release notes Team:Visualizations Team label for Lens, elastic-charts, Graph, legacy editors (TSVB, Visualize, Timelion) t// v8.19.0 v9.1.0

Projects

None yet

Development

Successfully merging this pull request may close these issues.

[Lens] Suggestions current visualization synchronizes one action behind

4 participants