tractor/ai/prompt-io
Gud Boi ecf89bfaac Close interrupted `MsgTransport.send()` streams
`SendStream.send_all()` can raise `trio.Cancelled` after writing an
arbitrary prefix of the four-byte length header and payload. The
peer can no longer distinguish a following msg boundary.

Close the stream under a shield before propagating cancellation so
callers can not append another msg to an indeterminate byte stream.

Caught-during: review remediation
Found-via: prospective P2 cancellation review

Review: PR #481 (opencode)
https://github.com/goodboy/tractor/pull/481#pullrequestreview-4956692120

Prompt-IO: ai/prompt-io/opencode/20260818T193001Z_bf06b4f8_prompt_io.md

(this patch was generated in some part by `opencode` using `gpt-5.6-sol` (`openai`))
2026-08-21 15:03:34 -04:00
..
claude Add `tractor.to_actor` one-shot task API subpkg 2026-08-21 15:03:34 -04:00
opencode Close interrupted `MsgTransport.send()` streams 2026-08-21 15:03:34 -04:00
prompts Add `tractor.to_actor` one-shot task API subpkg 2026-08-21 15:03:34 -04:00