🐛 fix(changelog): tolerate a tagged-but-unstamped HEAD in the drift gate (D-181) - #135
Merged
Merged
Conversation
…ate (D-181) Between pushing a release tag and landing its stamp commit, any verify run that checks out the tagged SHA (a re-run, or the weekly schedule on an unchanged main) rendered the new section, found it missing and went red. release.yaml's verify-green tag gate (REQ-AUD-S03-01) needs every verify run on the SHA to be green, so one such red locked the tag out of its release. verify-changelog.sh now, after the normal diff fails, re-renders the committed form with --ignore-tags for exactly the v* tags pointing at HEAD. If CHANGELOG.md equals that pre-tag render it passes with a notice naming the stamp to land (a ::warning:: under GITHUB_ACTIONS). A hand edit or a history re-render on the tagged HEAD, an unstamped tag with any commit on top, and an older unstamped tag behind a newer tagged HEAD all stay red. render-changelog.sh forwards extra arguments to git-cliff for this. changelog_gate_test.sh §10c pins both polarities; three mutants (no allowance, allowance without the pre-tag comparison, allowance keyed on the newest reachable tag instead of HEAD's) each red the suite.
…nday release rules
…unstamped commit (D-181, review F1) CI runs all of `task check` in release-exitgate (hack/audit/exitgate_test.sh), so the drift-gate allowance alone did not close the REQ-AUD-S03-01 lockout: changelog_gate_test.sh still went red on the tag SHA, at §1 (newest section vs newest tag) and at the §10 baseline, whose overlay commit sat on top of the tag. Measured stage by stage on a freshly tagged clone, those were the only reds. §1 now reads verify-changelog.sh's own allowance from its output and warns instead of failing on that commit only; the §10 sandbox drops HEAD tags whose section is missing, so it starts from the pre-tag state. New §10e runs this whole script nested on a tagged-but-unstamped clone (green) and with a commit on top (red); mutants removing either fix red it. Also from the review: rows for a release and its -rc on one commit and for regex escaping of the HEAD tag (a mutant without escaping reds), a failed pre-tag render falls through to the diff, the stamp hint names the release tag rather than a pre-release, and the tag-glob comment is corrected. Docs and the D-181 record now say what the code does.
… releases (D-181, review N1/N2) §10e committed its overlay with a cliff-skipped subject, so on a HEAD where every commit since the newest tag is skipped (right after every stamp commit) its v98.0.0 was an empty release, git-cliff omitted it, and the nested §1 went red: main would have been red after every release. The overlay now uses a rendering subject, with a positive control that v98.0.0 renders a section. §1 is now a function, newest_section_check, and also accepts a newest tag that renders no section while the drift gate is plainly green (the file is then byte-identical to the render of every tag, so nothing is missing): a tooling-only release no longer reds its tag SHA and main forever. §10e grades the stamp commit and such an empty release through the function directly.
… no stamp (D-181, review R1)
|
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.



No description provided.