Update 'noExperiments' context after trace open #297
Merged
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.
What it does
Fixes #296.
Triggers an update to the 'trace-explorer.noExperiments' context after a trace or experiment is opened.
How to test
The steps to reproduce the bug can be found in #296.
The bug can be reproduced on
master
The bug should be fixed on this branch.
Follow-ups
When the server is online, the context is properly updated by a vscode-message sent from the frontend recieved by the backend.
Frontend:
Backend:
I'm not sure why this code is triggered when the server is online and not when the server is offline. I didn't dig too deep into investigating that because I'm not sure the relevancy, and I know that the events getting bounced around on the FE / BE can get really messy and hard to trace.
There is also the tracking of
initialized
and we may simply not be sending the first signal intentionally. This can be investigated because it may not be necessary to track anymore and could lead a cleaner solution.I didn't deep dive into this. I think updating the context on the backend after a trace is opened is a reasonable approach. WDYT?
Review checklist