Repository navigation
CI: one gate job as the only required build check - #129
Merged
Merged
Conversation
dotnet.yml gains a `CI` job that needs every lane, runs `if: always()` and passes only when each lane reports `success`. GitHub reports a skipped job as Success even on a required check, so a skipped or cancelled lane fails the gate too. WorkflowGateConventionTests holds the gate to that rule: every other job is in its needs, it runs always(), it reads toJSON(needs) whole, it fails any result but success, and it still reports as `CI`. Co-Authored-By: Claude Opus 5.5 <[email protected]>
This was referenced Oct 20, 2026
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.
Closes #110
Problem
mainrequires four job names:Test (ubuntu-latest),Pack,Integration (PostgreSQL 18)andConsumer smoke test. GitHub reports a skipped job as Success, even on a required check, so those checks cannot tell an intended skip from an accidental one. Every new lane also costs a protection edit on every protected branch:Integration (SQL Server 2022)(#100) runs today and is required nowhere.Change
.github/workflows/dotnet.yml: aCIjob that needs all five lanes, runsif: always(), readstoJSON(needs)and fails on any result exceptsuccess. It writes a job/result table to the job summary. Skipped and cancelled lanes fail it, because no lane is skipped on purpose until CI: select the PostgreSQL, SQL Server, consumer and pack lanes from a derived map CodoMetis.EFCore.SchemaKit#12.test/…/WorkflowGateConventionTests.cs(new) andHarness/WorkflowFile.cs(a small reader for workflow jobs andneeds): every other job indotnet.ymlis in the gate'sneeds, the gate runsalways(), it readstoJSON(needs)and fails on anything butsuccess, and it reports asCI(and no other job does).CLAUDE.md(CI section and the quality-controls table),CONTRIBUTING.mdandROADMAP.md: the required check formainandrelease/5.xis nowCI.No changelog line, since nothing a consumer sees changes.
Tests
Proof runs, dispatched on throwaway branches (now deleted), each with one lane seeded:
CIproof/110-lane-failsexit 1proof/110-lane-skipsif: falseproof/110-lane-cancelledtimeout-minutes: 1+sleep 300chore/110-ci-gateIn the skip proof every lane except the skipped one is green. Under today's four required checks that PR would merge.
Guard: each of these seeds fails
WorkflowGateConventionTests:consumerdropped fromneeds,packdropped from a block-listneeds, a newdocsjob outsideneeds,if: always()removed, the gate renamed toGate, and the result check loosened to== "failure". The complete block-list form passes. Unit suite: 490 passed.Branch protection (for you to apply; I changed no settings)
Merge this PR first and wait until
CIhas reported green onmain. If you remove the old names first, every open PR waits for a check that never reports. Then replace main's four contexts with the gate.app_id15368 is GitHub Actions, as today:The issue says
Labels and issue linkmay be required too, because it never stays pending. To require it as well, use"checks": [ { "context": "CI", "app_id": 15368 }, { "context": "Labels and issue link", "app_id": 15368 } ].After the
v5.5.0cut,release/5.xgets the same protection withCI. The full command is in the corrected cut steps on CaffeinatedCoder/EFCore.ComplexIndexes#36.🤖 Generated with Claude Code