ci(release): bound macOS build steps with timeouts#324
Merged
Conversation
Issue: the v0.65.5 release stalled because the x86_64 build on the Intel runner hung mid-compile and, with no timeout configured, would have sat there until the 6-hour Actions limit, blocking the release and the Homebrew formula update. Solution: add a 30-minute job-level timeout as a backstop, plus tighter per-step timeouts on the two steps that can stall (20m for the build, 10m for the dependency prefetch). A normal job finishes in under 10 minutes, so these leave comfortable headroom while turning a multi-hour hang into a fast failure that frees the runner. The existing retry loop still covers transient non-zero failures.
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.
Solution
The v0.65.5 release run stalled: the x86_64 build on the
macos-15-intelrunner hung partway throughzig build, and because nothing capped its runtime it would have stayed there until the 6-hour Actions limit. That blocks the release and the downstreamupdate-formulajob, which needs both matrix legs to finish. The arm64 leg, by contrast, completed in under 5 minutes, and every recent release has finished in 7–10 minutes total.This adds GitHub Actions timeouts so a hang fails fast instead of sitting for hours:
timeout-minutes: 30onbuild-macosas a hard backstop.timeout-minutes: 20on Build release — the step that actually hung.timeout-minutes: 10on Prefetch Zig dependencies — the other network-bound step.Normal jobs finish well under 10 minutes, so these limits leave 2–3× headroom and won't trip on a genuinely slow-but-healthy run. The existing
for i in 1 2 3retry loop is untouched and still covers transient non-zero failures.I considered wrapping each build attempt in a
timeoutcommand so a hang would feed back into the retry loop, but the dev shell doesn't includecoreutilsand macOS runners don't shiptimeoutnatively, so that would mean a new dependency. The built-intimeout-minutesreaches the same outcome without one.Test plan
workflow_dispatchrun) completes both matrix legs within the new limits.timeout-minutesboundary rather than running indefinitely.