/ultrareview cloud session fails with `CLAUDE_CODE_OAUTH_TOKEN not set`, then silently times out at 30 min — consumes free runs

Resolved 💬 4 comments Opened Apr 28, 2026 by planfit-river Closed May 31, 2026

Description:
/ultrareview <PR#> consistently fails before any review work can begin. Two
distinct problems compound here:

  1. Root cause (server-side env): The cloud session's SessionStart:startup

hook (run_hunt.sh) exits with code 1 immediately because
CLAUDE_CODE_OAUTH_TOKEN is not set in the cloud environment. Nothing in my
local environment can influence this.

  1. Failure-surfacing bug: The hook fails within seconds, but the cloud

session does not surface the failure. The web UI stays empty and the task
keeps the free-run slot reserved until a 30-minute timeout. The eventual
notification reads Remote review failed: remote session exceeded 30 minutes,
which masks the real cause and makes it look like a long-running review
timed out.

Reproduction:

  1. Run /ultrareview 9279 in repo planfit/planfit-client-rn
  2. Cloud session starts; web UI shows no progress for ~30 min
  3. System reports "remote session exceeded 30 minutes"
  4. Inspecting the local task output file reveals the hook actually died

immediately with the OAuth error

Hook output (identical across both attempts, captured locally):

=== run_hunt.sh: Starting ===
=== Bug Hunter: Starting Review ===
Timestamp: 2026-04-28T02:58:34Z
PR: 9279
Repo: planfit/planfit-client-rn
=== run_hunt.sh: OAuth token check ===
ERROR: CLAUDE_CODE_OAUTH_TOKEN not set

Affected sessions:

  • session_015pncy6hnrqT5maaZjhQ1RJ — started 2026-04-28 02:58 UTC, hook failed

in seconds, marked failed only after 30 min

  • session_017RbBTu7Pguyyhha7oR2V6o — started 2026-04-28 03:23 UTC, identical

pattern

Impact:

  • 2 of 3 free runs consumed without producing any review
  • Each failure wastes 30 min of wall time before the user gets any signal
  • Misleading timeout message hides the actual root cause

Requests:

  1. Fix the server-side env so CLAUDE_CODE_OAUTH_TOKEN is set in ultrareview

cloud sessions

  1. Surface SessionStart hook failures immediately instead of waiting for the

30-min timeout, and don't consume free-run quota for sessions that fail
before any review work

  1. Credit the 2 failed runs back to my account — both failed at startup due to

the server-side env issue

View original on GitHub ↗

This issue has 4 comments on GitHub. Read the full discussion on GitHub ↗