Skip to content

fix(vercel): bound command output and clean up running processes - #245

Merged
earakely-scale merged 2 commits into
scaleapi:mainfrom
vercel-labs:fix/vercel-readiness-20261018
Oct 19, 2026
Merged

earakely-scale merged 2 commits into
scaleapi:mainfrom
vercel-labs:fix/vercel-readiness-20261018

Conversation

@erulkey

@erulkey erulkey commented Oct 19, 2026 •

Copy link
Copy Markdown
Contributor

Commands can accumulate unread output in memory, and their local stream tasks can outlive sandbox termination. Stalled SDK responses can also exceed the requested command timeout.

Spool unread output to temporary files, enforce a local deadline, and cancel and join command tasks when the sandbox is terminated, including through a fresh handle or when lookup reports that it is already gone. Completed output remains readable after wait(), and long output lines are preserved. Consumed spool space is reclaimed when a reader catches up. This bounds queued-output memory at the cost of local disk I/O.

Both task teardown paths now close the providers they construct. Shared providers remain open; a close failure or timeout is logged without replacing the termination result.

Validation: 8,401 unit/protocol tests passed with 20 skips, including 155 focused provider and teardown tests. The package builds and installs from its wheel. The Labs example also exercises the provider in a live Vercel evaluation, including saved output and termination through a fresh handle. See the example validation scope.

This PR changes provider behavior and cleanup only. The standalone example and launcher stay in the Labs repository. No configuration changes are required.

Upstream CI is waiting for maintainer approval: CodeBuild reports “Pull request approval required for starting a build.” The build has not run yet.

RetriggerView in GreptileConfidence Score: 5/5

The PR appears safe to merge; both previous findings are addressed and no new blocking issues were found.

Summary

The PR moves unread command output to temporary files, adds a local command deadline, and closes providers created for teardown.

The latest changes address both previous findings:

  • Vercel command output stays readable without filling memory.
  • Vercel commands stop when their requested timeout expires.
  • Sandbox termination stops command tasks from every handle.
  • Task teardown closes the providers it creates.

No new actionable issues were found. This review inspected code and tests; it did not run tests.

Reviews (2) · Last reviewed commit: "fix(vercel): finish missing-resource cle..." · Reviewed by Greptile

@erulkey
erulkey requested a review from a team as a code owner October 19, 2026 01:31
erulkey added a commit to vercel-labs/agentenv-framework that referenced this pull request Oct 19, 2026
Sync the source snapshot with scaleapi/agentenv-framework at 7ca617e and include the provider reliability fixes proposed in scaleapi#245.
Comment thread src/agent_env/providers/sandbox_providers/vercel/sandbox.py Outdated
Comment thread src/agent_env/providers/sandbox_providers/vercel/sandbox.py
@earakely-scale
earakely-scale merged commit dbd409f into scaleapi:main Oct 19, 2026
12 of 14 checks passed
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.

2 participants