feat: auto-strip candidate changes block from CHANGELOG on PR merge#102
Merged
hdamker merged 3 commits intocamaraproject:release-automationfrom Mar 3, 2026
Merged
Conversation
Strip the AUTOGENERATED:CANDIDATE_CHANGES block from the CHANGELOG when the Release Review PR is merged, ensuring raw candidate changes never leak into draft or published releases. Changes: - Workflow: strip markers + commit cleaned CHANGELOG to snapshot branch - Template: update wording to "auto-removed on merge" with editing permission - PR checklist: replace manual removal checkbox with distribution task - Bot comment: add conditional confirmation when block was stripped - BotContext: add candidate_block_stripped field - Tests: update assertions for new template text (510 pass)
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.
What type of PR is this?
enhancement/feature
What this PR does / why we need it:
Auto-removes the
<!-- AUTOGENERATED:CANDIDATE_CHANGES -->block from the CHANGELOG when the Release Review PR is merged into the snapshot branch. This prevents working-area content (candidate change listings, instruction text, HTML comment markers) from leaking into draft releases.Changes:
handle-pr-mergejob): detects markers in fetched CHANGELOG, strips the block (or orphan markers), commits the cleaned file back to the snapshot branch using the App tokenrelease_section.mustache): updated from "must be removed before merge" to "auto-removed on merge" with explicit editing permissionrelease_review_pr.mustache): replaced "remove candidate changes block" with the codeowner's actual job — "all relevant changes copied into Added/Changed/Fixed/Removed"draft_created.md): conditional confirmation line when block was strippedcandidate_block_strippedfieldEdge cases handled:
Which issue(s) this PR fixes:
Special notes for reviewers:
Tested end-to-end on
hdamker/TestRepo-QoD(PR #99):draft_createdbot comment includes "Release notes cleaned (candidate block removed)."Re-trigger safety: the commit to
release-snapshot/*does not match the caller workflow'spushtrigger (filtered tobranches: [main]+paths: [release-plan.yaml]).Changelog input
Additional documentation