Repository navigation
tooling: blocker-initiative tools -- pr_check, one rosetta-audit run, nightly baseline (#4270, 2 of 2) - #4595
Merged
Merged
Conversation
…seline (#4270) - tests/tools/pr_check.py N [--merge]: mergeable state, draft, head SHA, checks grouped (a cancelled run ignored only beside a same-name success on the same SHA), files touched with ratchet/baseline/golden/evidence/ledger and the CICS crucible pin flagged; --merge = ready + squash only when green. - rosetta-audit: label events other than rosetta:rebless-owed skip the job; concurrency moved to the job so the skipped runs cannot cancel the real one. - blocker-baseline.yml: nightly + dispatch `cics_census.py survey --baseline` on main, burned / pinned corpora only (no census clones), blockers.txt/json uploaded as an artifact. Co-Authored-By: Claude Opus 5.5 <[email protected]> Claude-Session: https://claude.ai/code/session_011wnQoeeAZP4npeyGnDviK6
Contributor
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.
Part of #4270 (blocker-initiative tooling, PR 2 of 2: items 5-6). Companion: the baseline cache / history / provision / unmask PR (items 1-4) -- merge that one first: the nightly job here calls
cics_census.py survey --baseline, which it adds. Nothing else here depends on it.tests/tools/pr_check.py N [--merge] [--json]One call: state, draft, head SHA, mergeable state; checks grouped by outcome; files touched with flags. Four REST calls through
gh api(pull, check-runs at per_page=100, combined status, files at per_page=100);gh pr view/editare not used (they fail on this repo).tests/_cics_crucible_pin.py.--merge: only when open, mergeable (not dirty / behind / blocked), nothing failed or pending. Thengh pr ready(falls back to themarkPullRequestReadyForReviewmutation throughgh api graphqlif gh's own path fails) andgh pr merge --squash --match-head-commit <checked SHA>. Otherwise exit 1 with the reasons, nothing merged.Real run on merged #4593:
rosetta-audit ran once per label event -- fixed
Root cause: one workflow, one job -- but triggered on
pull_requesttypesopened, synchronize, reopened, labeled, unlabeled.gh pr create --label a,b,cattaches the labels after the PR exists, so a fresh PR firesopened+ onelabeledper label. The workflow-level concurrency group then cancels all but one: the PR is left with a cancelledrosetta-auditcheck beside the green one.Evidence (
gh api .../actions/workflows/rosetta-audit.yml/runs, #4593, head ab28070):and the PR's events:
labeled enhancement / legacy-modernization / testing, all at 01:47:51Z (PR created 01:47:46Z). Same pattern on every labelled PR that day: #4592 (7a56374: 3 runs, 2 cancelled), #4591 (f585ea5: 3, 2 cancelled), #4590 (7157b86: 3, 2 cancelled), the SEND TEXT slice (74accea: 7 runs, 6 cancelled), #4588 (1b1069b: 3 runs, 1 cancelled -- and two that both ran to success, i.e. the audit ran twice). A plain re-push (synchronize, e.g. f4159d2) ran it once. The check-runs on ab28070:rosetta-audit cancelled+rosetta-audit success.Fix: the
labeled/unlabeledtypes stay (they are howrosetta:rebless-owedreaches the audit), but the job runs on a label event only when that label isrosetta:rebless-owed. Concurrency moves from the workflow to the job, so the skipped label-event runs cannot cancel the real one. Result per fresh PR: one audit run (opened), the label runs show as skipped; adding / removingrosetta:rebless-owedstill re-runs it; a re-push still supersedes the old run. Cannot be proven on this PR's own run until it merges (a PR runs the workflow from its head, so the next labelled PR shows it); this PR's own check list is the first evidence.Nightly blocker baseline (
.github/workflows/blocker-baseline.yml)Nightly (05:17 UTC) +
workflow_dispatch:cics_census.py survey --baseline --no-census --sha $GITHUB_SHAon main,blockers.txt/blockers.json/meta.jsonuploaded as theblockers-<sha>artifact (90 days), the first 40 lines in the step summary. Burned / pinned corpora only (tests/cobol_mainframe/corpora.json, fetched as every CI job fetches them; that manifest also holds the two pinned non-burned corpora dsf / zopeneditor-sample): no census clones in CI, as the owner approved. Locally the burned + local survey takes ~3 min of the 349 s full baseline, so well inside the 60-minute timeout. Nothing is committed.Checks
tests/tools/test_pr_check.py(7): the cancelled-beside-success rule (and a cancelled run with no success stays a failure), skipped-after-success, rerun wins, flags, four calls, not-ready reasons,--mergerefuses red and does ready + squash on green, the GraphQL fallback.pr_gates --only lint) and mypy on pr_check.py clean; secrets gate pass.🤖 Generated with Claude Code
https://claude.ai/code/session_011wnQoeeAZP4npeyGnDviK6