[Upgrade Assistant] Fix uniq keys bug in ES deprecations table#227416
[Upgrade Assistant] Fix uniq keys bug in ES deprecations table#227416sabarasaba merged 4 commits intoelastic:mainfrom
Conversation
|
Pinging @elastic/kibana-management (Team:Kibana Management) |
damian-polewski
left a comment
There was a problem hiding this comment.
Tested locally and everything works as expected, LGTM!
|
@elasticmachine merge upstream |
|
Starting backport for target branches: 8.18, 8.19 |
💛 Build succeeded, but was flaky
Failed CI StepsTest Failures
Metrics [docs]Async chunks
History
cc @sabarasaba |
…ic#227416) (cherry picked from commit 769404b)
💔 Some backports could not be created
Note: Successful backport PRs will be merged automatically after passing CI. Manual backportTo create the backport manually run: Questions ?Please refer to the Backport tool documentation |
💚 All backports created successfully
Note: Successful backport PRs will be merged automatically after passing CI. Questions ?Please refer to the Backport tool documentation |
…ic#227416) (cherry picked from commit 769404b) # Conflicts: # x-pack/platform/plugins/private/upgrade_assistant/public/application/components/es_deprecations/es_deprecations_table.tsx
…#227416) (#227802) # Backport This will backport the following commits from `main` to `8.19`: - [[Upgrade Assistant] Fix uniq keys bug in ES deprecations table (#227416)](#227416) <!--- Backport version: 9.6.6 --> ### Questions ? Please refer to the [Backport tool documentation](https://github.com/sorenlouv/backport) <!--BACKPORT [{"author":{"name":"Ignacio Rivas","email":"rivasign@gmail.com"},"sourceCommit":{"committedDate":"2025-07-14T11:37:22Z","message":"[Upgrade Assistant] Fix uniq keys bug in ES deprecations table (#227416)","sha":"769404bd4ac35f1d38b6b2bf8dc0f56a43cb4533","branchLabelMapping":{"^v9.2.0$":"main","^v(\\d+).(\\d+).\\d+$":"$1.$2"}},"sourcePullRequest":{"labels":["Team:Kibana Management","release_note:skip","Feature:Upgrade Assistant","backport:version","v8.19.0","v9.2.0","v8.18.4"],"title":"[Upgrade Assistant] Fix uniq keys bug in ES deprecations table","number":227416,"url":"https://github.com/elastic/kibana/pull/227416","mergeCommit":{"message":"[Upgrade Assistant] Fix uniq keys bug in ES deprecations table (#227416)","sha":"769404bd4ac35f1d38b6b2bf8dc0f56a43cb4533"}},"sourceBranch":"main","suggestedTargetBranches":["8.19","8.18"],"targetPullRequestStates":[{"branch":"8.19","label":"v8.19.0","branchLabelMappingKey":"^v(\\d+).(\\d+).\\d+$","isSourceBranch":false,"state":"NOT_CREATED"},{"branch":"main","label":"v9.2.0","branchLabelMappingKey":"^v9.2.0$","isSourceBranch":true,"state":"MERGED","url":"https://github.com/elastic/kibana/pull/227416","number":227416,"mergeCommit":{"message":"[Upgrade Assistant] Fix uniq keys bug in ES deprecations table (#227416)","sha":"769404bd4ac35f1d38b6b2bf8dc0f56a43cb4533"}},{"branch":"8.18","label":"v8.18.4","branchLabelMappingKey":"^v(\\d+).(\\d+).\\d+$","isSourceBranch":false,"state":"NOT_CREATED"}]}] BACKPORT--> Co-authored-by: Ignacio Rivas <rivasign@gmail.com>
|
Looks like this PR has backport PRs but they still haven't been merged. Please merge them ASAP to keep the branches relatively in sync. |
|
Looks like this PR has backport PRs but they still haven't been merged. Please merge them ASAP to keep the branches relatively in sync. |
…#227416) (#227806) # Backport This will backport the following commits from `main` to `8.18`: - [[Upgrade Assistant] Fix uniq keys bug in ES deprecations table (#227416)](#227416) <!--- Backport version: 10.0.1 --> ### Questions ? Please refer to the [Backport tool documentation](https://github.com/sorenlouv/backport) <!--BACKPORT [{"author":{"name":"Ignacio Rivas","email":"rivasign@gmail.com"},"sourceCommit":{"committedDate":"2025-07-14T11:37:22Z","message":"[Upgrade Assistant] Fix uniq keys bug in ES deprecations table (#227416)","sha":"769404bd4ac35f1d38b6b2bf8dc0f56a43cb4533","branchLabelMapping":{"^v9.2.0$":"main","^v(\\d+).(\\d+).\\d+$":"$1.$2"}},"sourcePullRequest":{"labels":["Team:Kibana Management","release_note:skip","Feature:Upgrade Assistant","backport:version","v8.19.0","v9.2.0","v8.18.4"],"title":"[Upgrade Assistant] Fix uniq keys bug in ES deprecations table","number":227416,"url":"https://github.com/elastic/kibana/pull/227416","mergeCommit":{"message":"[Upgrade Assistant] Fix uniq keys bug in ES deprecations table (#227416)","sha":"769404bd4ac35f1d38b6b2bf8dc0f56a43cb4533"}},"sourceBranch":"main","suggestedTargetBranches":["8.18"],"targetPullRequestStates":[{"branch":"8.19","label":"v8.19.0","branchLabelMappingKey":"^v(\\d+).(\\d+).\\d+$","isSourceBranch":false,"url":"https://github.com/elastic/kibana/pull/227802","number":227802,"state":"OPEN"},{"branch":"main","label":"v9.2.0","branchLabelMappingKey":"^v9.2.0$","isSourceBranch":true,"state":"MERGED","url":"https://github.com/elastic/kibana/pull/227416","number":227416,"mergeCommit":{"message":"[Upgrade Assistant] Fix uniq keys bug in ES deprecations table (#227416)","sha":"769404bd4ac35f1d38b6b2bf8dc0f56a43cb4533"}},{"branch":"8.18","label":"v8.18.4","branchLabelMappingKey":"^v(\\d+).(\\d+).\\d+$","isSourceBranch":false,"state":"NOT_CREATED"}]}] BACKPORT--> --------- Co-authored-by: kibanamachine <42973632+kibanamachine@users.noreply.github.com> Co-authored-by: Elastic Machine <elasticmachine@users.noreply.github.com>
Fixes: #227291
Summary
The issue was that the row keys are being generated using the visible array index (0-based for each page), resulting in duplicate keys like deprecation-row-0 appearing on every page. This caused React to incorrectly reuse component instances when navigating between pages.
The fix calculates an absolute index by adding the pager's
firstItemIndexto the current row index, ensuring unique keys across all pages (e.g., page 1 has keys 0-49, page 2 has keys 50-99). This prevents React from confusing components between pages and ensures that actions like reindexing only affect the correct deprecation item.