Repository navigation
ci: draft PRs skip the heavy PR workflows (#5104) - #5105
Conversation
…em (#5104) Every heavy pull_request workflow lists ready_for_review in types and gates every job on github.event_name != 'pull_request' || draft == false. ruff/mypy/small-audits/answer-key-guard keep running on drafts. Skipped checks read as green, so the shepherd only marks a draft ready (auto-merge next pass) and pr_check --merge marks a draft ready without merging it. Guard test added. Co-Authored-By: Claude Sonnet 5.5 <[email protected]>
|
No description provided. |
|
PR #5105 @ fb7c9a8: 1 failed check(s) == db2 3/4 (failure) -- real |
Fixes #5104. Workflow edits are allowed by the owner for this PR (queue item
allow_workflows); please review the workflow diff carefully.What changed
pull_requestworkflows:types: [opened, synchronize, reopened, ready_for_review](det-sweep and rosetta-audit keep their own types, plusready_for_review) and a job-level condition on every job that can run on a PR:github.event_name != 'pull_request' || github.event.pull_request.draft == false, ANDed with the job's existingif. A baredraft == falsewould be null-false on push/schedule/dispatch and disable those runs; theneeds:chained andalways()jobs (det,full-suite, thetested-treegates) each carry it too, since a skippedtested-treeleavesoutputs.skipempty and would let its dependents run.ruff-audit,mypy-audit,small-audits,answer-key-guard(run on drafts);pull_request_target(shepherd-event.yml);full-suite-gate.yml.ready+auto-mergein the same pass, so auto-merge could have fired before theready_for_reviewruns existed. Nowshepherd_gh.decide()only emitsreadyfor a draft (auto-merge on the next pass, whichshepherd-reconciletriggers when the real runs finish), andpr_check.merge()(also used byci_shepherd.py) marks a draft ready without merging it. A draft itself can never merge.tests/core_engine/test_workflow_draft_gate.py: guard test (cheap-audit allowlist,ready_for_reviewin types, every job gated, non-PR jobs allowlisted,pull_request_targetuntouched, self-tests).docs/ci.md: one paragraph.test_pipeline_pins.pyline numbers,test_tested_tree_workflows.py(gate may carry only the draft condition), fake-PR defaults intest_pr_check/test_ci_shepherd.Verification
pyteston the touched tests (311 pass);pr_gates.py --fast6/6. Not proven in CI: this PR is a draft, so the heavy workflows should NOT start on it (only the four cheap audits); marking it ready should start the full set.Cross-repo
None.
🤖 Generated with Claude Code