Repository navigation
Preview snapshot edits and bind application to the reviewed result - #54
Merged
Merged
Conversation
|
Caution Review failedThe pull request is closed.
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. |
…paction pinning - Stage snapshot replacements with the target's Unix mode before writing content, and report a target deleted mid-staging as stale. - Document that snapshot publication does not keep owner/ACLs/xattrs. - write_file and edit_file take the shared semantic-write lock. - REPL: keep the session open on non-provider prompt failures; return nonzero for unknown slash commands and failed custom commands; keep the last exit code on idle Ctrl+C. - Compaction: check the summary budget only once compaction is needed, and pin the turn's original request as well as the latest correction. - Keep provider-reported usage when the response text is empty. - Add coverage for staging recheck, precheck cancellation, snapshot symlink escape, unfinished primary compaction, and cancel isolation. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
…ontrol' into codex/runtime-resilience # Conflicts: # src/SharpClaw.Code.Runtime/Context/AutomaticContextManager.cs
…reviews # Conflicts: # docs/interactive-runtime.md # docs/tools.md # src/SharpClaw.Code.Permissions/Rules/WorkspaceBoundaryRule.cs # src/SharpClaw.Code.Tools/BuiltIn/EditFileSnapshotTool.cs # src/SharpClaw.Code.Tools/Models/SnapshotEditModels.cs # src/SharpClaw.Code.Tools/ToolsServiceCollectionExtensions.cs # src/SharpClaw.Code.Tools/Utilities/FileTextSnapshot.cs # tests/SharpClaw.Code.IntegrationTests/Runtime/InteractiveMilestoneTests.cs # tests/SharpClaw.Code.UnitTests/Tools/SnapshotEditingTests.cs
There was a problem hiding this comment.
Copilot was unable to review this pull request because the user who requested the review has insufficient remaining quota. Try requesting a review at a lower effort level.
An organization owner can choose the repository organization as the billing source for reviews requested by members with a paid Copilot license. Learn about Copilot code review billing.
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
Agents in read-only and plan modes can use
preview_file_snapshotto inspect the exact text removed and inserted by a proposed batch. The preview reports original line coordinates, the resulting content hash, and a deterministic preview ID.Callers can pass that ID to
edit_file_snapshotto require the reviewed target and result. A changed source returnsstaleSnapshot. A changed target or proposed result returnspreviewMismatch. Preview and apply share the same batch validation and text construction.Validation
Compatibility
The original apply arguments and result format remain supported. The preview ID checks consistency. Write permissions and the mutation journal still govern publication. The existing filesystem concurrency limits are documented in
docs/interactive-runtime.md.Stacked on PR #53. Local validation ran on macOS.