recover-pending-cut fold-back silently drops [Unreleased] text outside an accepted ### heading #1491
Labels
No labels
bump
major
bump
minor
bump
patch
kind
bug
kind
chore
kind
docs
kind
epic
kind
feature
loop/paused
mirror-drift
priority
critical
priority
high
priority
low
priority
medium
size
L
size
M
size
S
size
XL
status
blocked
No milestone
No project
No assignees
1 participant
Notifications
Due date
No due date set.
Dependencies
No dependencies set
Reference
frankenbit/release-toolkit#1491
Loading…
Reference in a new issue
No description provided.
Delete branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
rt recover-pending-cut(recovery B) folds a stranded section back under## [Unreleased]withchangelog.FoldBackIntoUnreleased(internal/changelog/foldback.go). When[Unreleased]is already non-empty, it merges the two bodies throughchangelog.MergeSections. That merge drops every line that is not under an accepted### <Kind>heading. It is the same mechanism #1486 makesrt preprefuse.Measured
Go probe calling
FoldBackIntoUnreleased(cl, "0.2.0")on the #1486 tree, 2026-10-02.foldback.gothere is unchanged frommain@02fae6a.[Unreleased]before:Pending section
[v0.2.0]:Result:
err=nil, and[Unreleased]after is:The prose and the whole
### Notesblock are gone. The empty-[Unreleased]splice path is not affected: it carries the section's lines verbatim.Why it matters
The deleted text never reaches the next
rt prep, so #1486's refusal cannot catch it: prep only sees what recovery left behind. An operator who runs the documented recovery loses hand-written notes, and the verb exits 0.Acceptance criteria
[Unreleased], recovery refuses and writes nothing whenchangelog.UncarriedLinesreports any line of the[Unreleased]body. The refusal names each line and the accepted headings (changelog.MergeKinds), asrt prepdoes after #1486. — DONE @ #1493 (2060ed1, reviewed as2060ed1)MergeSections' second argument, so the current kind carries over from[Unreleased], andUncarriedLinesis documented as exact only for the first argument. — DONE @ #1493 (2060ed1, reviewed as2060ed1). It is checked on its own. Lines above its first heading are refused too, and the refusal says whether the merge would move or drop each one. #1493's decision tree records why.[Unreleased]splice path stays byte-identical. — DONE @ #1493 (2060ed1, reviewed as2060ed1)mainand mutation-verified (AGENTS.md section 8, Axis B). — DONE @ #1493 (2060ed1, reviewed as2060ed1). The tests were red on the pre-fix tree, with a behaviour-free stub of the new type: they referenceFoldBackDropError, which #1493 adds, so they do not compile on the oldmain. Mutation runs: 19/19 killed at0935704, and 5/5 for the verb at2060ed1.Notes
UncarriedLinesandMergeKinds.FoldBackIntoUnreleasedExcept. Not checked: whether its diff changes the merge arm. Whichever lands second rebases onto the other.subtractCovered). Since #1493, both bodies are[]fileRecord, and the grading reads the same records the merge is fed. Rebasing #1490 only needssubtractCoveredto filter records.Landed on
mainas2060ed13ffb3834928b2aad3a32916eab485acb3via #1493 (rebase merge, 2026-10-02 12:20:51).ff3345f,0935704and2060ed1landed with their reviewed SHAs.git range-diff 55a12b9..2060ed1 55a12b9..origin/mainshows=for all three, and the trees match.2060ed1, the merged head. For the record, it was submitted at 12:14:41. That is inside the HOLD window for the re-review 7160 nit (HOLD comment 113878 at 12:11:01, released by 113882 at 12:16:12), so it is outside the AGENTS.md section 6.2 order. The approved SHA is the SHA that landed.ff3345f) and 7160 (at0935704) were posted as COMMENT, because that account authored the PR. The reviewing session reports verifying2060ed1after the merge.2060ed1: 30/30 success. push:main on2060ed1: 15 of 16 success.go-ci / record reviewed vs landed commit (push)failed withcomment page 2 repeated the previous non-empty page. That is the recorder defect tracked in #1495: it is red on every commented landing since #1486, and it is not this change.claude/1491-foldback-refuse-dropwas deleted after the range-diff check.\rinrt prep's refusal (prep.UnreleasedDropError), measured on2060ed1.All four acceptance criteria are ticked above (DONE @ #1493). Closing by hand, because the PR used
Refs.