Skip to content

docs(sandbox): clarify task process cleanup timing - #4604

Closed
yaoyu-33 wants to merge 1 commit into
NVIDIA-NeMo:pull-request/3902from
yaoyu-33:codex/pr3902-nonblocking-docs
Closed

yaoyu-33 wants to merge 1 commit into
NVIDIA-NeMo:pull-request/3902from
yaoyu-33:codex/pr3902-nonblocking-docs

Conversation

@yaoyu-33

Copy link
Copy Markdown
Contributor

Clarify the cleanup contract for task recipes and shared sandbox sessions, following the non-blocking approval notes on #3902 and the service-timing comment.

  • Explain that previously adopted children outside the harness group include unfinished background jobs such as make &, which can keep writing during verification. Describe the service-launch timing needed before a forced stop and the cleanup of newly orphaned children.
  • Correct sandboxed Hermes guidance: this caller supplies no stop file, so its adoption cutoff applies at the harness timeout, not a supervisor close request.
  • Qualify SandboxSession's service-lifetime docstring, including the natural-exit limitation.

The associated #3902 description correction scopes the evidence: Pi/Codex/OpenCode certificate runs exercise deadline drain under a real model; preservation of services already adopted before a forced stop is covered only by Linux regressions. Synthetic service controls exercise normal completion.

No separate issue is needed for these small corrections to the existing review. Runtime behavior, configuration and benchmark scoring are unchanged.

Validation: pre-commit run --all-files and git diff --check pass. A Python AST comparison confirms the changed Python file has identical executable code after stripping docstrings. Independent source/evidence review is recorded before publication. Runtime tests and fresh model smoke: N/A for prose-only changes.

Dependency: #3902 remains open at 30b121d4bc3c9d137749c997eb76e7205c9b6334. This draft targets its upstream pull-request/3902 mirror so the diff contains only these three files. After #3902 merges, rebase this follow-up onto main and retarget it there; do not merge into the CI mirror.

@yaoyu-33 yaoyu-33 added docs Documentation-only updates or documentation debt area:sandbox Sandbox providers, isolation, and sandbox runtime contracts labels Oct 14, 2026
@copy-pr-bot

copy-pr-bot Bot commented Oct 14, 2026

Copy link
Copy Markdown

This pull request requires additional validation before any workflows can run on NVIDIA's runners.

Pull request vetters can view their responsibilities here.

Contributors can view more details about this message here.

@copy-pr-bot
copy-pr-bot Bot deleted the branch NVIDIA-NeMo:pull-request/3902 October 14, 2026 17:37
@copy-pr-bot copy-pr-bot Bot closed this Oct 14, 2026
github-merge-queue Bot pushed a commit that referenced this pull request Oct 14, 2026
Clarify the cleanup contract for task recipes and shared sandbox
sessions, following the [non-blocking approval notes on
#3902](#3902 (review))
and the [service-timing
comment](#3902 (comment)).

- Explain that previously adopted children outside the harness group
include unfinished background jobs such as `make &`, which can keep
writing during verification. Describe the service-launch timing needed
before a forced stop and the cleanup of newly orphaned children.
- Correct sandboxed Hermes guidance: its adoption cutoff applies at the
harness timeout, not on close, because the runner never signals the
supervisor (a stop file only fences delayed launches).
- Qualify `SandboxSession`'s service-lifetime docstring, including the
natural-exit limitation.
- Correct the drain timing: in-flight tools are killed during the drain
after the grace period, adoption follows the launching process's exit,
and descendants of a preserved process also survive.

The associated #3902 description correction scopes the evidence:
Pi/Codex/OpenCode certificate runs exercise deadline drain under a real
model; preservation of services already adopted before a forced stop is
covered only by Linux regressions. Synthetic service controls exercise
normal completion.

No separate issue is needed for these small corrections to the existing
review. Runtime behavior, configuration and benchmark scoring are
unchanged.

Validation: `pre-commit run --from-ref origin/main --to-ref HEAD` and
`git diff --check` pass. A Python AST comparison confirms
`sandbox_session.py` has identical executable code to `main` after
stripping docstrings. `process_supervisor.py`, `supervisor_client.py`
and `hermes_sandboxed_agent/app.py` are unchanged on `main` since the
reviewed #3902 head (`30b121d4b`), so the documented behavior still
matches the code. Runtime tests and fresh model smoke: N/A for
prose-only changes.

Supersedes #4604, which closed automatically when #3902 merged and its
`pull-request/3902` CI mirror base was deleted. This branch is rebased
onto `main` (after the #3902 squash merge, 8bd25f3), so the diff
contains only these three files.

🤖 Generated with [Claude Code](https://claude.com/claude-code)

---------

Signed-off-by: yaoyu-33 <[email protected]>
Co-authored-by: Claude Opus 5.5 <[email protected]>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

area:sandbox Sandbox providers, isolation, and sandbox runtime contracts docs Documentation-only updates or documentation debt

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant