Repository navigation
Conversation
Exporting conflicts should not require opting into the server's resolver. Return the existing conflict package for ordinary failed lands and allow --conflicts-dir without --resolve, so callers can edit and re-land it. Build the package outside the lane from the failed attempt's exact tip and commit, in a disposable quarantine, after checking agent policy. Keep the original error when an intermediate rebase conflict has a clean endpoint merge. Cover CLI and SDK flows and update the protocol comments. Changelog: added
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.
graft land --conflicts-dir DIRcurrently requires--resolve, which also opts into the server's configured resolver. Allow callers to export unresolved conflicts for manual editing without requesting automatic resolution, then land their edits withgraft land --resolved DIR.Ordinary
UserLandmerge conflicts now include the existingLandConflicterror detail. The server builds it outside the landing lane, in a disposable quarantine, using the exact tip and commit reported by the failed attempt. It checks agent policy before building the package and calls no resolver. Existing error codes andUserLandErrordetails remain available to older clients. CLI help, SDK documentation, protocol comments and the roadmap describe the new behavior.Regression coverage exercises rebase and merge with and without automatic resolution, reading the three sides through the SDK, manual re-land, preserving edits on repeated export, a branch that has moved, and denied agents. A conflict in an intermediate rebase commit whose endpoint merge is clean still returns the original error without a package; an older server still needs
--resolveto return one.Validation with Go 1.26.0 and Git built from the repository's pinned
GIT_VERSION_PREVrevision:cmd/graft,sdk,internal/graft/workspaceanddoc/grafttest packages.TestUserLand*andTestLandConflictWithoutResolution*in the operations package; the three connectivity checks that needed a complete Git installation passed on rerun with that installation.TestLandConflictWithoutResolutionandTestUserLand_conflictPackage.go vetfor the CLI, SDK, workspace and operations packages, the Windows CLI build, andgit diff --check.The full repository suite and bundled MVCC Git variant were not run.