Repository navigation
fix(ci): check PR titles without stripping a trailing issue reference - #1819
Conversation
The conventional-commit policy stripped a trailing "(#N)" from every message, including PR titles. #1810's title ended in "(#1780)", passed as if that were the PR number, and integrated as "... (#1780) (#1810)", which the main check rejects. Main CI failed at the 9.5.0 release commit, so Release publish refused to publish 9.5.0. PR titles are now checked as written, since the squash appends the PR number only at integration. 272fced keeps its subject through an exact-commit-and-subject exception, like the historical breaking-footer ones. Every main commit since the policy floor validates. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
There was a problem hiding this comment.
Ladon verdict: Approve
Approve — clean CI-tooling fix with full test coverage.
This PR touches only scripts/check_main_policies.py and tests/test_main_release_policies.py (CI tooling, no public surface or wire change). It fixes a conventional-commit release-policy bug: a PR title ending in an issue reference like "(#1780)" was stripped as if it were the squash-appended PR number, so the squash appended a second "(#1810)" and landed "...(#1780) (#1810)" on main, failing push-time validation. The new integrated flag keeps a trailing "(#N)" in the description for PR titles so the case is rejected at PR time, and a sha+subject-pinned HISTORICAL_DESCRIPTION_SUBJECTS exception un-breaks the one already-landed commit (272fced).
Checked: narrowly scoped, cannot be abused from the PR path, double-reference subjects still reject, and tests cover the integrated split and the exact-match exception.
Decision table: no critical/high/medium findings; gated_paths is false; high_risk is false; no no-auto-approve team match; no prior decision. Note review_decision is REVIEW_REQUIRED, but row 2 only fires when gated_paths is true. Falls through to row 9 → approve.
9.5.0 never reached PyPI. Main CI failed at the release commit
e45e1b8, so Release publish stopped at "Wait for successful main CI at the release commit".Cause: Validate conventional commit format rejected
272fced5, #1810's squash commit:feat(decisioning): let a raised AdcpError reject a request with every error (#1780) (#1810). The policy strips one trailing(#N)and then forbids parentheses in the description. On the PR, the title's own(#1780)was stripped as if it were the PR number, so it passed. After the squash appended(#1810), it failed on main.Fix (
scripts/check_main_policies.py):validate_message(..., integrated=False)for PR titles. A PR title has no PR number until the squash, so a trailing(#N)is part of its description and is rejected up front.HISTORICAL_DESCRIPTION_SUBJECTSexempts exactly272fced5with exactly that subject, the same pattern asHISTORICAL_BREAKING_SUBJECTS.Tests:
(#1174)now use the title without it.PUBLISHED_BASE(258) validates with the patched script.Release: 9.5.0's tag stays where it is. CI at
e45e1b8runs the old script and will keep failing, so thisfix(ci)commit should make release-please propose 9.5.1, which carries 9.5.0's changes to PyPI.🤖 Generated with Claude Code