Skip to content

fix(sandbox): Recover closed streams for read tools#966

Draft
sentry-junior[bot] wants to merge 1 commit into
mainfrom
fix/recover-closed-sandbox-file-tools
Draft

fix(sandbox): Recover closed streams for read tools#966
sentry-junior[bot] wants to merge 1 commit into
mainfrom
fix/recover-closed-sandbox-file-tools

Conversation

@sentry-junior

@sentry-junior sentry-junior Bot commented Jul 20, 2026

Copy link
Copy Markdown
Contributor

Recover read-only file tools when a cached Vercel sandbox closes during execution instead of allowing the stream error to abort the agent turn with a generic internal-error reply.

Safe Recovery

When readFile, grep, findFiles, or listDir encounters an unavailable sandbox, Junior recreates the sandbox and retries once. Mutating tools remain non-retriable so writes cannot be duplicated.

Regression Coverage

Adds coverage for a StreamError raised during grep traversal and verifies that execution continues against the replacement sandbox.

Refs JUNIOR-4N
Refs JUNIOR-4Z

Requested by Ben Henry via Junior.

--

View Junior Session

Co-Authored-By: Ben Henry <ben.henry@sentry.io>
@vercel

vercel Bot commented Jul 20, 2026

Copy link
Copy Markdown

The latest updates on your projects. Learn more about Vercel for GitHub.

Project Deployment Actions Updated (UTC)
junior-docs Ready Ready Preview Jul 20, 2026 8:10pm

Request Review

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.

0 participants