-
Notifications
You must be signed in to change notification settings - Fork 8.5k
[Security Solution][Detections] - Fix query preview bugs + tests #79947
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
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@XavierM please let me know if this is what you were thinking.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Yes but the const bucketEmpty need to go on line 34 ;)
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@patrykkopycinski @angorayc @XavierM Is this change here ok? addDanger only shows an error message, while addError allows the user to click to view full error details.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
we might need to change it everywhere for consistency, but we can take care of that. Thank you!
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
There's an existing bug with warnings, working on the fix in a separate PR to keep these small-ish.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@patrykkopycinski I was able to test this hook more thoroughly, and was going to do the same for useMatrixHistogram but required one small change of first declaring the variable let subscription$ and then assigning it. Otherwise, the tests failed saying the variable was unreachable. If this seems like an ok change, happy to add similar tests to useMatrixHistogram.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
👍
rylnd
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Looking good so far! Just a few minor things. Big remaining one is the syncing of validity to the preview button; I hit that a bunch in testing this.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This seems a bit strange to me. Is one of the comparisons meant to be a type check? If they're both numbers I think the latter check should be sufficient
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Yea, I wanted to try to keep the PRs smallish - so I focused on fixing the bugs/tests with the api here and have a sequel "preview_buggies_2" that addresses these issues (#80110). I promise it's a really good sequel 😄
It currently includes the changes from this PR, but if you check out the last 2 commits you can see the new changes.
32d5421 to
552b41f
Compare
|
Had been trying to have smaller PRs, but going to just address the comments from here in this new PR that tackles all known bugs at once - #80110 |
💚 Build SucceededMetrics [docs]async chunks size
page load bundle size
History
To update your PR or re-run it, just comment with: |

Summary
Fixes the following in the rule query preview feature:
addErrorso now user can click to view detailssomeAriaIdChecklist