[BUG] Cloud agent silently loses all work when git push hangs (~50% reproduction rate)

Resolved 💬 1 comment Opened Apr 21, 2026 by jeramiahgcoffey Closed May 28, 2026

Preflight Checklist

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

What's Wrong?

Summary

Claude Code cloud agents (claude.com/code web) hang on git push to the
origin remote approximately 50% of the time. When the hang occurs:

  • The session becomes unresponsive.
  • The sandbox is recycled.
  • All work produced in the session is lost (including committed but

unpushed commits).

  • No error is shown in the UI.
  • No logs are available to the user for diagnosis.

This is silent, unrecoverable work loss. It makes the cloud agent product
unusable for any non-trivial task.

## Environment

  • Product: Claude Code Web (claude.com/code)
  • Plan: Max
  • Browser: Chrome 147 MacOS
  • First observed: Over 6 months ago
  • Frequency: ~50% of sessions that end in a push

## Related issues

  • #23707 — Background Task agents fail on Claude Code Web, sandbox recycled

between turns (closed "not planned")

  • #20278 — Sessions hang in "Architecting" state after git operations
  • #22357 — Infinite queue loop when user sends message during tool execution
  • #36759 — Sandbox TMPDIR points to non-existent directory, child processes

hang silently

The changelog through v2.1.116 does not appear to address the push-specific
failure mode.

## Ask

  1. Acknowledge whether this is a known issue and whether a fix is planned.
  2. Publish a recommended workaround (push cadence, session structure, etc.)

until a fix ships.

  1. Surface sandbox-recycle events to the user so work loss is not silent.
  2. Expose cloud agent logs so users can self-diagnose hangs.

## Impact

This is a production reliability issue. The current behavior prevents me
from using cloud agents for any task larger than a single small commit,
because half of all sessions discard work with no recovery path.

What Should Happen?

Expected behavior

  • Push either succeeds or fails with a surfaced error.
  • If the sandbox is recycled mid-operation, the user is notified.
  • Committed work is preserved across sandbox recycles (it is stored in the

git-tracked working directory).

Error Messages/Logs

Steps to Reproduce

Reproduction

  1. Open a cloud agent session on a feature branch.
  2. Have the agent make code changes across several files.
  3. Ask the agent to commit and push to the remote.
  4. Observe: roughly half the time, the push operation hangs with no

progress indicator and no error. The session cannot be recovered.
I do not have a minimal public repro — the issue appears related to session
duration and sandbox state, not repo contents. I can supply session IDs
and timestamps privately if useful.

Claude Model

Opus

Is this a regression?

Yes, this worked in a previous version

Last Working Version

_No response_

Claude Code Version

2.1.116

Platform

Anthropic API

Operating System

macOS

Terminal/Shell

Terminal.app (macOS)

Additional Information

<img width="1184" height="678" alt="Image" src="https://github.com/user-attachments/assets/d200c94c-89a6-4321-915f-8e366a103dfc" />

View original on GitHub ↗

This issue has 1 comment on GitHub. Read the full discussion on GitHub ↗