Repository navigation
improvement(sandbox): return a timed-out workbench run's output and the files it already wrote - #9596
Merged
Merged
Conversation
…he files it already wrote A run_code call killed at its own timeout returned an empty stdout and only "timed out after Nms", so models reran long jobs from scratch. E2B's SDK throws a stream-less TimeoutError, which dropped the output the stream callbacks had already observed. - E2B adapter: a timed-out command returns the stdout/stderr its callbacks observed - Workbench runs (session sandboxes) that hit their own timeout throw a timeout abort carrying the output tail (64 KB) and the files already in the call's output directory; every existing timeout check still accepts it - The route returns that output in stdout with a 408 and says the workbench and its files persist, so the next call can rerun only the remaining work - Output goes through the same session provenance check and secret-name reporting as any other result; one-shot sandboxes and billing are unchanged
|
The latest updates on your projects. Learn more about Vercel for GitHub. |
Contributor
[Medium impact] The PR appears safe to merge. SummaryReturns partial output and saved file names when a workbench run reaches its own timeout.
No actionable new issues or confirmed repository-rule violations were found. Reviews (2) · Last reviewed commit: "fix(sandbox): keep a cancellation during..." · Reviewed by Greptile |
Contributor
There was a problem hiding this comment.
All reported issues were addressed across 8 files
Reply with feedback, questions, or to request a fix.
Turn on auto-fix | Re-trigger cubic
Collaborator
Author
Collaborator
Author
|
@cubic-dev-ai review this PR |
Contributor
@waleedlatif1 I have started the AI code review. It will take a few minutes to complete. |
This branch was previously deployed
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
stdout: ""and onlyFunction execution timed out after Nms, so the model reran long jobs from scratchTimeoutError; a timed-out command now returns the stdout/stderr the stream callbacks already observedSandboxExecutionTimeoutError— still atimeoutAbortError, so every existing timeout check accepts it — carrying the last 64 KB of output and the files already in the call's output directory (listing bounded to 3 s, best effort)stdoutwith the existing 408 and appends: how long the code ran, that the workbench and its files persist, which output files exist, and to rerun only the remaining workType of Change
Testing
__resolvedSecretNames, and no coste2b-session.test.ts,session-sandbox.test.ts,execute-request.test.ts,conformance.test.ts,session-cli.test.ts(422 tests) andbun run lint; type-check and audits run in CIChecklist
test-auditauthoring gate)