Skip to content

[Night Shift] Fix subagent env var resolution and add background task docs#401

Open
Pgarciapg wants to merge 3 commits into
openai:mainfrom
Pgarciapg:exec-assistant/2026-06-25
Open

[Night Shift] Fix subagent env var resolution and add background task docs#401
Pgarciapg wants to merge 3 commits into
openai:mainfrom
Pgarciapg:exec-assistant/2026-06-25

Conversation

@Pgarciapg

Copy link
Copy Markdown

Summary

  • Fixed CLAUDE_PLUGIN_ROOT environment variable resolution in codex-rescue agent by adding script path resolution fallback instructions
  • Added background task collection instructions to codex-result-handling skill to prevent silent loss of backgrounded task results

Work Items Completed

fix: Subagent CLAUDE_PLUGIN_ROOT environment variable resolution

  • Added script path resolution section to codex-rescue.md agent
  • Added matching guidance to codex-cli-runtime skill
  • When CLAUDE_PLUGIN_ROOT is not available in the subagent environment, the agent now has instructions to locate the script by finding the codex plugin directory

docs: Background task collection instructions

  • Added new "Background Task Collection" section to codex-result-handling skill
  • Documents how to check status, wait for completion, and retrieve results
  • Warns about potential loss of results if not explicitly collected

Test Results

All 90 tests pass.

🤖 Generated with Claude Code

Pgarciapg and others added 3 commits June 24, 2026 00:06
…ell-safe prompts

The codex-companion.mjs already supports --prompt-file to read prompts
from a file, which avoids shell escaping issues with special characters
like $, backticks, quotes, and newlines. Updated the skill documentation
to recommend this approach as the primary method, keeping the positional
argument form as a legacy option for simple prompts.

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
When the codex-rescue subagent runs, the CLAUDE_PLUGIN_ROOT environment
variable may not be properly inherited. Add instructions for resolving
the absolute script path when the env var is unavailable.

Also update codex-cli-runtime skill with matching path resolution
guidance for consistency.

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
Add guidance to the codex-result-handling skill for collecting results
from backgrounded Codex tasks. Without explicit collection, background
task results can be silently lost.

The new section instructs users to:
- Use /codex:status <job-id> to check progress
- Use /codex:status <job-id> --wait to block until completion
- Use /codex:result <job-id> to retrieve final output

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
@Pgarciapg Pgarciapg requested a review from a team June 25, 2026 05:07
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