Remote Control: OAuth access token revoked mid-session (401), hub loses all remote sessions — twice in two weeks

Status Open
Reported on v2.1.239
Maintainer reply None cached
Activity 0 comments · opened Aug 30, 2026

Summary

A long-running claude remote-control hub (launched via launchd, KeepAlive) repeatedly loses its connection because the CLI's OAuth access token is revoked server-side while logged in via a claude.ai Max subscription. Each occurrence orphans all remote sessions being served (they show "Can't reach your computer" and never auto-reconnect).

Environment

  • Claude Code 2.1.239 / 2.1.246, macOS 14.0 (23A344)
  • Login: claude.ai account, Max subscription (claude auth status shows loggedIn: true, firstParty)
  • Hub: claude remote-control --name Mac-hub run headless via a launchd user agent (KeepAlive), stdin kept open

Occurrences

  1. 2026-08-18: CLI spontaneously logged out ("Not logged in") while the desktop app stayed logged in; Remote Control down until manual re-login.
  2. 2026-08-30 07:10 CEST: while serving 3 sessions:
[07:10:53] Error: Failed to stop work cse_...: StopWork: Authentication failed (401): OAuth access token has been revoked.. Remote Control is only available with claude.ai subscriptions. Please use `/login` to sign in with your claude.ai account.
[07:10:55] Error: Failed to stop work cse_... after 3 attempts: Remote Control is only available with claude.ai subscriptions. ...
[07:10:55] Environment preserved. Restart `claude remote-control` to reconnect existing sessions.

Hub reconnected ~08:08 after token refresh, without manual re-login this time.

Context that may matter

Multiple Claude Code processes run concurrently on this machine under the same account (desktop app local sessions, scheduled tasks, the remote-control hub). If concurrent token refreshes can trigger refresh-token-reuse detection, that could explain the revocations.

Impact

  • Remote Control goes down until the token refreshes (up to ~1h) or the user logs in again.
  • Worse: every hub process exit orphans the remote sessions it served. They show "Can't reach your computer" on claude.ai/mobile and never reattach to the new hub instance automatically; recovery requires claude remote-control --session-id <id> per session within ~4h.

Expected

  1. Access-token revocation with a valid refresh token should not take Remote Control down for an extended period.
  2. After a hub restart in the same environment, existing remote sessions should reattach automatically (or claude.ai should offer a reconnect that targets the new server instance).

View original on GitHub ↗