Repository navigation
fix(ci): grade every non-merge commit a PR proposes - #45
Merged
Merged
Conversation
The commit convention gate judged exactly one commit, the PR tip. When GitHub's own Update-branch button makes the tip a merge commit, a conforming PR goes red; and a branch where only the tip conforms passes regardless of its other commits (#37). Grade the base..head range instead (before..head on push), exclude merge commits, name every offender by sha, and fail loudly when the range is unresolvable or contains no non-merge commits rather than reporting a vacuous pass. Fetch depth is pinned to 0 so the range always resolves. Closes #37
|
Warning Review limit reachedNext included review available in 59 minutes. View limit detailsLimit details: You’ve used the included review currently available. You've used all free OSS reviews for now. Wait for the free limit to reset to keep reviewing this public repository. Review configuration: ⚙️ Run configurationConfiguration used: Organization UI Review profile: ASSERTIVE Plan: Advanced Run ID: 📒 Files selected for processing (1)
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
|
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.



Fixes #37.
What changed
.github/workflows/ci.yml, Repo hygiene job:git log --no-merges <base>..<head>— instead of only the tip. Onpushit grades<before>..<head>(tip alone when the ref has no recorded before-sha).--no-merges): a PR whose head is a merge commit created by GitHub's own Update branch button but whose own commits all conform now passes.::errorannotation, not just the subject.fetch-depth: 0), and an unresolvable range fails loudly (cannot resolve <sha> ... refusing to grade zero commits).no non-merge commits ... refusing a vacuous pass) — a gate that examines nothing must not report success.Acceptance criteria check
--no-merges base..headrangefetch-depth: 0); unresolvable range fails loudlyLocal verification
Extracted the exact step script and ran it against a synthetic repo:
::error::commit ea57869... fails the conventional pattern: broken subject hererefusing a vacuous passcannot resolve deadbeef...; refusing to grade zero commitsRepo hygiene gates (
check-format.sh,check-lint.sh,check-spdx.sh,config/ci/lintSource.jlequivalent) pass on this branch. YAML validated.