You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
create_branch branch tool fails with generic message when rule is violated oppose to the Github UI #3080
try to create an invalid branch name from the UI -> see detailed error about the rules violation
try to create the same branch name from mcp -> see generic 422 error
Expected vs actual behavior
expecting to see the same errors like we see in the website, and in general more descriptive errors
detailed errors helps the LLM to recover from failed tool calls
Thanks for the report. Would maintainers accept a small PR that preserves GitHub's structured validation message (subject to existing redaction conventions) instead of returning a generic 422, with a regression test for a branch-naming rule violation? I would keep the scope limited to create_branch and leave successful behavior unchanged. Is there a preferred error format or existing abstraction to use?
Activity
quseijuro-design commentedon Aug 16, 2026
Thanks for the report. Would maintainers accept a small PR that preserves GitHub's structured validation message (subject to existing redaction conventions) instead of returning a generic 422, with a regression test for a branch-naming rule violation? I would keep the scope limited to
create_branchand leave successful behavior unchanged. Is there a preferred error format or existing abstraction to use?fix(errors): safely format GitHub validation failures
fix(errors): safely format GitHub validation failures
fix(errors): safely format GitHub validation failures