Skip to content

fix(claude-code): the pin follows Task's dotenv order; interactive sessions get the right advice (claude-code 1.6.1) - #79

Merged
nabil-becker merged 2 commits into
mainfrom
fix/claude-host-attach-kind/1
Oct 24, 2026
Merged

nabil-becker merged 2 commits into
mainfrom
fix/claude-host-attach-kind/1

Conversation

@nabil-becker

Copy link
Copy Markdown
Owner

What

  • Pin lookup (pin-hook-env-visibility): claude-host-pin (hook and --replace), claude-fleet and claude-host now read the root .env, then .devcontainer/.env, in the same order as the Taskfile's dotenv, where the first file that defines a variable wins. Before this, the hook looked only in .devcontainer/.env. This repo keeps HOST_SESSION in the root .env, so the pin went stale after /clear.
  • Attach advice (claude-host-attach-kind): claude-host reads each live session's kind from claude agents --json. For an interactive session it names the pid and tty and says to switch to that terminal or use Remote Control. It prints claude attach <id> only for a background session, because attach fails with "No job matching" on an interactive one.
  • claude-code 1.6.0 → 1.6.1. NOTES and the README are regenerated.
  • The backs' records since Records since #75: ADRs 0029–0030 #78, and a backlog tidy (items ticked, duplicates merged).

Checked

  • task lint passes. test/claude-code/unit/live_session_test.sh has 44 new checks.
  • Live in the devhost: the fixed claude-host named the running interactive session with its pid and tty (pts/0) and gave no claude attach. The fixed hook wrote the new id into the root .env on a /clear input.

After merge

Release claude-code 1.6.1 (the Operator).

🤖 Generated with Claude Code

https://claude.ai/code/session_018RdTPBTYGqBZzNWf3yzR8y

devhost agent and others added 2 commits October 24, 2026 13:53
…ssions get the right advice (claude-code 1.6.1)

claude-host-pin (hook and --replace), claude-fleet and claude-host now read
the root .env, then .devcontainer/.env, as the Taskfile's dotenv does (the
first file that defines a variable wins); the hook looked only in
.devcontainer/.env, so a pin kept in the root .env went stale after /clear.

claude-host reads each live session's kind from `claude agents --json`: an
interactive session is named with its pid and tty (switch to that terminal or
Remote Control); `claude attach <id>` is printed only for a background one.

Backlog: pin-hook-env-visibility, claude-host-attach-kind.

Co-Authored-By: Claude Sonnet 5.5 <claude-sonnet-5-5@noreply.invalid>
Co-Authored-By: Claude Opus 5.5 <claude-opus-5-5@noreply.invalid>
Signed-off-by: devhost agent <devhost-agent@noreply.invalid>
The backs' ledger, cost report and backlog changes since #78. Ticked:
release-fleet-lessons, merge-repair-and-records-prs, windows-repair-cleanup,
claude-host-attach-kind, pin-hook-env-visibility. Merged the duplicate
pin-hook-first-clear items (with the first run's failure noted) and removed
the open fleet-reconcile-live-sessions duplicate and amend-pin-hook-first-clear.

Co-Authored-By: Claude Opus 5.5 <claude-opus-5-5@noreply.invalid>
Signed-off-by: devhost agent <devhost-agent@noreply.invalid>
@nabil-becker
nabil-becker merged commit 904fdd8 into main Oct 24, 2026
69 checks passed
@nabil-becker
nabil-becker deleted the fix/claude-host-attach-kind/1 branch October 24, 2026 13:58
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