tractor/docs/guide
Gud Boi 6429e6a515 Reject concurrent `BroadcastReceiver.receive()` calls
Two tasks could receive through one `BroadcastReceiver` and race its
single `_wait_scope`. A later call could replace the scope, leaving
the first blocked through `.aclose()`.

Track the active `trio.lowlevel.Task` per receiver and reject an
overlapping call with `trio.BusyResourceError`. Include the owner's
task name and repr in the error, then clear ownership in `finally`.

Define each receiver as one logical subscription cursor. Concurrent
consumers must use separate `.subscribe()` receivers so each retains
an independent cursor and lag policy. Strict mode reads every retained
value or raises `Lagged`; `raise_on_lag=False` explicitly permits
drops.

Cover the regression with a checkpoint loop synchronized on
`recv_ready`; explain the interleaving inline, assert the error names
the active consumer, then release the source and prove the original
receive remains usable.

Prompt-IO: ai/prompt-io/opencode/20260828T014247Z_d06ee34b_prompt_io.md

(this patch was generated in some part by `opencode` using `gpt-5.6-sol` (`openai`))
2026-08-27 22:11:55 -04:00
..
asyncio.rst Expose stream subscriber lag policy 2026-08-27 21:18:00 -04:00
cancellation.rst Clarify owned-child hard-reap docs 2026-08-25 15:56:38 -04:00
clustering.rst Clarify `to_actor.run()` ownership 2026-08-21 15:03:34 -04:00
context.rst Clarify `to_actor.run()` ownership 2026-08-21 15:03:34 -04:00
debugging.rst Write the big boi docs content tree 2026-06-28 13:29:01 -04:00
discovery.rst Document stable macOS UDS operation 2026-08-14 10:37:19 -04:00
index.rst Showcase `to_actor.run()` across docs 2026-08-21 15:03:34 -04:00
msging.rst Write the big boi docs content tree 2026-06-28 13:29:01 -04:00
parallelism.rst Showcase `to_actor.run()` across docs 2026-08-21 15:03:34 -04:00
rpc.rst Polish `to_actor` examples and references 2026-08-25 15:20:34 -04:00
spawning.rst Correct `to_actor.run()` target guidance 2026-08-21 15:03:35 -04:00
streaming.rst Reject concurrent `BroadcastReceiver.receive()` calls 2026-08-27 22:11:55 -04:00
testing.rst Make UDS reaping platform-aware 2026-08-14 10:36:27 -04:00