Preflight Checklist
What's Wrong?
In a new Claude Code session using a worktree branched off local master, the diff button shows changes from origin/master...HEAD rather than master...HEAD. This causes the diff view to include commits that exist on local master but have not yet been pushed to the remote — changes completely unrelated to the current session.
What Should Happen?
The diff button should show changes introduced in the current worktree branch relative to the local branch it was created from (master...HEAD), returning no changes if Claude has not yet modified anything.
Actual Behavior
The diff button shows changes from origin/master...HEAD, which includes unpushed commits from local master that are unrelated to the current session.
Verification
git diff master...HEAD returns nothing (correct — no session changes)
git diff origin/master...HEAD matches what the diff button displays
Environment
- Claude Code: latest
- Session type: new worktree session branched from local
master
Error Messages/Logs
Steps to Reproduce
- Have a local
master branch that is ahead of origin/master (i.e. unpushed commits exist)
- Start a new Claude Code session using a worktree branched off local
master
- Without Claude making any changes, click the Diff button
Claude Model
Sonnet (default)
Is this a regression?
I don't know
Last Working Version
No response
Claude Code Version
1.1062.0 (b81bcd) Claude for Windows
Platform
Anthropic API
Operating System
Windows
Terminal/Shell
Other
Additional Information
No response
Preflight Checklist
What's Wrong?
In a new Claude Code session using a worktree branched off local
master, the diff button shows changes fromorigin/master...HEADrather thanmaster...HEAD. This causes the diff view to include commits that exist on localmasterbut have not yet been pushed to the remote — changes completely unrelated to the current session.What Should Happen?
The diff button should show changes introduced in the current worktree branch relative to the local branch it was created from (
master...HEAD), returning no changes if Claude has not yet modified anything.Actual Behavior
The diff button shows changes from
origin/master...HEAD, which includes unpushed commits from localmasterthat are unrelated to the current session.Verification
git diff master...HEADreturns nothing (correct — no session changes)git diff origin/master...HEADmatches what the diff button displaysEnvironment
masterError Messages/Logs
Steps to Reproduce
masterbranch that is ahead oforigin/master(i.e. unpushed commits exist)masterClaude Model
Sonnet (default)
Is this a regression?
I don't know
Last Working Version
No response
Claude Code Version
1.1062.0 (b81bcd) Claude for Windows
Platform
Anthropic API
Operating System
Windows
Terminal/Shell
Other
Additional Information
No response