-
Notifications
You must be signed in to change notification settings - Fork 8.3k
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
[ML] Transforms: Fixes privileges check #163687
Conversation
Pinging @elastic/ml-ui (:ml) |
💚 Build Succeeded
Metrics [docs]Module Count
Async chunks
Page load bundle
To update your PR or re-run it, just comment with: |
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.
Tested, LGTM
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.
LGTM
💔 All backports failed
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 |
Fixes a regression introduced in elastic#154007. When security is disabled, the check for transform privileges/capabilities would fail and the transform page would not render. - This fixes the endpoint to return data in the correct format should security be disabled. - The endpoint's TypeScript has been updated to catch malformed responses. - The client side custom `useRequest` is replaced with `useQuery` from `'@tanstack/react-query'` which also fixes TypeScript support on the client side. (cherry picked from commit ecaa8a7) # Conflicts: # x-pack/plugins/transform/public/app/app.tsx
* main: (64 commits) [ML] Transforms: Fix privileges check. (elastic#163687) [Log Explorer] Add test suite for Dataset Selector (elastic#163079) [Security Solution][Endpoint] Add API checks to Endpoint Policy create/update for checking `endpointPolicyProtections` is enabled (elastic#163429) [Security Solution] Fix flaky test: x-pack/test/detection_engine_api_integration/security_and_spaces/update_prebuilt_rules_package/update_prebuilt_rules_package·ts - update_prebuilt_rules_package should allow user to install prebuilt rules from scratch, then install new rules and upgrade existing rules from the new package (elastic#163241) [Security Solution] expandable flyout - replace feature flag with advanced settings toggle (elastic#161614) [DOCS] Adds the release notes for the 8.9.1 release. (elastic#163578) [FTR] Implement browser network condition utils (elastic#163633) [Security Solution] Unskip rules table auto-refresh Cypress tests (elastic#163451) [Security Solution] Re-enable fixed rule snoozing Cypress test (elastic#160037) [Flaky Test elastic#111821] Mock `moment` to avoid midnight TZ issues (elastic#163157) Document interactive setup (elastic#163619) [Lens] Align decoration color with text color for layer actions (elastic#163630) [Lens] Relax counter field checks for saved visualizations with unsupported operations (elastic#163515) [Security Solution][Endpoint] Removes pMap and uses a for loop instead (elastic#163509) [Enterprise Search] Update Workplace Search connectors doclink (elastic#163676) Update APM (main) (elastic#163623) [Serverless] Partially fix lens/maps/visualize breadcrumbs missing title (elastic#163476) [Flaky elastic#118272] Unskip tests (elastic#163319) [APM] Make service group saved objects exportable (elastic#163569) [Observability AI Assistant] Action menu item (elastic#163463) ...
# Backport This will backport the following commits from `main` to `8.9`: - [[ML] Transforms: Fix privileges check. (#163687)](#163687) <!--- Backport version: 8.9.8 --> ### Questions ? Please refer to the [Backport tool documentation](https://github.com/sqren/backport) <!--BACKPORT [{"author":{"name":"Walter Rafelsberger","email":"walter.rafelsberger@elastic.co"},"sourceCommit":{"committedDate":"2023-08-11T13:46:56Z","message":"[ML] Transforms: Fix privileges check. (#163687)\n\nFixes a regression introduced in #154007.\r\n\r\nWhen security is disabled, the check for transform\r\nprivileges/capabilities would fail and the transform page would not\r\nrender.\r\n\r\n- This fixes the endpoint to return data in the correct format should\r\nsecurity be disabled.\r\n- The endpoint's TypeScript has been updated to catch malformed\r\nresponses.\r\n- The client side custom `useRequest` is replaced with `useQuery` from\r\n`'@tanstack/react-query'` which also fixes TypeScript support on the\r\nclient side.","sha":"ecaa8a73707f97c99ef2d57574ac3dcbac3096df","branchLabelMapping":{"^v8.10.0$":"main","^v(\\d+).(\\d+).\\d+$":"$1.$2"}},"sourcePullRequest":{"labels":["bug","release_note:fix",":ml","Feature:Transforms","v8.10.0","v8.9.2"],"number":163687,"url":"https://github.com/elastic/kibana/pull/163687","mergeCommit":{"message":"[ML] Transforms: Fix privileges check. (#163687)\n\nFixes a regression introduced in #154007.\r\n\r\nWhen security is disabled, the check for transform\r\nprivileges/capabilities would fail and the transform page would not\r\nrender.\r\n\r\n- This fixes the endpoint to return data in the correct format should\r\nsecurity be disabled.\r\n- The endpoint's TypeScript has been updated to catch malformed\r\nresponses.\r\n- The client side custom `useRequest` is replaced with `useQuery` from\r\n`'@tanstack/react-query'` which also fixes TypeScript support on the\r\nclient side.","sha":"ecaa8a73707f97c99ef2d57574ac3dcbac3096df"}},"sourceBranch":"main","suggestedTargetBranches":["8.9"],"targetPullRequestStates":[{"branch":"main","label":"v8.10.0","labelRegex":"^v8.10.0$","isSourceBranch":true,"state":"MERGED","url":"https://github.com/elastic/kibana/pull/163687","number":163687,"mergeCommit":{"message":"[ML] Transforms: Fix privileges check. (#163687)\n\nFixes a regression introduced in #154007.\r\n\r\nWhen security is disabled, the check for transform\r\nprivileges/capabilities would fail and the transform page would not\r\nrender.\r\n\r\n- This fixes the endpoint to return data in the correct format should\r\nsecurity be disabled.\r\n- The endpoint's TypeScript has been updated to catch malformed\r\nresponses.\r\n- The client side custom `useRequest` is replaced with `useQuery` from\r\n`'@tanstack/react-query'` which also fixes TypeScript support on the\r\nclient side.","sha":"ecaa8a73707f97c99ef2d57574ac3dcbac3096df"}},{"branch":"8.9","label":"v8.9.2","labelRegex":"^v(\\d+).(\\d+).\\d+$","isSourceBranch":false,"state":"NOT_CREATED"}]}] BACKPORT-->
This pr didn't make it into the build candidate for v8.9.1. Updating the labels. |
Summary
Related to #164303.
Fixes a regression introduced in #154007.
When security is disabled, the check for transform privileges/capabilities would fail and the transform page would not render.
useRequest
is replaced withuseQuery
from'@tanstack/react-query'
which also fixes TypeScript support on the client side.Checklist