-
Notifications
You must be signed in to change notification settings - Fork 159
[APP-511] fix: explore workspace initialization #8558
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
base: main
Are you sure you want to change the base?
Conversation
| statusCode={404} | ||
| /> | ||
| {:else if exploreName && metricsViewName} | ||
| {#if ready} |
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 check adds an edge case as mentioned by @ericokuma . Another scenario where a blank page is shown,
- Start app.
- Go to explore directly.
- Open visual editing. You will see a blank page.
This is because DashboardStateManager is responsible for creating explore store for the given name. So adding it behind an if that check that depends on presence of explore store leads to a deadlock.
Since stateManagers is created only if a metricsViewName is present and we are already checking for it a line above then can we get rid of the ready check here?
| // This needs to change, but this is a workaround for now | ||
| $: if (visualEditing) { | ||
| stateManagers.metricsViewName.set(metricsViewName); | ||
| $: if (visualEditing && stateManagers && metricsViewName) { |
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.
Do we still need this if we are keying based on metricsViewName?
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. metricsViewName can be undefined in the ExploreWorkspace if there is an error further up the DAG. It's really just a types thing, though. The check really only needs to be for stateManagers
Brings elements of #8518 to the Explore Workspace to fix a few initialization bugs and clean things up for #8501.
Namely, this ensures that the
VisualExploreEditingcomponent doesn't render until an underlyingexploreStoreis available. This fixes a bug that prevented theVisualExploreEditingcomponent from receiving updates to theExploreStateobject.Checklist: