When you start a cloud session with claude --cloud, Claude Code packs up your repository and uploads it. A new branch with no commits yet may still have staged files. Staged files are changes you have marked with git add for the next commit.
In that case, when the upload covers more than just the current branch, Claude Code now compares your staged files against an empty project and against the latest commits of recent branches and tags. What happens next:
- Nothing is staged, or the staged files match an existing branch or tag: the upload goes ahead.
- The staged files match nothing: the upload stops with "The current branch has no commits yet".
- There are too many branches to check, or the comparison cannot be read: the upload stops with the same error.
Before this change, a branch with no commits but with staged files went ahead and its work in progress was set aside for the upload.
A new branch holding only staged files could produce a misleading upload. Now the problem shows up before the cloud session starts.
It is not clear whether an upload that goes ahead because the staged files match a branch starts the cloud session from the right point.