-
Notifications
You must be signed in to change notification settings - Fork 1.5k
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
[ui] Global AMP: Fix timeline pagination #26353
Conversation
@@ -72,6 +73,11 @@ export const GlobalAutomaterializationContent = () => { | |||
[fetch, getVariables], | |||
); | |||
|
|||
// When the variables have changed (e.g. due to pagination), refresh. |
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.
Hmm... I think I was relying on useRefreshAtInterval
doing this... I think it should but also okay with requiring callsites to do it themselves. i'll leave it up to you.
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.
Ah, I had noticed that the useRefreshAtInterval
is disabled (below) when a time range is applied, so I understood it to mean that the query only refreshes on the first page. (Which I think makes sense, since viewing an older page means the data should be static.)
Deploy preview for dagit-core-storybook ready! ✅ Preview Built with commit 1182f1c. |
## Summary & Motivation In the global AMP view, the tick timeline is broken when paginating to older ticks. The (paginated) table view sets the parent's time range, but the time range isn't being used as a signal to refetch the list of ticks used by the timeline. Fix this with an effect. ## How I Tested These Changes View AMP overview for Discord. Page backward in time, verify that the timeline updates with the correct ticks displayed. ## Changelog [ui] Fix global auto-materialize tick timeline when paginating.
Summary & Motivation
In the global AMP view, the tick timeline is broken when paginating to older ticks. The (paginated) table view sets the parent's time range, but the time range isn't being used as a signal to refetch the list of ticks used by the timeline. Fix this with an effect.
How I Tested These Changes
View AMP overview for Discord. Page backward in time, verify that the timeline updates with the correct ticks displayed.
Changelog
[ui] Fix global auto-materialize tick timeline when paginating.