Repository navigation
Show no progress for a queued run, and its whole estimate as the ETA [patch] - #369
Merged
Merged
Conversation
…[patch] A pending run counted the time since Started as build time, so a run sitting in the queue drew a growing progress ring, percentage and a shrinking ETA before it had begun. The row's duration, ETA and progress now come from MeasureRun, which treats a pending run as zero elapsed: no progress, and the full estimate as its ETA. Running and finished runs are measured as before. Run.IsOngoing still includes Pending, so polling of queued runs is unchanged. Fixes #364 Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01GKJwMybTmY6x4mJfMM9RKv
|
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
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.



Fixes #364
What changed
RenderBuildBranchRowColumnsmeasured every ongoing run fromStarted, and that includedPendingones. A run that was still waiting in the queue showed a growing progress ring, a percentage and a shrinking ETA before any build work had started.The row's duration, ETA and progress now come from a new
BuildMonitor.MeasureRun(Run, TimeSpan estimate):Clock.UtcNow - Started, the same as before.Run.Duration, the same as before.The providers'
StartedThe issue asked me to check what each provider puts in
Started:RunStartedAt, which is set when the run attempt is created, while it is still queued.StartTime ?? QueueTime, so a run that hasn't started gets its queue time.Either way,
Startedon a pending run means queue time. This fix doesn't depend on which provider set it.Deliberately not changed
Run.IsOngoingstill includesPending, andRun.CalculateETA(whichRunSyncuses to pick the poll interval) is unchanged. So queued runs are still polled at the same rate and their start is picked up as quickly as before. Running the queue-aware ETA through polling as well would have stretched a pending run's poll interval to the 60 s maximum.Tests
RunProgressTests, usingClock.UtcNowOverride: pending, running and finished cases.Startedthe old way, and passes with the fix.BuildMonitor.Test: 141/141 pass.tests/BuildMonitor.UITests: 6/6 pass.🤖 Generated with Claude Code
https://claude.ai/code/session_01GKJwMybTmY6x4mJfMM9RKv
Generated by Claude Code