Add rspec-time-guard to catch hanging specs - #33
Draft
apiology wants to merge 3 commits into
Draft
Conversation
Sets a 60s global time limit on specs via the rspec-time-guard gem. Extracted from castwide#1006 (Improve pin caching) as a standalone piece: this is dev/test tooling only, no runtime behavior change, and useful independently of the rest of that PR. Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
apiology
marked this pull request as draft
August 2, 2026 15:52
CI showed the new 60s global time limit tripping on 5 specs that are legitimately slow (gem/bundle resolution, YAML/Thor lookups) rather than hung: ApiMap#get_method_stack's YAML/Thor cases, ApiMap#returns core methods, Host#opens a file outside of prepared libraries, Protocol#handles $/solargraph/documentGems, and Gemspecs#fetch_dependencies's external-bundle cases. Tag each with the same per-example time_limit_seconds override the original PR (castwide#1006) settled on, so this PR doesn't regress CI on its own before the rest of that PR's stacked branches land. Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
The YAML/Psych stdlib resolution spec timed out at 240.33s against a 240s limit in CI - a genuine near-miss (0.14% over), not contention from running multiple PRs' CI concurrently (each job gets its own runner, so concurrent jobs affect queue time, not execution time). Widen that limit and the other 120s limits proportionally to give real headroom against normal run-to-run variance on GitHub Actions' shared runners, rather than re-running and hoping. Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
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.
Extracted from castwide#1006 (Improve pin caching), piece 1 of a chain of PRs breaking that PR into independently-reviewable units before sending them upstream.
Adds a 60s global time limit on specs via the rspec-time-guard gem. Pure dev/test tooling, no runtime behavior change. Independent of the rest of the pin-caching work.
See castwide#1239 for the full rebased PR this is extracted from, and castwide#1006 for the original discussion.