Repository navigation
fix(release): restore changelog when abandoning a release - #2024
Merged
Merged
Conversation
gerchowl
force-pushed
the
bugfix/2003-abandon-unfreeze-changelog
branch
from
November 4, 2026 04:42
e1c22e1 to
266ad73
Compare
gerchowl
force-pushed
the
bugfix/2003-abandon-unfreeze-changelog
branch
from
November 4, 2026 05:07
266ad73 to
ebf89f3
Compare
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.
Description
Abandoning a regular release restores dev's pending changelog entries to Unreleased. Restoration commits are pinned to the checkout SHA so a stale fold cannot silently replace concurrent dev changes. The one-off 1.19.0 repair is generated by the tested command from current dev, preserving concurrent entries and regenerating the mirror.
Type of Change
feat-- New featurefix-- Bug fixdocs-- Documentation onlychore-- Maintenance taskrefactor-- Code restructuringtest-- Adding or updating testsci-- CI/CD pipeline changesbuild-- Build system or dependency changesrevert-- Reverts a previous commitstyle-- Code styleModifiers
!)Changes Made
prepare-changelog unfreeze VERSION [FILE]: combine pending entries and repeated categories, preserve entry order and nested details, and deduplicate whole entries. An absent version is a no-op; dated releases are refused.git rev-parse HEADimmediately after checkout in both abandon workflows and fail if SHA capture fails, and pass it asBASE_SHAto the same Commit App API action used by prepare-release. A non-fast-forward update fails; rerun abandonment from a fresh checkout.The pinned v0.3.3 runner reads
BASE_SHAintobaseSha, and commit.ts uses that fixed base for the tree and commit parent, then updates the ref withforce: false. Retries reuse that base and commit; they do not recompute against a newer dev head.Changelog Entry
Fixed
Testing
just test) — targeted local verification; full suites run in CI.uv run --with pytest-xdist pytest packages/vig-utils/tests/test_prepare_changelog.py tests/test_abandon_release.py tests/test_seed_changelog.py tests/test_workflow_model.py -n 4 --basetemp=$HOME/.cache/devkit-pytest/2003-r2-capture-green: 251 passed, exit 0.RED tests were committed before implementation: 11 failures covering the checkout-SHA wiring and command edge cases (exit 1), plus two failures covering mixed newline styles in untouched release history (exit 1), and two failures proving SHA-resolution errors must stop the job (exit 1).
Replay tests execute the SHA-capture step from each actual workflow, advance the fixture branch, then resolve the API action's environment and prove
BASE_SHAremains the original checkout output. Command tests cover category merging, duplicates, empty sections, reruns, missing versions, dated-version CLI refusal, CRLF, untouched history, unsupported prose/comments, error section names and entry spacing.Manual Testing Details
Rebased onto current dev, regenerated the repair with
prepare-changelog unfreeze 1.19.0 CHANGELOG.md, and ranscripts/sync_manifest.py sync assets/workspace/. Verified all merged category contents retain their order; #1955, #2025 and #2011 occur once each; released history and the empty consumer seed are unchanged. No release workflow was dispatched.Checklist
CHANGELOG.mdin UnreleasedAdditional Notes
The changelog moves are the one-off pending-section repair. Published release sections are not changed. The concurrency failure intentionally leaves the workflow failed rather than rebasing stale file contents onto a newer dev head.
Refs: #2003