-
Notifications
You must be signed in to change notification settings - Fork 8.2k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[RAM] Alerts Table breaking when adding first column in fields browser #156557
Merged
Conversation
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
jcger
added
bug
Fixes for quality problems that affect the customer experience
release_note:fix
Team:ResponseOps
Label for the ResponseOps team (formerly the Cases and Alerting teams)
v8.8.0
labels
May 3, 2023
Pinging @elastic/response-ops (Team:ResponseOps) |
jcger
changed the title
fix missing use case
[RAM] Alerts Table breaking when adding first column in fields browser
May 3, 2023
guskovaue
approved these changes
May 3, 2023
💚 Build Succeeded
Metrics [docs]Async chunks
Unknown metric groupsESLint disabled line counts
Total ESLint disabled count
To update your PR or re-run it, just comment with: |
💚 All backports created successfully
Note: Successful backport PRs will be merged automatically after passing CI. Questions ?Please refer to the Backport tool documentation |
kibanamachine
pushed a commit
to kibanamachine/kibana
that referenced
this pull request
May 3, 2023
elastic#156557) Fixes elastic#156001 (cherry picked from commit 4171c9b)
kibanamachine
added a commit
that referenced
this pull request
May 3, 2023
…browser (#156557) (#156572) # Backport This will backport the following commits from `main` to `8.8`: - [[RAM] Alerts Table breaking when adding first column in fields browser (#156557)](#156557) <!--- Backport version: 8.9.7 --> ### Questions ? Please refer to the [Backport tool documentation](https://github.com/sqren/backport) <!--BACKPORT [{"author":{"name":"Julian Gernun","email":"[email protected]"},"sourceCommit":{"committedDate":"2023-05-03T15:30:14Z","message":"[RAM] Alerts Table breaking when adding first column in fields browser (#156557)\n\nFixes https://github.com/elastic/kibana/issues/156001","sha":"4171c9b8229e497a79c3ad0ced5e035944f2c159","branchLabelMapping":{"^v8.9.0$":"main","^v(\\d+).(\\d+).\\d+$":"$1.$2"}},"sourcePullRequest":{"labels":["bug","release_note:fix","Team:ResponseOps","v8.8.0","v8.9.0"],"number":156557,"url":"https://github.com/elastic/kibana/pull/156557","mergeCommit":{"message":"[RAM] Alerts Table breaking when adding first column in fields browser (#156557)\n\nFixes https://github.com/elastic/kibana/issues/156001","sha":"4171c9b8229e497a79c3ad0ced5e035944f2c159"}},"sourceBranch":"main","suggestedTargetBranches":["8.8"],"targetPullRequestStates":[{"branch":"8.8","label":"v8.8.0","labelRegex":"^v(\\d+).(\\d+).\\d+$","isSourceBranch":false,"state":"NOT_CREATED"},{"branch":"main","label":"v8.9.0","labelRegex":"^v8.9.0$","isSourceBranch":true,"state":"MERGED","url":"https://github.com/elastic/kibana/pull/156557","number":156557,"mergeCommit":{"message":"[RAM] Alerts Table breaking when adding first column in fields browser (#156557)\n\nFixes https://github.com/elastic/kibana/issues/156001","sha":"4171c9b8229e497a79c3ad0ced5e035944f2c159"}}]}] BACKPORT--> Co-authored-by: Julian Gernun <[email protected]>
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Labels
bug
Fixes for quality problems that affect the customer experience
release_note:fix
Team:ResponseOps
Label for the ResponseOps team (formerly the Cases and Alerting teams)
v8.8.0
v8.9.0
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Fixes #156001
We previously overlooked a scenario where no columns were displayed. When generating the output array of columns, the code would insert an empty entry at the beginning because 'columns[0]' was undefined (check current code), which later caused an error. To resolve this issue without processing again all elements in the entire array, we now check if the current columns display array is empty. If it is, we return a new array containing only the user-added column and exit early.