Skip to content

Claude runs no longer join the Claude Code session that launched Godspeed - #87

Open
ShriD5 wants to merge 2 commits into
mainfrom
t3-watch/2026-11-02-claude-host-session-env
Open

ShriD5 wants to merge 2 commits into
mainfrom
t3-watch/2026-11-02-claude-host-session-env

Conversation

@ShriD5

@ShriD5 ShriD5 commented Nov 2, 2026

Copy link
Copy Markdown
Owner

What T3 added

pingdotgg/t3code@47f2c8d29e: a Claude Code session exports markers to its children (CLAUDECODE, CLAUDE_CODE_SESSION_ID, CLAUDE_CODE_MESSAGING_SOCKET/_TOKEN, CLAUDE_EFFORT, CLAUDE_PID, …). A claude spawned with them acts as part of that session. T3 now strips them before starting Claude.

How Godspeed does it

If the engine is started from inside Claude Code (a terminal in Claude Code, or an agent running the godspeed CLI), every Claude chat inherited those markers. CLAUDE_EFFORT also overrode the chat's chosen effort. The direct Claude CLI harness passed all of them on. The ACP, Pi and OpenCode adapters (process::owned::configure) dropped only three.

  • crates/harness/src/process/owned.rs: the full 13-variable list plus remove_claude_session_markers. configure uses it.
  • crates/harness/src/claude/mod.rs: the run command, the initialize probe and the --thinking-display probe all call it. The CLI's entrypoint is left alone.
  • Docs: ledger rows for T3 through 47f2c8d29e, plus new T3-GAPS rows (model/effort switch divider, withdrawn Claude approvals, managed policy).

Screenshots: not available (no UI change).

Tests

  • cargo test -p zeron-harness --no-fail-fast: all pass (lib 435). The two env tests now assert that the session markers are removed.
  • cargo build -p godspeed: ok
  • cargo check --workspace --tests: ok

Check by eye

Start the engine from a Claude Code terminal, then open a Claude chat with effort set to low. The run should start as a new session, and its effort should not follow the launching session's CLAUDE_EFFORT.

🤖 Generated with Claude Code

… launched Godspeed

A Claude Code session exports its session id, messaging socket and token,
effort and IDE port to its children. When Godspeed's engine was started
from one (a terminal inside Claude Code, or an agent running the CLI),
every claude it spawned inherited them and acted as part of that session,
with its effort overriding the chat's. The Claude CLI harness passed all of
them on; the ACP, Pi and OpenCode adapters dropped only three.

Both paths now drop the full marker list.

Inspired by: pingdotgg/t3code@47f2c8d29e
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant