claude-code - 💡(How to fix) Fix [BUG] agent stuck: git-rebase preference + auto-mode -> blocked force pushes -> requires human intervention

Official PRs (…)
ON THIS PAGE

Recommended Tools

×6

Utilities matched from this issue’s tags and category — try them while you read without losing context.

GitHub issue graph ai analysis

Paste a GitHub issue URL. We fetch that issue, discover linked issues from bodies/comments/timeline, collect linked pull requests, and produce a structured English report.

The report is written in English Markdown for sharing and archival.

Helpful · Quick feedback

Loading…

Error Message

Error Messages/Logs

⏺ The classifier is blocking me even with your explicit instruction. The error says "retrying often succeeds" — let me try once more: Latest blocked action: Stage 2 classifier error - blocking based on stage 1 assessment (usually transient — retrying often succeeds)

Code Example

try again doing it yourself

Bash(git -C /Users/**/biome-poc push --force-with-lease origin biome-poc 2>&1)
  ⎿  Denied by auto mode classifier ∙ see https://code.claude.com/docs/s/claude-code-auto-mode

The classifier is blocking me even with your explicit instruction. The error says "retrying often succeeds"let me try once more:

Bash(git -C /Users/**/biome-poc push --force-with-lease origin biome-poc 2>&1)
  ⎿  Waiting…

───────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────
 Bash command

   git -C /Users/**/biome-poc push --force-with-lease origin biome-poc 2>&1
   Force push rebased biome-poc branch

 Auto mode classifier requires confirmation for this command.
 3 consecutive actions were blocked. Please review the transcript before continuing.

 Latest blocked action: Stage 2 classifier error - blocking based on stage 1 assessment (usually transient — retrying often succeeds)

 Do you want to proceed?
1. Yes
   2. Yes, and don’t ask again for: git *
   3. No
RAW_BUFFERClick to expand / collapse

Preflight Checklist

  • I have searched existing issues and this hasn't been reported yet
  • This is a single bug report (please file separate reports for different bugs)
  • I am using the latest version of Claude Code

What's Wrong?

Claude code gets trapped from making forward progress when auto-mode is enabled and it decides to use a rebase rather than a merge to resolve merge conflicts on a PR.

  • merge conflicts -> agent needs to choose resolution strategy (merge or rebase)
  • agent chooses rebase -> requires a force push to update the remote
  • auto-mode -> blocks force push on all branches

What Should Happen?

Claude should default to workflows that allow it to autonomously finish code changes. (which needs to include getting CI builds passing via git-push)

Either:

  • auto-mode needs to allow force push when this is a feature branch created in the same context
  • claude system prompts need to prefer merge over rebase to get the latest changes (Does claude need to be auto-mode aware?) - so that this does not block progress

Error Messages/Logs

❯ try again doing it yourself

⏺ Bash(git -C /Users/**/biome-poc push --force-with-lease origin biome-poc 2>&1)
  ⎿  Denied by auto mode classifier ∙ see https://code.claude.com/docs/s/claude-code-auto-mode

⏺ The classifier is blocking me even with your explicit instruction. The error says "retrying often succeeds"let me try once more:

⏺ Bash(git -C /Users/**/biome-poc push --force-with-lease origin biome-poc 2>&1)
  ⎿  Waiting…

───────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────
 Bash command

   git -C /Users/**/biome-poc push --force-with-lease origin biome-poc 2>&1
   Force push rebased biome-poc branch

 Auto mode classifier requires confirmation for this command.
 3 consecutive actions were blocked. Please review the transcript before continuing.

 Latest blocked action: Stage 2 classifier error - blocking based on stage 1 assessment (usually transient — retrying often succeeds)

 Do you want to proceed?
1. Yes
   2. Yes, and don’t ask again for: git *
   3. No

Steps to Reproduce

  1. enable auto-mode
  2. Start work on a local branch that has merge conflicts with a remote branch.
  3. Prompt agent with something like: "{{do the feature work}}. get the build passing locally and then prepare the brach for a code review in a PR"
  4. Agent finishes the local changes and gets local builds passing. Pushes feature branch.
  5. Agent checks on PR/CI status and sees merge conflict.
  6. Agent uses rebase to resolve conflicts with remote (the agent is now trapped)
  7. Agent tries to --force push the updated feature branch
  8. Agent blocked from force push of feature branch by auto-mode
  9. human gives explicit instructions "this is a feature branch force push it"
  10. auto-mode - Blocks attempts to force push
  11. human approval required to proceed

Claude Model

Opus

Is this a regression?

I don't know

Last Working Version

No response

Claude Code Version

2.1.157

Platform

Anthropic API

Operating System

macOS

Terminal/Shell

iTerm2

Additional Information

No response

Vote matrix · Quick signals

Works
Did the solution work? Tap to confirm.
Easy Fix
Was it a quick fix?
Time Saver
Did it save you time?
Blocking
Was it severely blocking?
Common Issue
Are others likely hitting this too?
Flaky / Intermittent
Is it intermittent?
Verified / Reproducible
Can you reproduce it reliably?
Loading…

Still need to ship something?

×6

Another batch ranked right after the header list — different links, same matching logic.

Back to top recommendations

TRENDING

claude-code - 💡(How to fix) Fix [BUG] agent stuck: git-rebase preference + auto-mode -> blocked force pushes -> requires human intervention