Repository navigation
fix(cli): fail verify when the time limit leaves gate checks unrun - #260
Merged
adityankale190895 merged 3 commits intoNov 18, 2026
Merged
Conversation
runChecks marks checks not_run when the budget is used up, but verify ignored outOfTime, ran the tests with no limit and reported the checks as skipped. Stop before the tests and fail the verdict instead. Fixes DiffCI#259 Signed-off-by: FredApps <[email protected]>
Contributor
Author
|
Cross-review (FredApps, head 1ec51e3). Not an approval. Checked
Fixed: nothing pushed. Open
|
Every check could run and still use the whole --timeout-ms budget, for example a failing check whose base rerun shows it also fails at the base. The tests then started with a 0ms limit, which means no limit. They now do not start and the verdict fails. A base rerun with no time left is reported as unknown instead of running with no limit. Fixes DiffCI#259 Signed-off-by: FredApps <[email protected]>
Contributor
Author
|
Follow-up on the open point in the cross-review: checks that run but use the whole budget. Real. On this branch before the fix, a failing check whose base rerun showed it also fails at the base used the whole Fixed in 977110d
CI: all checks pass on 977110d. Still open: |
… cleanly with DiffCI#276 No behavior change. DiffCI#276 adds redactReceipt at the same spot after verifyCommitRange, which made the two PRs conflict. Signed-off-by: FredApps <[email protected]>
FredApps
marked this pull request as ready for review
November 18, 2026 01:19
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 #259
Changed behavior
When the
--timeout-msbudget runs out before a gate check starts,verifyno longer runs the tests with no time limit and reports passed. It now stops before the tests, records a timed-out execution, and fails the verdict with the reasongate check(s) <ids> did not run within the <N>ms time limit; tests were not run. The failure baseline is not compared in that case, as with a failed check.Behavior is unchanged when every check runs.
Validation
tests/client/verify-check-timeout.test.ts: a failing gate check withtimeoutMs: 0. It fails on main (verificationispassed) and passes with this change.node --import tsx --test tests/client/verify-*.test.ts tests/client/gate-checks.test.ts: 47 passed.tsc --noEmit -p packages/diffci-cli: clean.release-files.json.Checks that use the whole budget (follow-up)
Every check can run and still use the whole
--timeout-msbudget, for example a failing check whose base rerun (--baseline-on-failure) shows it also fails at the base. The tests then started with a limit ofMath.max(..., 0)= 0, which means no limit. Now:gate checks used the whole <N>ms time limit (<M>ms); tests were not run, and the failure baseline is not compared.unknown("the time limit ran out before the base run") instead of running with no limit.Two cases are added to
tests/client/verify-check-timeout.test.ts. They mockDate.nowso that the check uses the whole budget once it has run, because real time cannot reliably reproduce an overrun the check's own timeout caps. Both fail without this change: the first reportspassed, and the second reruns the check at the base (preexisting).Conflict with #276:
checksOutOfTimenow sits aftercheckSummaryinstead of at the spot where #276 addsredactReceipt, so the two merge in either order.