diff --git a/packages/cli/src/zed-integration/zedIntegration.ts b/packages/cli/src/zed-integration/zedIntegration.ts index 7769ce2780..350fa004ff 100644 --- a/packages/cli/src/zed-integration/zedIntegration.ts +++ b/packages/cli/src/zed-integration/zedIntegration.ts @@ -318,6 +318,13 @@ class Session { ); } + if ( + pendingSend.signal.aborted || + (error instanceof Error && error.name === 'AbortError') + ) { + return { stopReason: 'cancelled' }; + } + throw error; }