-
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
Start using InstigationTick.scheduledExecutionTimestamp when rendering the schedule timeline #26823
base: consecutivefailurecount2
Are you sure you want to change the base?
Conversation
ac79a45
to
534f6a6
Compare
Deploy preview for dagit-core-storybook ready! ✅ Preview Built with commit 8a034bd. |
534f6a6
to
03ddbad
Compare
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.
lgtm!
03ddbad
to
8a8cb74
Compare
ae401a6
to
55088ae
Compare
…g the schedule timeline Summary: Right now schedule ticks smush two separate concepts into the 'timestamp' field: the time the schedule tick was supposed to run, and the time it actually ran. This means that if the tick fails and retries, the retry overwrites the original tick in a confusing way, and also means that if a tick happens way after its scheduled time for whatever reason (e..g the daemon was down) the resulting duration is much longer than it should have been. The plan is to alleviate those issues by moving the 'timestamp' field to be the itme that the tick actually started, and add a new 'scheduledExecutionTimestamp' field for when you when you want to know when it was supposed to happen. This PR adds the new "scheduledExecutionTimestamp" field to the tick object and uses it where appropriate to keep the existing behavior. I think more substantial design changes will likely need to be made to the schedule timeline view to display both timestamps where appropriate, but wanted to send this out to seed that discussion.
8a8cb74
to
8a034bd
Compare
@@ -133,7 +133,7 @@ const TickDetailsDialogImpl = ({tickId, tickResultType, instigationSelector}: In | |||
<> | |||
<span>Tick for {instigationSelector.name}: </span> | |||
<TimestampDisplay | |||
timestamp={tick.timestamp} | |||
timestamp={tick.scheduledExecutionTimestamp ?? tick.timestamp} |
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 all looks good but I want to sanity check the ordering here, I'd assumed from the PR description that the old behavior was the inverse of this -- the time it actually executed, if it did execute, and the time it is scheduled for, if it did not yet execute. If that's the case I think these would be tick.timestamp ?? tick.scheduledExecutionTimestamp
, since tick.scheduledExecutionTimestamp
is the one that is always present?
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.
edit: Ahh I see, maybe this is falling back to tick.timestamp
for back-compat so this is more of a "new version ?? old version". Carry on!
Summary:
Right now schedule ticks smush two separate concepts into the 'timestamp' field: the time the schedule tick was supposed to run, and the time it actually ran. This means that if the tick fails and retries, the retry overwrites the original tick in a confusing way, and also means that if a tick happens way after its scheduled time for whatever reason (e..g the daemon was down) the resulting duration is much longer than it should have been.
The plan is to alleviate those issues by moving the 'timestamp' field to be the itme that the tick actually started, and add a new 'scheduledExecutionTimestamp' field for when you when you want to know when it was supposed to happen.
This PR adds the new "scheduledExecutionTimestamp" field to the tick object and uses it where appropriate to keep the existing behavior. I think more substantial design changes will likely need to be made to the schedule timeline view to display both timestamps where appropriate, but wanted to send this out to seed that discussion.
Summary & Motivation
How I Tested These Changes
Changelog