docs(althing): retract the "bare shell" claim — it was never verified
I wrote that Claude Code runs the status line in a bare shell. What I actually measured was that a HAND-RUN from an interactive session inherits that session's exported ALTHING_HANDLE; Claude Code's own invocation is a different execution and was not observed. forseti caught it before the sentence had been read by anyone else. The evidence points the other way: this box's Claude Code process carries ALTHING_HANDLE and ALTHING_POST_OFFICE in its own environ, inherited from the dev-launch shell, and a spawned child would normally inherit both — observed independently on two seats. Whether Claude Code scrubs before spawning was not observed either. Nothing depends on the answer, which is why the page now says "do not depend on the environment being present" instead of asserting its absence, and records it as an open question with both sides. The smoke test still strips the variables, because that is the harder case and the one whose false pass caught two agents inside an hour.
This commit is contained in:
@@ -318,9 +318,24 @@ edited directly and was *ahead* of the tracked copy; a reflexive `cp` from the
|
||||
repo would have destroyed the better version. The tracked copy is intent, the
|
||||
live path is reality, and reality is sometimes right.
|
||||
|
||||
Smoke test — Claude Code runs it in a **bare shell**, so unset the althing
|
||||
env vars or you will test your own session's identity instead of the resolution
|
||||
logic:
|
||||
Smoke test — **strip the althing env vars, or you will test your own session's
|
||||
identity instead of the resolution logic.** A hand-run inherits the exported
|
||||
`ALTHING_HANDLE` from the session you run it in, so the seat's own directory and
|
||||
a directory with no althing identity render identically and both look right.
|
||||
That false pass caught two agents within one hour on 2026-09-02.
|
||||
|
||||
⚠ **Open question — whether Claude Code's own invocation inherits the
|
||||
environment is NOT established, and nothing here depends on it.** An earlier
|
||||
version of this page asserted a "bare shell"; that claim was never verified and
|
||||
the evidence points the other way. Measured 2026-09-02: this box's Claude Code
|
||||
process carries `ALTHING_HANDLE` and `ALTHING_POST_OFFICE` in its own `environ`
|
||||
(inherited from the `dev-launch` shell), and a spawned child would normally
|
||||
inherit both — observed independently on two seats. Whether Claude Code scrubs
|
||||
the environment before spawning the status-line command was not observed either
|
||||
way. **Write code that does not depend on the environment being present**, which
|
||||
`althing-statusline` already does: environment first, launch history second, and
|
||||
a seat started outside `dev-launch` has no handle in either place. Test with the
|
||||
variables stripped regardless, because that is the harder case:
|
||||
|
||||
printf '{"workspace":{"current_dir":"/tmp"}}' \
|
||||
| env -u ALTHING_HANDLE -u ALTHING_POST_OFFICE bash scripts/claude-statusline-command.sh
|
||||
|
||||
Reference in New Issue
Block a user