Skip to content

Fix pi-subagents result path env alias handling - #39

Merged
tasercake merged 1 commit into
mainfrom
worktree/fix-subagent-result-env-path
Jul 20, 2026
Merged

Fix pi-subagents result path env alias handling#39
tasercake merged 1 commit into
mainfrom
worktree/fix-subagent-result-env-path

Conversation

@tasercake

Copy link
Copy Markdown
Owner

Summary

  • fix the result-path guidance regression introduced by 3dbd5fa / PR docs(pi-subagents): clarify result file guidance #19 by telling child agents to pass the resolved absolute path to Pi file tools and reserve $PI_SUBAGENT_RESULT_PATH for shell commands
  • add a child-runtime compatibility guard that rewrites only the exact $PI_SUBAGENT_RESULT_PATH and ${PI_SUBAGENT_RESULT_PATH} path tokens for write, edit, and read
  • leave embedded variables, arbitrary env vars, unrelated paths, missing-env calls, and bash commands untouched
  • replace copied prompt-construction tests with tests of the registered production handlers and document the distinction

Validation

  • observed RED: focused regression test failed because no tool_call guard was registered
  • npm test in extensions/pi-subagents (35 passed, 1 opt-in real-model integration skipped)
  • npm pack --dry-run --json in extensions/pi-subagents
  • git diff --check

@tasercake
tasercake merged commit fdc82c4 into main Jul 20, 2026
1 check passed
@tasercake
tasercake deleted the worktree/fix-subagent-result-env-path branch July 20, 2026 10:52
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