You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
Aborted tool permission/question waits survive cancellation and late approval can write files #601
An actual SessionPrompt run calls read then edit with edit permission set to ask and no permission timeout. After prompt.cancel returns and the runner ends, the permission remains pending. A stale once reply writes the aborted replacement to disk. Question and MCP permission waits also remain pending on unchanged base.
Mechanism
SessionTools execute callbacks start EffectBridge.promise fibers without the SDK AbortSignal. Cancel interrupts the stream but not the independent tool fiber, so permission/question finalizers and an EditTool file semaphore are not released.
Expected
Interrupt pending tool permission/question waits on session cancellation, reject stale replies, release edit locks and prevent post-abort writes. Preserve the existing Bash contract: stop its process and deliver captured/truncated interrupted output rather than discarding it.
Verification scope
Real prompt/SDK tests cover late edit approval, a fresh same-path edit after abort, question cleanup, MCP permission cleanup and Bash permission cancellation. This is not a claim that every external MCP transport cancels its remote side effects. HTTP routes use the same cancel boundary but are not independently retested in this fix yet.
Activity