-
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
[Lens][Inspector] Close the inspector on Lens unmount #114317
Conversation
@elasticmachine merge upstream |
@elasticmachine merge upstream |
Pinging @elastic/kibana-vis-editors (Team:VisEditors) |
@elasticmachine merge upstream |
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.
the behavior is as expected and the code LGTM :ok
Just FYI, I changed the description so it doesn't close the issue, but checking the visualize app and discover looks like Lens is the only one to fix so maybe it's ok with closing the issue when merging this PR? Let me know :)
@@ -101,7 +101,7 @@ export function App({ | |||
const [isSaveModalVisible, setIsSaveModalVisible] = useState(false); | |||
const [lastKnownDoc, setLastKnownDoc] = useState<Document | undefined>(undefined); | |||
|
|||
const lensInspector = getLensInspectorService(inspector); | |||
const lensInspector = inspector; |
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.
nit: what if instead we do in line 65
const {
data,
chrome,
uiSettings,
inspector: lensInspector,
application,
notifications,
savedObjectsTagging,
getOriginatingAppName,
spaces,
http,
// Temporarily required until the 'by value' paradigm is default.
dashboardFeatureFlag,
} = lensAppServices;
You're right. Maybe I can extends this fix to |
Sure, that sounds great! I'll check it again when it's ready. But I checked it briefly and couldn't make it break on Visualize so maybe it's ok 🤷🏼♀️ Please re-check! |
I think this is just an issue in Lens today, I just re-used the issue. |
💚 Build Succeeded
Metrics [docs]Async chunks
History
To update your PR or re-run it, just comment with: |
I cannot reproduce the issue in Visualize. I'll assign the linked issue to |
* 🐛 First attempt to close the inspector automatically on app unmount * 👌 Integrate feedback Co-authored-by: Kibana Machine <42973632+kibanamachine@users.noreply.github.com>
💚 Backport successful
This backport PR will be merged automatically after passing CI. |
Summary
Fixes for Lens only #45928
This PR anticipate the creation of the inspector wrapper, in order to have a reference in the mounter to call on exit.
Checklist
Delete any items that are not applicable to this PR.
Risk Matrix
Delete this section if it is not applicable to this PR.
Before closing this PR, invite QA, stakeholders, and other developers to identify risks that should be tested prior to the change/feature release.
When forming the risk matrix, consider some of the following examples and how they may potentially impact the change:
For maintainers