-
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
[Console] A console url that contains load_from
query para doesnt allow editing
#195877
Labels
Feature:Console
Dev Tools Console Feature
impact:high
Addressing this issue will have a high level of impact on the quality/strength of our product.
Team:Kibana Management
Dev Tools, Index Management, Upgrade Assistant, ILM, Ingest Node Pipelines, and more
v8.16.0
v9.0.0
Comments
sabarasaba
added
the
bug
Fixes for quality problems that affect the customer experience
label
Oct 11, 2024
sabarasaba
added
Feature:Console
Dev Tools Console Feature
Team:Kibana Management
Dev Tools, Index Management, Upgrade Assistant, ILM, Ingest Node Pipelines, and more
v9.0.0
v8.16.0
and removed
bug
Fixes for quality problems that affect the customer experience
needs-team
Issues missing a team label
labels
Oct 11, 2024
Pinging @elastic/kibana-management (Team:Kibana Management) |
sabarasaba
added
the
impact:high
Addressing this issue will have a high level of impact on the quality/strength of our product.
label
Oct 11, 2024
kibanamachine
pushed a commit
to kibanamachine/kibana
that referenced
this issue
Oct 21, 2024
Fixes elastic#195877 Addresses elastic#179658 ## Summary This PR fixes the bug in Console where using the `load_from` param in the URL made Console uneditable because every re-render reset the initial value in the editor. This is fixed by restricting the hook to only set the initial value once. This PR also adds some unit tests for the hook, as I realized that this was a long-standing improvement. ### How to test: Try loading the following URL (making the necessary replacement in the URL) and verify that the data is correctly loaded into the editor and value can be edited: `http://localhost:5601/<REPLACE-THIS>/app/dev_tools#/console?load_from=data:text/plain,AoeQygKgBA9A+gRwK4FMBOBPGBDAzhgOwGMB+AEzQHsAHOApAGwbiMoaQFsDcAoAbx5QoAImToMwgFwiAZgCVKAWShoUHSgBcUAWgBUkgJYEyKAB4pcwgDSCRDSkWwMUUkSgLXbwmQYZa0rgJCQsIARpRsgbbBIhxIuBquANoAujYxIT5+6Mlp0cHCuAAWlIxkuekZwnEJdJq5+QC+ts2NQA` `http://localhost:5601/<REPLACE-THIS>/app/dev_tools#/console?load_from=https://www.elastic.co/guide/en/elasticsearch/reference/current/snippets/86.console` Co-authored-by: Matthew Kime <[email protected]> (cherry picked from commit e6e4e34)
ElenaStoeva
added a commit
to ElenaStoeva/kibana
that referenced
this issue
Oct 22, 2024
Fixes elastic#195877 Addresses elastic#179658 ## Summary This PR fixes the bug in Console where using the `load_from` param in the URL made Console uneditable because every re-render reset the initial value in the editor. This is fixed by restricting the hook to only set the initial value once. This PR also adds some unit tests for the hook, as I realized that this was a long-standing improvement. ### How to test: Try loading the following URL (making the necessary replacement in the URL) and verify that the data is correctly loaded into the editor and value can be edited: `http://localhost:5601/<REPLACE-THIS>/app/dev_tools#/console?load_from=data:text/plain,AoeQygKgBA9A+gRwK4FMBOBPGBDAzhgOwGMB+AEzQHsAHOApAGwbiMoaQFsDcAoAbx5QoAImToMwgFwiAZgCVKAWShoUHSgBcUAWgBUkgJYEyKAB4pcwgDSCRDSkWwMUUkSgLXbwmQYZa0rgJCQsIARpRsgbbBIhxIuBquANoAujYxIT5+6Mlp0cHCuAAWlIxkuekZwnEJdJq5+QC+ts2NQA` `http://localhost:5601/<REPLACE-THIS>/app/dev_tools#/console?load_from=https://www.elastic.co/guide/en/elasticsearch/reference/current/snippets/86.console` Co-authored-by: Matthew Kime <[email protected]> (cherry picked from commit e6e4e34)
ElenaStoeva
added a commit
that referenced
this issue
Oct 22, 2024
# Backport This will backport the following commits from `main` to `8.16`: - [[Console] Fix load_from param (#196836)](#196836) <!--- Backport version: 8.9.8 --> ### Questions ? Please refer to the [Backport tool documentation](https://github.com/sqren/backport) <!--BACKPORT [{"author":{"name":"Elena Stoeva","email":"[email protected]"},"sourceCommit":{"committedDate":"2024-10-21T19:20:30Z","message":"[Console] Fix load_from param (#196836)\n\nFixes https://github.com/elastic/kibana/issues/195877\r\nAddresses https://github.com/elastic/kibana/issues/179658\r\n\r\n## Summary\r\n\r\nThis PR fixes the bug in Console where using the `load_from` param in\r\nthe URL made Console uneditable because every re-render reset the\r\ninitial value in the editor. This is fixed by restricting the hook to\r\nonly set the initial value once. This PR also adds some unit tests for\r\nthe hook, as I realized that this was a long-standing improvement.\r\n\r\n### How to test:\r\n\r\nTry loading the following URL (making the necessary replacement in the\r\nURL) and verify that the data is correctly loaded into the editor and\r\nvalue can be edited:\r\n\r\n\r\n`http://localhost:5601/<REPLACE-THIS>/app/dev_tools#/console?load_from=data:text/plain,AoeQygKgBA9A+gRwK4FMBOBPGBDAzhgOwGMB+AEzQHsAHOApAGwbiMoaQFsDcAoAbx5QoAImToMwgFwiAZgCVKAWShoUHSgBcUAWgBUkgJYEyKAB4pcwgDSCRDSkWwMUUkSgLXbwmQYZa0rgJCQsIARpRsgbbBIhxIuBquANoAujYxIT5+6Mlp0cHCuAAWlIxkuekZwnEJdJq5+QC+ts2NQA`\r\n\r\n\r\n\r\n`http://localhost:5601/<REPLACE-THIS>/app/dev_tools#/console?load_from=https://www.elastic.co/guide/en/elasticsearch/reference/current/snippets/86.console`\r\n\r\nCo-authored-by: Matthew Kime <[email protected]>","sha":"e6e4e343aa700f1b489915f8df233a0abf2ea058","branchLabelMapping":{"^v9.0.0$":"main","^v8.17.0$":"8.x","^v(\\d+).(\\d+).\\d+$":"$1.$2"}},"sourcePullRequest":{"labels":["Feature:Console","Team:Kibana Management","release_note:skip","v9.0.0","backport:prev-minor","v8.16.0","v8.17.0"],"number":196836,"url":"https://github.com/elastic/kibana/pull/196836","mergeCommit":{"message":"[Console] Fix load_from param (#196836)\n\nFixes https://github.com/elastic/kibana/issues/195877\r\nAddresses https://github.com/elastic/kibana/issues/179658\r\n\r\n## Summary\r\n\r\nThis PR fixes the bug in Console where using the `load_from` param in\r\nthe URL made Console uneditable because every re-render reset the\r\ninitial value in the editor. This is fixed by restricting the hook to\r\nonly set the initial value once. This PR also adds some unit tests for\r\nthe hook, as I realized that this was a long-standing improvement.\r\n\r\n### How to test:\r\n\r\nTry loading the following URL (making the necessary replacement in the\r\nURL) and verify that the data is correctly loaded into the editor and\r\nvalue can be edited:\r\n\r\n\r\n`http://localhost:5601/<REPLACE-THIS>/app/dev_tools#/console?load_from=data:text/plain,AoeQygKgBA9A+gRwK4FMBOBPGBDAzhgOwGMB+AEzQHsAHOApAGwbiMoaQFsDcAoAbx5QoAImToMwgFwiAZgCVKAWShoUHSgBcUAWgBUkgJYEyKAB4pcwgDSCRDSkWwMUUkSgLXbwmQYZa0rgJCQsIARpRsgbbBIhxIuBquANoAujYxIT5+6Mlp0cHCuAAWlIxkuekZwnEJdJq5+QC+ts2NQA`\r\n\r\n\r\n\r\n`http://localhost:5601/<REPLACE-THIS>/app/dev_tools#/console?load_from=https://www.elastic.co/guide/en/elasticsearch/reference/current/snippets/86.console`\r\n\r\nCo-authored-by: Matthew Kime <[email protected]>","sha":"e6e4e343aa700f1b489915f8df233a0abf2ea058"}},"sourceBranch":"main","suggestedTargetBranches":["8.16"],"targetPullRequestStates":[{"branch":"main","label":"v9.0.0","labelRegex":"^v9.0.0$","isSourceBranch":true,"state":"MERGED","url":"https://github.com/elastic/kibana/pull/196836","number":196836,"mergeCommit":{"message":"[Console] Fix load_from param (#196836)\n\nFixes https://github.com/elastic/kibana/issues/195877\r\nAddresses https://github.com/elastic/kibana/issues/179658\r\n\r\n## Summary\r\n\r\nThis PR fixes the bug in Console where using the `load_from` param in\r\nthe URL made Console uneditable because every re-render reset the\r\ninitial value in the editor. This is fixed by restricting the hook to\r\nonly set the initial value once. This PR also adds some unit tests for\r\nthe hook, as I realized that this was a long-standing improvement.\r\n\r\n### How to test:\r\n\r\nTry loading the following URL (making the necessary replacement in the\r\nURL) and verify that the data is correctly loaded into the editor and\r\nvalue can be edited:\r\n\r\n\r\n`http://localhost:5601/<REPLACE-THIS>/app/dev_tools#/console?load_from=data:text/plain,AoeQygKgBA9A+gRwK4FMBOBPGBDAzhgOwGMB+AEzQHsAHOApAGwbiMoaQFsDcAoAbx5QoAImToMwgFwiAZgCVKAWShoUHSgBcUAWgBUkgJYEyKAB4pcwgDSCRDSkWwMUUkSgLXbwmQYZa0rgJCQsIARpRsgbbBIhxIuBquANoAujYxIT5+6Mlp0cHCuAAWlIxkuekZwnEJdJq5+QC+ts2NQA`\r\n\r\n\r\n\r\n`http://localhost:5601/<REPLACE-THIS>/app/dev_tools#/console?load_from=https://www.elastic.co/guide/en/elasticsearch/reference/current/snippets/86.console`\r\n\r\nCo-authored-by: Matthew Kime <[email protected]>","sha":"e6e4e343aa700f1b489915f8df233a0abf2ea058"}},{"branch":"8.16","label":"v8.16.0","labelRegex":"^v(\\d+).(\\d+).\\d+$","isSourceBranch":false,"state":"NOT_CREATED"},{"branch":"8.x","label":"v8.17.0","labelRegex":"^v8.17.0$","isSourceBranch":false,"url":"https://github.com/elastic/kibana/pull/197131","number":197131,"state":"MERGED","mergeCommit":{"sha":"a5ad3e5d937ee5cfed4e78dfb10e2e40aad4e075","message":"[8.x] [Console] Fix load_from param (#196836) (#197131)\n\n# Backport\n\nThis will backport the following commits from `main` to `8.x`:\n- [[Console] Fix load_from param\n(#196836)](https://github.com/elastic/kibana/pull/196836)\n\n<!--- Backport version: 9.4.3 -->\n\n### Questions ?\nPlease refer to the [Backport tool\ndocumentation](https://github.com/sqren/backport)\n\n<!--BACKPORT [{\"author\":{\"name\":\"Elena\nStoeva\",\"email\":\"[email protected]\"},\"sourceCommit\":{\"committedDate\":\"2024-10-21T19:20:30Z\",\"message\":\"[Console]\nFix load_from param (#196836)\\n\\nFixes\nhttps://github.com//issues/195877\\r\\nAddresses\nhttps://github.com//issues/179658\\r\\n\\r\\n##\nSummary\\r\\n\\r\\nThis PR fixes the bug in Console where using the\n`load_from` param in\\r\\nthe URL made Console uneditable because every\nre-render reset the\\r\\ninitial value in the editor. This is fixed by\nrestricting the hook to\\r\\nonly set the initial value once. This PR also\nadds some unit tests for\\r\\nthe hook, as I realized that this was a\nlong-standing improvement.\\r\\n\\r\\n### How to test:\\r\\n\\r\\nTry loading\nthe following URL (making the necessary replacement in the\\r\\nURL) and\nverify that the data is correctly loaded into the editor and\\r\\nvalue\ncan be\nedited:\\r\\n\\r\\n\\r\\n`http://localhost:5601/<REPLACE-THIS>/app/dev_tools#/console?load_from=data:text/plain,AoeQygKgBA9A+gRwK4FMBOBPGBDAzhgOwGMB+AEzQHsAHOApAGwbiMoaQFsDcAoAbx5QoAImToMwgFwiAZgCVKAWShoUHSgBcUAWgBUkgJYEyKAB4pcwgDSCRDSkWwMUUkSgLXbwmQYZa0rgJCQsIARpRsgbbBIhxIuBquANoAujYxIT5+6Mlp0cHCuAAWlIxkuekZwnEJdJq5+QC+ts2NQA`\\r\\n\\r\\n\\r\\n\\r\\n`http://localhost:5601/<REPLACE-THIS>/app/dev_tools#/console?load_from=https://www.elastic.co/guide/en/elasticsearch/reference/current/snippets/86.console`\\r\\n\\r\\nCo-authored-by:\nMatthew Kime\n<[email protected]>\",\"sha\":\"e6e4e343aa700f1b489915f8df233a0abf2ea058\",\"branchLabelMapping\":{\"^v9.0.0$\":\"main\",\"^v8.17.0$\":\"8.x\",\"^v(\\\\d+).(\\\\d+).\\\\d+$\":\"$1.$2\"}},\"sourcePullRequest\":{\"labels\":[\"Feature:Console\",\"Team:Kibana\nManagement\",\"release_note:skip\",\"v9.0.0\",\"backport:prev-minor\"],\"title\":\"[Console]\nFix load_from\nparam\",\"number\":196836,\"url\":\"https://github.com/elastic/kibana/pull/196836\",\"mergeCommit\":{\"message\":\"[Console]\nFix load_from param (#196836)\\n\\nFixes\nhttps://github.com//issues/195877\\r\\nAddresses\nhttps://github.com//issues/179658\\r\\n\\r\\n##\nSummary\\r\\n\\r\\nThis PR fixes the bug in Console where using the\n`load_from` param in\\r\\nthe URL made Console uneditable because every\nre-render reset the\\r\\ninitial value in the editor. This is fixed by\nrestricting the hook to\\r\\nonly set the initial value once. This PR also\nadds some unit tests for\\r\\nthe hook, as I realized that this was a\nlong-standing improvement.\\r\\n\\r\\n### How to test:\\r\\n\\r\\nTry loading\nthe following URL (making the necessary replacement in the\\r\\nURL) and\nverify that the data is correctly loaded into the editor and\\r\\nvalue\ncan be\nedited:\\r\\n\\r\\n\\r\\n`http://localhost:5601/<REPLACE-THIS>/app/dev_tools#/console?load_from=data:text/plain,AoeQygKgBA9A+gRwK4FMBOBPGBDAzhgOwGMB+AEzQHsAHOApAGwbiMoaQFsDcAoAbx5QoAImToMwgFwiAZgCVKAWShoUHSgBcUAWgBUkgJYEyKAB4pcwgDSCRDSkWwMUUkSgLXbwmQYZa0rgJCQsIARpRsgbbBIhxIuBquANoAujYxIT5+6Mlp0cHCuAAWlIxkuekZwnEJdJq5+QC+ts2NQA`\\r\\n\\r\\n\\r\\n\\r\\n`http://localhost:5601/<REPLACE-THIS>/app/dev_tools#/console?load_from=https://www.elastic.co/guide/en/elasticsearch/reference/current/snippets/86.console`\\r\\n\\r\\nCo-authored-by:\nMatthew Kime\n<[email protected]>\",\"sha\":\"e6e4e343aa700f1b489915f8df233a0abf2ea058\"}},\"sourceBranch\":\"main\",\"suggestedTargetBranches\":[],\"targetPullRequestStates\":[{\"branch\":\"main\",\"label\":\"v9.0.0\",\"branchLabelMappingKey\":\"^v9.0.0$\",\"isSourceBranch\":true,\"state\":\"MERGED\",\"url\":\"https://github.com/elastic/kibana/pull/196836\",\"number\":196836,\"mergeCommit\":{\"message\":\"[Console]\nFix load_from param (#196836)\\n\\nFixes\nhttps://github.com//issues/195877\\r\\nAddresses\nhttps://github.com//issues/179658\\r\\n\\r\\n##\nSummary\\r\\n\\r\\nThis PR fixes the bug in Console where using the\n`load_from` param in\\r\\nthe URL made Console uneditable because every\nre-render reset the\\r\\ninitial value in the editor. This is fixed by\nrestricting the hook to\\r\\nonly set the initial value once. This PR also\nadds some unit tests for\\r\\nthe hook, as I realized that this was a\nlong-standing improvement.\\r\\n\\r\\n### How to test:\\r\\n\\r\\nTry loading\nthe following URL (making the necessary replacement in the\\r\\nURL) and\nverify that the data is correctly loaded into the editor and\\r\\nvalue\ncan be\nedited:\\r\\n\\r\\n\\r\\n`http://localhost:5601/<REPLACE-THIS>/app/dev_tools#/console?load_from=data:text/plain,AoeQygKgBA9A+gRwK4FMBOBPGBDAzhgOwGMB+AEzQHsAHOApAGwbiMoaQFsDcAoAbx5QoAImToMwgFwiAZgCVKAWShoUHSgBcUAWgBUkgJYEyKAB4pcwgDSCRDSkWwMUUkSgLXbwmQYZa0rgJCQsIARpRsgbbBIhxIuBquANoAujYxIT5+6Mlp0cHCuAAWlIxkuekZwnEJdJq5+QC+ts2NQA`\\r\\n\\r\\n\\r\\n\\r\\n`http://localhost:5601/<REPLACE-THIS>/app/dev_tools#/console?load_from=https://www.elastic.co/guide/en/elasticsearch/reference/current/snippets/86.console`\\r\\n\\r\\nCo-authored-by:\nMatthew Kime\n<[email protected]>\",\"sha\":\"e6e4e343aa700f1b489915f8df233a0abf2ea058\"}}]}]\nBACKPORT-->\n\nCo-authored-by: Elena Stoeva <[email protected]>"}}]}] BACKPORT-->
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Labels
Feature:Console
Dev Tools Console Feature
impact:high
Addressing this issue will have a high level of impact on the quality/strength of our product.
Team:Kibana Management
Dev Tools, Index Management, Upgrade Assistant, ILM, Ingest Node Pipelines, and more
v8.16.0
v9.0.0
If you navigate to console and have a load_from param, you wont be able to make any changes in the editor as it keeps reseting itself.
For testing purposes the following URL can be used:
http://localhost:5601/wcm/app/dev_tools#/console/shell?load_from=data:text/plain,AoeQygKgBA9A+gRwK4FMBOBPGBDAzhgOwGMB+AEzQHsAHOApAGwbiMoaQFsDcAoAbx5QoAImToMwgFwiAZgCVKAWShoUHSgBcUAWgBUkgJYEyKAB4pcwgDSCRDSkWwMUUkSgLXbwmQYZa0rgJCQsIARpRsgbbBIhxIuBquANoAujYxIT5+6Mlp0cHCuAAWlIxkuekZwnEJdJq5+QC+ts2NQA
The text was updated successfully, but these errors were encountered: