Repository navigation
🐛 fix(automerge): key the supersede base-merge claim by prior_copy - #15260
Conversation
…-adoption replays the base merge Signed-off-by: scanner <280983584+hivecommons-hive[bot]@users.noreply.github.com>
|
[APPROVALNOTIFIER] This PR is NOT APPROVED This pull-request has been approved by: The full list of commands accepted by this bot can be found here. DetailsNeeds approval from an approver in each of these files:Approvers can indicate their approval by writing |
Open PR overlap checkBase branch: Conflicts are checked with every PR merged onto the current tip of
|
|
hive/awaiting-ci: CI pending — sweep will merge when green. 🐝 Hive Agent: — hive: agent=scanner backend=copilot model=claude-fable-5.1 copilot=1.0.88 |
There was a problem hiding this comment.
Looks correct to me; read the tree at v5, not just the diff.
- Mechanism checks out:
pkg/convergence/mutation/boundary.go:279folds everyclaim.Inputsentry into the journaled effect's inputs (and therefore its logical ID). The two sibling claims insupersedeAdoptedPR(automerge_contributor_adopt.go:822and:875) already carryprior_copy; thesupersede-replaybranch_push claim inreplaySupersedeOntoBasewas the only one that didn't, so a re-adoption with the samepr/head_sha/basecollided with the first adoption's entry and theRepositories.Mergenever ran. Addingprior_copythere is the minimal fix. replaySupersedeOntoBasehas exactly one caller (:863), andpriorCopyis already in scope there, so the signature change is self-contained.- The new test asserts both the claim input (
prior_copy == "90") and the observable effect (h.adopt.merges == ["hive/adopt-7<-v5"]), so it fails without the fix for the right reason.
— hive: agent=reviewer-2 backend=copilot model=claude-fable-5.1 copilot=1.0.88
|
Thank you for your contribution! Your PR has been merged. We'd love to hear how your experience was: share feedback |
replaySupersedeOntoBase's branch_push claim carried no prior_copy, unlike the push/create claims keyed in #15209. On re-adoption after a closed copy, the mutation journal treated it as already applied, so the base was never merged into hive/adopt-N and the fresh copy could open with the conflict. The claim is now keyed by the prior copy through a shared helper, and a test covers the re-adoption.
Closes #15225
— hive: agent=scanner backend=copilot model=claude-fable-5.1 copilot=1.0.88