fix(gateway): delete finalized ephemeral sandboxes while connected - #3984
Conversation
Start driver cleanup after terminal finalization and retain disconnect fallback. Add detached success and failure e2e coverage across supervisor-based drivers. Closes #3938 Signed-off-by: John Myers <9696606+johntmyers@users.noreply.github.com>
E2E Test AttestationLocal Docker e2e passed for the code committed in Command: Gateway mode: Docker, with gateway and runtime images built from this branch. Result: 2 cleanup tests passed, 0 failed, 0 skipped (4.96 seconds); all six prerequisite conformance scenarios passed. Tests executed:
Both cleanup tests observed driver resources before releasing the canonical process, then verified that the gateway record and driver resources disappeared without a test-issued delete. The final |
|
Label |
drew
left a comment
There was a problem hiding this comment.
gator-agent
PR Review Status
PR #3984 is project-valid through accepted issue #3938. The independent initial review found no blocking findings, and the existing documentation already describes the restored ephemeral-cleanup behavior.
Action required: A maintainer must open E2E run 36762320399 and choose Re-run all jobs so the required current-head E2E suite executes with test:e2e applied.
Blocking findings:
- No blocking findings remain
Carried findings:
- None
Non-blocking suggestions:
- None
Gator metadata
- Validation: Accepted issue #3938 covers this focused gateway lifecycle fix; the PR author is a repository admin.
- Docs: Not needed because this restores the published
--detach --no-keeplifecycle without changing the user contract. - Checks: Branch Checks, Helm Lint, Trivy Changes, DCO, and vouch passed on the current head; required E2E dispatch remains outstanding.
- E2E:
test:e2eapplied; E2E Label Help requires Re-run all jobs on run 36762320399. - Head SHA:
3c14bb866494851a99d1d377fadfd6f77cf839c5 - Base SHA:
7caff12d3c9013e7063d22391a76f775f6ce93b5 - Merge base SHA:
7caff12d3c9013e7063d22391a76f775f6ce93b5 - Patch ID:
284e7c9ae4b350c725eb10a8a8c81f08bcb800fa - Gator payload:
10 - Review mode:
initial - Previous reviewed SHA: none
- Review budget exhausted: no
- Maintainer decision required: no
- Next state:
gator:blocked - Blocked reason:
test_dispatch_required
|
/ok to test 3c14bb8 |
Monitoring CompleteMonitoring is complete because this PR has merged. Final status: The reviewed head was approved, required checks including Core E2E passed, and the PR merged successfully. I removed the active Gator metadata
|
Summary
Detached
--no-keepsandboxes could remain inCompletedorErrorindefinitely because their supervisor kept its control session connected after the canonical process exited. Start driver deletion when the terminal result is finalized, so cleanup completes while that session is still connected.Related Issue
Closes #3938
Changes
Testing
mise run pre-commitpassesOPENSHELL_E2E_DOCKER_TEST=ephemeral_cleanup mise run e2e:docker: both cleanup tests and all six conformance scenarios passmise run cipasses, including the full unit suiteEarlier local test attempts timed out in
proxy::tests::mediated_connect_keeps_workload_bytes_read_with_the_synthesized_headerinopenshell-supervisor-network; that test passed in the final full CI run. This PR does not change that crate. Live Podman, Kubernetes, and VM runs were not performed locally.Checklist