[BUG] Background sessions silently lose macOS folder/network access and the model is never told it is a background job

Status Open
Reported on v2.1.269
Maintainer reply None cached
Activity 0 comments · opened Sep 12, 2026

Summary

When a session has been sent to the background (/bg, agent view), it runs as a separate process under the supervisor and loses capabilities that a terminal-tied session has on macOS (per agent-view docs: no access to Desktop/Documents/Downloads until separately granted, no local-network access on macOS 15+, separate terminal host process). But the model is not told it is running as a background job. The only ways to discover it are the user running /status (Session kind row) or the model checking the CLAUDE_JOB_DIR env var, which it has no reason to do.

Result: a command that worked in a foreground session fails in the same conversation after backgrounding (Operation not permitted, no route to host, terminal control failures), and neither the model nor the user can see why. The user spent a long time debugging "it worked before, now it doesn't" until discovering by accident that the session had become a background job.

There is also no UI indicator when attached to a background session that distinguishes it from a normal one, and no way to convert a background session back to a terminal-tied one (only stop + claude --resume, which creates a new session).

Steps to reproduce

  1. Start claude in a terminal on macOS 15+. Run a command that reads ~/Downloads — works.
  2. Send the session to the background with /bg, then attach to it again from agent view.
  3. Ask for the same command. It fails with Operation not permitted.
  4. The model has no information in its context that the session kind changed. /status (user-run) is the only visible signal.

Expected

  • Inject a system-level note into the model context when a session becomes a background job (and on attach), listing the known restrictions, the way other environment changes are surfaced.
  • Show a persistent marker in the attached UI (header or status line) that the session is a background job.
  • Ideally: a way to promote a background session back to a terminal-tied session without forking.

Environment

  • Claude Code 2.1.269
  • macOS 26.6.2 (Darwin 25.6.0)

View original on GitHub ↗