Document CI wait pattern and add cross-references#9
Merged
nkhdiscovery merged 1 commit intomainfrom Apr 29, 2026
Merged
Conversation
…til loop Agents were improvising CI polling after `sleep` was blocked, landing on `until <SUCCESS-check> | grep -q true` — which loops forever when CI fails because the jq expression returns "false", never the exit condition. Add a "Waiting for CI to finish" section with an `until` loop that conditions on pending checks (QUEUED/IN_PROGRESS) dropping to zero — exits on pass or fail. Update both work-loop paths (A and B) to reference it. https://claude.ai/code/session_01Gi8TE7TAj99334RqTfLPQx
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.
What this does
Adds a new "Waiting for CI to finish" section to the unattended rules that documents the correct polling pattern for waiting on CI checks to reach terminal state. Updates three existing references throughout the document to point to this new section, ensuring engineers follow the documented pattern instead of using blocking sleeps or incorrect loop conditions.
Issue / deliverable
Improves operational clarity for unattended PR workflows by centralizing CI wait logic and preventing common mistakes (blocked sleeps, infinite loops on CI failure).
ADRs referenced or introduced
None.
Checklist
Risk / blast radius
Internal to documentation only. No code changes, no runtime impact.
https://claude.ai/code/session_01Gi8TE7TAj99334RqTfLPQx