Skip to content

[codex] Improve error for refs outside workspace#13223

Draft
Byron wants to merge 3 commits intogitbutlerapp:masterfrom
Byron:better-create-reference-error
Draft

[codex] Improve error for refs outside workspace#13223
Byron wants to merge 3 commits intogitbutlerapp:masterfrom
Byron:better-create-reference-error

Conversation

@Byron
Copy link
Copy Markdown
Collaborator

@Byron Byron commented Apr 8, 2026

Summary

  • improve create_reference so an existing ref outside the workspace fails with an explicit error instead of the generic segment-creation error
  • add a regression test covering that exact case

Why

The reported failure mode in issue #13104 surfaced a cryptic error when the branch already existed in Git but was outside the GitButler workspace.

Validation

  • cargo test -p but-workspace create_reference -- --nocapture
  • cargo fmt --check --all

Notes

  • This draft PR was created by Codex.
  • Byron still needs to review this change before it is ready to merge.

@vercel
Copy link
Copy Markdown

vercel bot commented Apr 8, 2026

@Byron is attempting to deploy a commit to the GitButler Team on Vercel.

A member of the Team first needs to authorize it.

@Byron Byron linked an issue Apr 8, 2026 that may be closed by this pull request
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

git butler gives me an error whenever I try to create a 'main' branch

1 participant