diff --git a/docs/OPENCLAW.md b/docs/OPENCLAW.md index e0bb60ad7..2f1b162bb 100644 --- a/docs/OPENCLAW.md +++ b/docs/OPENCLAW.md @@ -127,7 +127,13 @@ environment variable should be set. gstack detects this and adjusts: rendering prose to nobody - Focuses on task completion and prose reporting -Set the env var in sessions_spawn: `env: { OPENCLAW_SESSION: "1" }` +`sessions_spawn` has no per-spawn environment argument +([openclaw/openclaw#51654](https://github.com/openclaw/openclaw/issues/51654) +was closed without adding one), so an `env` field in the tool call is ignored. +Set `OPENCLAW_SESSION=1` in the environment of the Claude ACP harness or the +Gateway service instead, keep credentials out of that wrapper, and confirm the +variable from inside the spawned process (for example `echo $OPENCLAW_SESSION`) +rather than trusting the session's final message. ### Explicit override: GSTACK_SESSION_KIND diff --git a/test/openclaw-native-skills.test.ts b/test/openclaw-native-skills.test.ts index 009b5e22c..994b9038a 100644 --- a/test/openclaw-native-skills.test.ts +++ b/test/openclaw-native-skills.test.ts @@ -32,4 +32,9 @@ describe('OpenClaw native skills', () => { expect((parsed.description as string).length).toBeGreaterThan(0); } }); + + test('integration docs do not advertise an unsupported per-spawn env', () => { + const content = fs.readFileSync(path.join(ROOT, 'docs/OPENCLAW.md'), 'utf-8'); + expect(content).not.toContain('env: { OPENCLAW_SESSION'); + }); });