[Data View Field] Fix popularity score bugs #211201
Conversation
|
Pinging @elastic/kibana-data-discovery (Team:DataDiscovery) |
dmlemeshko
left a comment
There was a problem hiding this comment.
test/functional/services/field_editor.ts changes LGTM
davismcphee
left a comment
There was a problem hiding this comment.
Latest changes look great, thanks for addressing these issues!
💚 Build Succeeded
Metrics [docs]Public APIs missing comments
Async chunks
Page load bundle
Unknown metric groupsAPI count
History
cc @jughosta |
ElenaStoeva
left a comment
There was a problem hiding this comment.
Changes in test/functional/apps/management/data_views/_index_pattern_popularity.ts lgtm - rubber stamp review as we don't really own this test.
tsullivan
left a comment
There was a problem hiding this comment.
test/functional/page_objects/settings_page.ts update LGTM
|
Starting backport for target branches: 8.17, 8.18, 8.x, 9.0 https://github.com/elastic/kibana/actions/runs/13564369072 |
- Fixes elastic#211109 ## Summary This PR fixes a number of bugs in fields popularity logic: - [x] If field popularity was customized via UI form, the value will be saved now as a number instead of a string - [x] Same for runtime fields in another part of the code - [x] Since the data was polluted with string values, this PR makes sure that the incrementing would still work and the result would be converted to number. - [x] If user opened the field flyout, when selected/deselected fields as columns in the table, then opened the field flyout again, the data shown as Popularity was outdated. Now it should be fixed. - [x] Prevents reseting of Popularity scores in other fields. - [x] Functional tests in `test/functional/apps/discover/group6/_sidebar.ts` and `test/functional/apps/management/data_views/_index_pattern_popularity.ts`. ### 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 9726041)
- Fixes elastic#211109 ## Summary This PR fixes a number of bugs in fields popularity logic: - [x] If field popularity was customized via UI form, the value will be saved now as a number instead of a string - [x] Same for runtime fields in another part of the code - [x] Since the data was polluted with string values, this PR makes sure that the incrementing would still work and the result would be converted to number. - [x] If user opened the field flyout, when selected/deselected fields as columns in the table, then opened the field flyout again, the data shown as Popularity was outdated. Now it should be fixed. - [x] Prevents reseting of Popularity scores in other fields. - [x] Functional tests in `test/functional/apps/discover/group6/_sidebar.ts` and `test/functional/apps/management/data_views/_index_pattern_popularity.ts`. ### 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 9726041)
- Fixes elastic#211109 ## Summary This PR fixes a number of bugs in fields popularity logic: - [x] If field popularity was customized via UI form, the value will be saved now as a number instead of a string - [x] Same for runtime fields in another part of the code - [x] Since the data was polluted with string values, this PR makes sure that the incrementing would still work and the result would be converted to number. - [x] If user opened the field flyout, when selected/deselected fields as columns in the table, then opened the field flyout again, the data shown as Popularity was outdated. Now it should be fixed. - [x] Prevents reseting of Popularity scores in other fields. - [x] Functional tests in `test/functional/apps/discover/group6/_sidebar.ts` and `test/functional/apps/management/data_views/_index_pattern_popularity.ts`. ### 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 9726041)
- Fixes elastic#211109 ## Summary This PR fixes a number of bugs in fields popularity logic: - [x] If field popularity was customized via UI form, the value will be saved now as a number instead of a string - [x] Same for runtime fields in another part of the code - [x] Since the data was polluted with string values, this PR makes sure that the incrementing would still work and the result would be converted to number. - [x] If user opened the field flyout, when selected/deselected fields as columns in the table, then opened the field flyout again, the data shown as Popularity was outdated. Now it should be fixed. - [x] Prevents reseting of Popularity scores in other fields. - [x] Functional tests in `test/functional/apps/discover/group6/_sidebar.ts` and `test/functional/apps/management/data_views/_index_pattern_popularity.ts`. ### 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 9726041)
💚 All backports created successfully
Note: Successful backport PRs will be merged automatically after passing CI. Questions ?Please refer to the Backport tool documentation |
# Backport This will backport the following commits from `main` to `9.0`: - [[Data View Field] Fix popularity score bugs (#211201)](#211201) <!--- Backport version: 9.6.6 --> ### Questions ? Please refer to the [Backport tool documentation](https://github.com/sorenlouv/backport) <!--BACKPORT [{"author":{"name":"Julia Rechkunova","email":"julia.rechkunova@elastic.co"},"sourceCommit":{"committedDate":"2025-02-27T10:34:22Z","message":"[Data View Field] Fix popularity score bugs (#211201)\n\n- Fixes https://github.com/elastic/kibana/issues/211109\n\n## Summary\n\nThis PR fixes a number of bugs in fields popularity logic:\n- [x] If field popularity was customized via UI form, the value will be\nsaved now as a number instead of a string\n- [x] Same for runtime fields in another part of the code\n- [x] Since the data was polluted with string values, this PR makes sure\nthat the incrementing would still work and the result would be converted\nto number.\n- [x] If user opened the field flyout, when selected/deselected fields\nas columns in the table, then opened the field flyout again, the data\nshown as Popularity was outdated. Now it should be fixed.\n- [x] Prevents reseting of Popularity scores in other fields.\n- [x] Functional tests in\n`test/functional/apps/discover/group6/_sidebar.ts` and\n`test/functional/apps/management/data_views/_index_pattern_popularity.ts`.\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":"97260415030a3b816b3a8507c51c4a5184ff25df","branchLabelMapping":{"^v9.1.0$":"main","^v8.19.0$":"8.x","^v(\\d+).(\\d+).\\d+$":"$1.$2"}},"sourcePullRequest":{"labels":["release_note:fix","Feature:Data Views","v9.0.0","Team:DataDiscovery","backport:version","v8.17.0","v8.18.0","v9.1.0","v8.19.0"],"title":"[Data View Field] Fix popularity score bugs ","number":211201,"url":"https://github.com/elastic/kibana/pull/211201","mergeCommit":{"message":"[Data View Field] Fix popularity score bugs (#211201)\n\n- Fixes https://github.com/elastic/kibana/issues/211109\n\n## Summary\n\nThis PR fixes a number of bugs in fields popularity logic:\n- [x] If field popularity was customized via UI form, the value will be\nsaved now as a number instead of a string\n- [x] Same for runtime fields in another part of the code\n- [x] Since the data was polluted with string values, this PR makes sure\nthat the incrementing would still work and the result would be converted\nto number.\n- [x] If user opened the field flyout, when selected/deselected fields\nas columns in the table, then opened the field flyout again, the data\nshown as Popularity was outdated. Now it should be fixed.\n- [x] Prevents reseting of Popularity scores in other fields.\n- [x] Functional tests in\n`test/functional/apps/discover/group6/_sidebar.ts` and\n`test/functional/apps/management/data_views/_index_pattern_popularity.ts`.\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":"97260415030a3b816b3a8507c51c4a5184ff25df"}},"sourceBranch":"main","suggestedTargetBranches":["9.0","8.17","8.18","8.x"],"targetPullRequestStates":[{"branch":"9.0","label":"v9.0.0","branchLabelMappingKey":"^v(\\d+).(\\d+).\\d+$","isSourceBranch":false,"state":"NOT_CREATED"},{"branch":"8.17","label":"v8.17.0","branchLabelMappingKey":"^v(\\d+).(\\d+).\\d+$","isSourceBranch":false,"state":"NOT_CREATED"},{"branch":"8.18","label":"v8.18.0","branchLabelMappingKey":"^v(\\d+).(\\d+).\\d+$","isSourceBranch":false,"state":"NOT_CREATED"},{"branch":"main","label":"v9.1.0","branchLabelMappingKey":"^v9.1.0$","isSourceBranch":true,"state":"MERGED","url":"https://github.com/elastic/kibana/pull/211201","number":211201,"mergeCommit":{"message":"[Data View Field] Fix popularity score bugs (#211201)\n\n- Fixes https://github.com/elastic/kibana/issues/211109\n\n## Summary\n\nThis PR fixes a number of bugs in fields popularity logic:\n- [x] If field popularity was customized via UI form, the value will be\nsaved now as a number instead of a string\n- [x] Same for runtime fields in another part of the code\n- [x] Since the data was polluted with string values, this PR makes sure\nthat the incrementing would still work and the result would be converted\nto number.\n- [x] If user opened the field flyout, when selected/deselected fields\nas columns in the table, then opened the field flyout again, the data\nshown as Popularity was outdated. Now it should be fixed.\n- [x] Prevents reseting of Popularity scores in other fields.\n- [x] Functional tests in\n`test/functional/apps/discover/group6/_sidebar.ts` and\n`test/functional/apps/management/data_views/_index_pattern_popularity.ts`.\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":"97260415030a3b816b3a8507c51c4a5184ff25df"}},{"branch":"8.x","label":"v8.19.0","branchLabelMappingKey":"^v8.19.0$","isSourceBranch":false,"state":"NOT_CREATED"}]}] BACKPORT--> Co-authored-by: Julia Rechkunova <julia.rechkunova@elastic.co>
# Backport This will backport the following commits from `main` to `8.x`: - [[Data View Field] Fix popularity score bugs (#211201)](#211201) <!--- Backport version: 9.6.6 --> ### Questions ? Please refer to the [Backport tool documentation](https://github.com/sorenlouv/backport) <!--BACKPORT [{"author":{"name":"Julia Rechkunova","email":"julia.rechkunova@elastic.co"},"sourceCommit":{"committedDate":"2025-02-27T10:34:22Z","message":"[Data View Field] Fix popularity score bugs (#211201)\n\n- Fixes https://github.com/elastic/kibana/issues/211109\n\n## Summary\n\nThis PR fixes a number of bugs in fields popularity logic:\n- [x] If field popularity was customized via UI form, the value will be\nsaved now as a number instead of a string\n- [x] Same for runtime fields in another part of the code\n- [x] Since the data was polluted with string values, this PR makes sure\nthat the incrementing would still work and the result would be converted\nto number.\n- [x] If user opened the field flyout, when selected/deselected fields\nas columns in the table, then opened the field flyout again, the data\nshown as Popularity was outdated. Now it should be fixed.\n- [x] Prevents reseting of Popularity scores in other fields.\n- [x] Functional tests in\n`test/functional/apps/discover/group6/_sidebar.ts` and\n`test/functional/apps/management/data_views/_index_pattern_popularity.ts`.\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":"97260415030a3b816b3a8507c51c4a5184ff25df","branchLabelMapping":{"^v9.1.0$":"main","^v8.19.0$":"8.x","^v(\\d+).(\\d+).\\d+$":"$1.$2"}},"sourcePullRequest":{"labels":["release_note:fix","Feature:Data Views","v9.0.0","Team:DataDiscovery","backport:version","v8.17.0","v8.18.0","v9.1.0","v8.19.0"],"title":"[Data View Field] Fix popularity score bugs ","number":211201,"url":"https://github.com/elastic/kibana/pull/211201","mergeCommit":{"message":"[Data View Field] Fix popularity score bugs (#211201)\n\n- Fixes https://github.com/elastic/kibana/issues/211109\n\n## Summary\n\nThis PR fixes a number of bugs in fields popularity logic:\n- [x] If field popularity was customized via UI form, the value will be\nsaved now as a number instead of a string\n- [x] Same for runtime fields in another part of the code\n- [x] Since the data was polluted with string values, this PR makes sure\nthat the incrementing would still work and the result would be converted\nto number.\n- [x] If user opened the field flyout, when selected/deselected fields\nas columns in the table, then opened the field flyout again, the data\nshown as Popularity was outdated. Now it should be fixed.\n- [x] Prevents reseting of Popularity scores in other fields.\n- [x] Functional tests in\n`test/functional/apps/discover/group6/_sidebar.ts` and\n`test/functional/apps/management/data_views/_index_pattern_popularity.ts`.\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":"97260415030a3b816b3a8507c51c4a5184ff25df"}},"sourceBranch":"main","suggestedTargetBranches":["9.0","8.17","8.18","8.x"],"targetPullRequestStates":[{"branch":"9.0","label":"v9.0.0","branchLabelMappingKey":"^v(\\d+).(\\d+).\\d+$","isSourceBranch":false,"state":"NOT_CREATED"},{"branch":"8.17","label":"v8.17.0","branchLabelMappingKey":"^v(\\d+).(\\d+).\\d+$","isSourceBranch":false,"state":"NOT_CREATED"},{"branch":"8.18","label":"v8.18.0","branchLabelMappingKey":"^v(\\d+).(\\d+).\\d+$","isSourceBranch":false,"state":"NOT_CREATED"},{"branch":"main","label":"v9.1.0","branchLabelMappingKey":"^v9.1.0$","isSourceBranch":true,"state":"MERGED","url":"https://github.com/elastic/kibana/pull/211201","number":211201,"mergeCommit":{"message":"[Data View Field] Fix popularity score bugs (#211201)\n\n- Fixes https://github.com/elastic/kibana/issues/211109\n\n## Summary\n\nThis PR fixes a number of bugs in fields popularity logic:\n- [x] If field popularity was customized via UI form, the value will be\nsaved now as a number instead of a string\n- [x] Same for runtime fields in another part of the code\n- [x] Since the data was polluted with string values, this PR makes sure\nthat the incrementing would still work and the result would be converted\nto number.\n- [x] If user opened the field flyout, when selected/deselected fields\nas columns in the table, then opened the field flyout again, the data\nshown as Popularity was outdated. Now it should be fixed.\n- [x] Prevents reseting of Popularity scores in other fields.\n- [x] Functional tests in\n`test/functional/apps/discover/group6/_sidebar.ts` and\n`test/functional/apps/management/data_views/_index_pattern_popularity.ts`.\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":"97260415030a3b816b3a8507c51c4a5184ff25df"}},{"branch":"8.x","label":"v8.19.0","branchLabelMappingKey":"^v8.19.0$","isSourceBranch":false,"state":"NOT_CREATED"}]}] BACKPORT--> Co-authored-by: Julia Rechkunova <julia.rechkunova@elastic.co>
# Backport This will backport the following commits from `main` to `8.18`: - [[Data View Field] Fix popularity score bugs (#211201)](#211201) <!--- Backport version: 9.6.6 --> ### Questions ? Please refer to the [Backport tool documentation](https://github.com/sorenlouv/backport) <!--BACKPORT [{"author":{"name":"Julia Rechkunova","email":"julia.rechkunova@elastic.co"},"sourceCommit":{"committedDate":"2025-02-27T10:34:22Z","message":"[Data View Field] Fix popularity score bugs (#211201)\n\n- Fixes https://github.com/elastic/kibana/issues/211109\n\n## Summary\n\nThis PR fixes a number of bugs in fields popularity logic:\n- [x] If field popularity was customized via UI form, the value will be\nsaved now as a number instead of a string\n- [x] Same for runtime fields in another part of the code\n- [x] Since the data was polluted with string values, this PR makes sure\nthat the incrementing would still work and the result would be converted\nto number.\n- [x] If user opened the field flyout, when selected/deselected fields\nas columns in the table, then opened the field flyout again, the data\nshown as Popularity was outdated. Now it should be fixed.\n- [x] Prevents reseting of Popularity scores in other fields.\n- [x] Functional tests in\n`test/functional/apps/discover/group6/_sidebar.ts` and\n`test/functional/apps/management/data_views/_index_pattern_popularity.ts`.\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":"97260415030a3b816b3a8507c51c4a5184ff25df","branchLabelMapping":{"^v9.1.0$":"main","^v8.19.0$":"8.x","^v(\\d+).(\\d+).\\d+$":"$1.$2"}},"sourcePullRequest":{"labels":["release_note:fix","Feature:Data Views","v9.0.0","Team:DataDiscovery","backport:version","v8.17.0","v8.18.0","v9.1.0","v8.19.0"],"title":"[Data View Field] Fix popularity score bugs ","number":211201,"url":"https://github.com/elastic/kibana/pull/211201","mergeCommit":{"message":"[Data View Field] Fix popularity score bugs (#211201)\n\n- Fixes https://github.com/elastic/kibana/issues/211109\n\n## Summary\n\nThis PR fixes a number of bugs in fields popularity logic:\n- [x] If field popularity was customized via UI form, the value will be\nsaved now as a number instead of a string\n- [x] Same for runtime fields in another part of the code\n- [x] Since the data was polluted with string values, this PR makes sure\nthat the incrementing would still work and the result would be converted\nto number.\n- [x] If user opened the field flyout, when selected/deselected fields\nas columns in the table, then opened the field flyout again, the data\nshown as Popularity was outdated. Now it should be fixed.\n- [x] Prevents reseting of Popularity scores in other fields.\n- [x] Functional tests in\n`test/functional/apps/discover/group6/_sidebar.ts` and\n`test/functional/apps/management/data_views/_index_pattern_popularity.ts`.\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":"97260415030a3b816b3a8507c51c4a5184ff25df"}},"sourceBranch":"main","suggestedTargetBranches":["9.0","8.17","8.18","8.x"],"targetPullRequestStates":[{"branch":"9.0","label":"v9.0.0","branchLabelMappingKey":"^v(\\d+).(\\d+).\\d+$","isSourceBranch":false,"state":"NOT_CREATED"},{"branch":"8.17","label":"v8.17.0","branchLabelMappingKey":"^v(\\d+).(\\d+).\\d+$","isSourceBranch":false,"state":"NOT_CREATED"},{"branch":"8.18","label":"v8.18.0","branchLabelMappingKey":"^v(\\d+).(\\d+).\\d+$","isSourceBranch":false,"state":"NOT_CREATED"},{"branch":"main","label":"v9.1.0","branchLabelMappingKey":"^v9.1.0$","isSourceBranch":true,"state":"MERGED","url":"https://github.com/elastic/kibana/pull/211201","number":211201,"mergeCommit":{"message":"[Data View Field] Fix popularity score bugs (#211201)\n\n- Fixes https://github.com/elastic/kibana/issues/211109\n\n## Summary\n\nThis PR fixes a number of bugs in fields popularity logic:\n- [x] If field popularity was customized via UI form, the value will be\nsaved now as a number instead of a string\n- [x] Same for runtime fields in another part of the code\n- [x] Since the data was polluted with string values, this PR makes sure\nthat the incrementing would still work and the result would be converted\nto number.\n- [x] If user opened the field flyout, when selected/deselected fields\nas columns in the table, then opened the field flyout again, the data\nshown as Popularity was outdated. Now it should be fixed.\n- [x] Prevents reseting of Popularity scores in other fields.\n- [x] Functional tests in\n`test/functional/apps/discover/group6/_sidebar.ts` and\n`test/functional/apps/management/data_views/_index_pattern_popularity.ts`.\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":"97260415030a3b816b3a8507c51c4a5184ff25df"}},{"branch":"8.x","label":"v8.19.0","branchLabelMappingKey":"^v8.19.0$","isSourceBranch":false,"state":"NOT_CREATED"}]}] BACKPORT--> Co-authored-by: Julia Rechkunova <julia.rechkunova@elastic.co>
# Backport This will backport the following commits from `main` to `8.17`: - [[Data View Field] Fix popularity score bugs (#211201)](#211201) <!--- Backport version: 9.6.6 --> ### Questions ? Please refer to the [Backport tool documentation](https://github.com/sorenlouv/backport) <!--BACKPORT [{"author":{"name":"Julia Rechkunova","email":"julia.rechkunova@elastic.co"},"sourceCommit":{"committedDate":"2025-02-27T10:34:22Z","message":"[Data View Field] Fix popularity score bugs (#211201)\n\n- Fixes https://github.com/elastic/kibana/issues/211109\n\n## Summary\n\nThis PR fixes a number of bugs in fields popularity logic:\n- [x] If field popularity was customized via UI form, the value will be\nsaved now as a number instead of a string\n- [x] Same for runtime fields in another part of the code\n- [x] Since the data was polluted with string values, this PR makes sure\nthat the incrementing would still work and the result would be converted\nto number.\n- [x] If user opened the field flyout, when selected/deselected fields\nas columns in the table, then opened the field flyout again, the data\nshown as Popularity was outdated. Now it should be fixed.\n- [x] Prevents reseting of Popularity scores in other fields.\n- [x] Functional tests in\n`test/functional/apps/discover/group6/_sidebar.ts` and\n`test/functional/apps/management/data_views/_index_pattern_popularity.ts`.\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":"97260415030a3b816b3a8507c51c4a5184ff25df","branchLabelMapping":{"^v9.1.0$":"main","^v8.19.0$":"8.x","^v(\\d+).(\\d+).\\d+$":"$1.$2"}},"sourcePullRequest":{"labels":["release_note:fix","Feature:Data Views","v9.0.0","Team:DataDiscovery","backport:version","v8.17.0","v8.18.0","v9.1.0","v8.19.0"],"title":"[Data View Field] Fix popularity score bugs ","number":211201,"url":"https://github.com/elastic/kibana/pull/211201","mergeCommit":{"message":"[Data View Field] Fix popularity score bugs (#211201)\n\n- Fixes https://github.com/elastic/kibana/issues/211109\n\n## Summary\n\nThis PR fixes a number of bugs in fields popularity logic:\n- [x] If field popularity was customized via UI form, the value will be\nsaved now as a number instead of a string\n- [x] Same for runtime fields in another part of the code\n- [x] Since the data was polluted with string values, this PR makes sure\nthat the incrementing would still work and the result would be converted\nto number.\n- [x] If user opened the field flyout, when selected/deselected fields\nas columns in the table, then opened the field flyout again, the data\nshown as Popularity was outdated. Now it should be fixed.\n- [x] Prevents reseting of Popularity scores in other fields.\n- [x] Functional tests in\n`test/functional/apps/discover/group6/_sidebar.ts` and\n`test/functional/apps/management/data_views/_index_pattern_popularity.ts`.\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":"97260415030a3b816b3a8507c51c4a5184ff25df"}},"sourceBranch":"main","suggestedTargetBranches":["9.0","8.17","8.18","8.x"],"targetPullRequestStates":[{"branch":"9.0","label":"v9.0.0","branchLabelMappingKey":"^v(\\d+).(\\d+).\\d+$","isSourceBranch":false,"state":"NOT_CREATED"},{"branch":"8.17","label":"v8.17.0","branchLabelMappingKey":"^v(\\d+).(\\d+).\\d+$","isSourceBranch":false,"state":"NOT_CREATED"},{"branch":"8.18","label":"v8.18.0","branchLabelMappingKey":"^v(\\d+).(\\d+).\\d+$","isSourceBranch":false,"state":"NOT_CREATED"},{"branch":"main","label":"v9.1.0","branchLabelMappingKey":"^v9.1.0$","isSourceBranch":true,"state":"MERGED","url":"https://github.com/elastic/kibana/pull/211201","number":211201,"mergeCommit":{"message":"[Data View Field] Fix popularity score bugs (#211201)\n\n- Fixes https://github.com/elastic/kibana/issues/211109\n\n## Summary\n\nThis PR fixes a number of bugs in fields popularity logic:\n- [x] If field popularity was customized via UI form, the value will be\nsaved now as a number instead of a string\n- [x] Same for runtime fields in another part of the code\n- [x] Since the data was polluted with string values, this PR makes sure\nthat the incrementing would still work and the result would be converted\nto number.\n- [x] If user opened the field flyout, when selected/deselected fields\nas columns in the table, then opened the field flyout again, the data\nshown as Popularity was outdated. Now it should be fixed.\n- [x] Prevents reseting of Popularity scores in other fields.\n- [x] Functional tests in\n`test/functional/apps/discover/group6/_sidebar.ts` and\n`test/functional/apps/management/data_views/_index_pattern_popularity.ts`.\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":"97260415030a3b816b3a8507c51c4a5184ff25df"}},{"branch":"8.x","label":"v8.19.0","branchLabelMappingKey":"^v8.19.0$","isSourceBranch":false,"state":"NOT_CREATED"}]}] BACKPORT--> --------- Co-authored-by: Julia Rechkunova <julia.rechkunova@elastic.co>
…lastic#212616) # Backport This will backport the following commits from `main` to `8.x`: - [[Data View Field] Fix popularity score bugs (elastic#211201)](elastic#211201) <!--- Backport version: 9.6.6 --> ### Questions ? Please refer to the [Backport tool documentation](https://github.com/sorenlouv/backport) <!--BACKPORT [{"author":{"name":"Julia Rechkunova","email":"julia.rechkunova@elastic.co"},"sourceCommit":{"committedDate":"2025-02-27T10:34:22Z","message":"[Data View Field] Fix popularity score bugs (elastic#211201)\n\n- Fixes https://github.com/elastic/kibana/issues/211109\n\n## Summary\n\nThis PR fixes a number of bugs in fields popularity logic:\n- [x] If field popularity was customized via UI form, the value will be\nsaved now as a number instead of a string\n- [x] Same for runtime fields in another part of the code\n- [x] Since the data was polluted with string values, this PR makes sure\nthat the incrementing would still work and the result would be converted\nto number.\n- [x] If user opened the field flyout, when selected/deselected fields\nas columns in the table, then opened the field flyout again, the data\nshown as Popularity was outdated. Now it should be fixed.\n- [x] Prevents reseting of Popularity scores in other fields.\n- [x] Functional tests in\n`test/functional/apps/discover/group6/_sidebar.ts` and\n`test/functional/apps/management/data_views/_index_pattern_popularity.ts`.\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":"97260415030a3b816b3a8507c51c4a5184ff25df","branchLabelMapping":{"^v9.1.0$":"main","^v8.19.0$":"8.x","^v(\\d+).(\\d+).\\d+$":"$1.$2"}},"sourcePullRequest":{"labels":["release_note:fix","Feature:Data Views","v9.0.0","Team:DataDiscovery","backport:version","v8.17.0","v8.18.0","v9.1.0","v8.19.0"],"title":"[Data View Field] Fix popularity score bugs ","number":211201,"url":"https://github.com/elastic/kibana/pull/211201","mergeCommit":{"message":"[Data View Field] Fix popularity score bugs (elastic#211201)\n\n- Fixes https://github.com/elastic/kibana/issues/211109\n\n## Summary\n\nThis PR fixes a number of bugs in fields popularity logic:\n- [x] If field popularity was customized via UI form, the value will be\nsaved now as a number instead of a string\n- [x] Same for runtime fields in another part of the code\n- [x] Since the data was polluted with string values, this PR makes sure\nthat the incrementing would still work and the result would be converted\nto number.\n- [x] If user opened the field flyout, when selected/deselected fields\nas columns in the table, then opened the field flyout again, the data\nshown as Popularity was outdated. Now it should be fixed.\n- [x] Prevents reseting of Popularity scores in other fields.\n- [x] Functional tests in\n`test/functional/apps/discover/group6/_sidebar.ts` and\n`test/functional/apps/management/data_views/_index_pattern_popularity.ts`.\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":"97260415030a3b816b3a8507c51c4a5184ff25df"}},"sourceBranch":"main","suggestedTargetBranches":["9.0","8.17","8.18","8.x"],"targetPullRequestStates":[{"branch":"9.0","label":"v9.0.0","branchLabelMappingKey":"^v(\\d+).(\\d+).\\d+$","isSourceBranch":false,"state":"NOT_CREATED"},{"branch":"8.17","label":"v8.17.0","branchLabelMappingKey":"^v(\\d+).(\\d+).\\d+$","isSourceBranch":false,"state":"NOT_CREATED"},{"branch":"8.18","label":"v8.18.0","branchLabelMappingKey":"^v(\\d+).(\\d+).\\d+$","isSourceBranch":false,"state":"NOT_CREATED"},{"branch":"main","label":"v9.1.0","branchLabelMappingKey":"^v9.1.0$","isSourceBranch":true,"state":"MERGED","url":"https://github.com/elastic/kibana/pull/211201","number":211201,"mergeCommit":{"message":"[Data View Field] Fix popularity score bugs (elastic#211201)\n\n- Fixes https://github.com/elastic/kibana/issues/211109\n\n## Summary\n\nThis PR fixes a number of bugs in fields popularity logic:\n- [x] If field popularity was customized via UI form, the value will be\nsaved now as a number instead of a string\n- [x] Same for runtime fields in another part of the code\n- [x] Since the data was polluted with string values, this PR makes sure\nthat the incrementing would still work and the result would be converted\nto number.\n- [x] If user opened the field flyout, when selected/deselected fields\nas columns in the table, then opened the field flyout again, the data\nshown as Popularity was outdated. Now it should be fixed.\n- [x] Prevents reseting of Popularity scores in other fields.\n- [x] Functional tests in\n`test/functional/apps/discover/group6/_sidebar.ts` and\n`test/functional/apps/management/data_views/_index_pattern_popularity.ts`.\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":"97260415030a3b816b3a8507c51c4a5184ff25df"}},{"branch":"8.x","label":"v8.19.0","branchLabelMappingKey":"^v8.19.0$","isSourceBranch":false,"state":"NOT_CREATED"}]}] BACKPORT--> Co-authored-by: Julia Rechkunova <julia.rechkunova@elastic.co>
- Fixes elastic#211109 ## Summary This PR fixes a number of bugs in fields popularity logic: - [x] If field popularity was customized via UI form, the value will be saved now as a number instead of a string - [x] Same for runtime fields in another part of the code - [x] Since the data was polluted with string values, this PR makes sure that the incrementing would still work and the result would be converted to number. - [x] If user opened the field flyout, when selected/deselected fields as columns in the table, then opened the field flyout again, the data shown as Popularity was outdated. Now it should be fixed. - [x] Prevents reseting of Popularity scores in other fields. - [x] Functional tests in `test/functional/apps/discover/group6/_sidebar.ts` and `test/functional/apps/management/data_views/_index_pattern_popularity.ts`. ### 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
Summary
This PR fixes a number of bugs in fields popularity logic:
test/functional/apps/discover/group6/_sidebar.tsandtest/functional/apps/management/data_views/_index_pattern_popularity.ts.Checklist