[BUG] /ultrareview fails "Could not find merge-base with main" despite local main branch existing with valid merge-base
Resolved 💬 3 comments Opened Apr 16, 2026 by apolo-81 Closed May 27, 2026
Preflight Checklist
- [x] I have searched existing issues and this hasn't been reported yet
- [x] This is a single bug report
- [x] I am using the latest version of Claude Code (2.1.111)
What's Wrong?
/ultrareview (no args) fails with:
Could not find merge-base with main. Make sure you're in a git repo with a main branch.
despite:
- Being in a valid git repo
- Local
mainbranch existing git merge-base master mainresolving successfully to a valid commit SHA
The repo has no remote configured. I suspect /ultrareview is looking for origin/main (remote tracking) instead of local main, but the error message says "main" which is misleading.
What Should Happen?
Either:
/ultrareviewshould work with localmainbranch when no remote is configured, OR- The error message should clarify "Could not find
origin/main— a GitHub remote is required"
Steps to Reproduce
mkdir /tmp/repro && cd /tmp/repro
git init
echo "a" > file.txt && git add . && git commit -m "init"
git branch main
echo "b" > file.txt && git commit -am "change"
# Now on master (default), main exists, merge-base resolves
git merge-base master main # works, returns init commit SHA
/ultrareview # fails with "Could not find merge-base with main"
Claude Model
Opus 4.7
Claude Code Version
2.1.111
Platform
Anthropic API
Operating System
Linux (Debian 14)
Terminal/Shell
bash
This issue has 3 comments on GitHub. Read the full discussion on GitHub ↗