Repository navigation
fix(context-cli): keep later production stages and cancel partial revision delivery on rollback - #108
Merged
Merged
Conversation
…ision delivery on rollback A rollback now always records the production stage it found (null when none), so finishing it never discards a stage prepared afterwards. Rolling back also deletes the partial revision delivery selection of the replaced revision, which otherwise stopped close. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This was referenced Nov 13, 2026
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.
Summary
Follow-up to #107 with two rollback fixes found in review.
A production stage prepared after a rollback could be deleted
A rollback recorded
productiononly when a stage existed, and cleanup treated a missing record as an older state that discards whatever stage it finds. A stage prepared after the rollback was applied (for example with aprepare-currentcommand obtained earlier) was therefore deleted when the rollback finished.production: the stage and whether it is discarded, ornullwhen no stage existed. A missing field still means an older state.discard: true. A stage it did not record (null, or a different stage id) is kept; only the rollback record is removed and the result reportsproduction: "kept". Previously a changed stage id threw an error that could not be resolved while the rollback stayed active.Partial delivery of a page revision stopped close after a rollback
Rolling back replaced the revision pointer but left
revision-delivery.json, socontext closevalidated the old selection and failed with "Partial revision delivery is no longer active".discarded_revision_delivery.Guides (3 copies) and the CHANGELOG
Unreleasedsection are updated.Tests
mainand pass with this change.🤖 Generated with Claude Code