Skip to content

Executor errors and lost calls now show up in Sentry - #10

Open
fforres wants to merge 1 commit into
skywardfrom
feat/host-cloudflare-sentry
Open

fforres wants to merge 1 commit into
skywardfrom
feat/host-cloudflare-sentry

Conversation

@fforres

@fforres fforres commented Sep 26, 2026

Copy link
Copy Markdown

What changes for us

Executor (host-cloudflare) had no error reporting. Failures such as the session memory crash only showed as "Execution lost" for the caller and a warning line in Workers logs. They now land in the Sentry project skywardai/executor.

Change

  • The worker and the MCP session Durable Object are wrapped with @sentry/cloudflare (same pattern as apps/cloud).
  • Handled errors that reach ErrorCapture are sent to Sentry, tagged with the console trace id so an issue matches its Workers log line.
  • Every call the front worker has to answer with "Execution lost" is reported as MCP call lost: <reason> (session_reset or response_deadline). A Durable Object killed by its memory limit cannot report itself, so the front worker reports for it, through a hook added to the vendored agents patch.
  • New test: the hook fires once per lost call and never on a delivered response.
  • Disabled while SENTRY_DSN is unset. The secret is already set on executor-cloudflare.

Verified in production

Deployed from this branch. Forcing a Durable Object reset during a 40 s execution produced the Sentry issue "MCP call lost: session_reset" within seconds.

https://claude.ai/code/session_01VMqJkxznzTQaFVHHcttxpJ

The worker and the MCP session Durable Object are wrapped with
@sentry/cloudflare, handled errors that reach ErrorCapture are sent to Sentry
tagged with their console trace id, and every call the bridge has to answer
with "Execution lost" is reported from the front worker, since an isolate
killed by its memory limit cannot report itself. Disabled while SENTRY_DSN is
unset.

Claude-Session: https://claude.ai/code/session_01VMqJkxznzTQaFVHHcttxpJ

This branch has not been deployed

No deployments
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.

1 participant