---
model: claude-fable-5
service: claude
session: 6db64ac6-6986-4505-9343-df4ee31e67db
timestamp: 2026-07-06T17:28:18Z
git_ref: ad42871e
scope: code
substantive: true
raw_file: 20260706T172818Z_ad42871e_prompt_io.raw.md
---

## Prompt

Resuming the `drop_ria_nursery` (wkt) branch after the human's
review pause at `ba4af0ad`, with the directive:

> we need to resolve the remaining outstandings ... to finish
> this endeavour we ideally,
> - finish the ria-tn hoist into the machinery in `to_actor` if
>   possible.
> - avoid supporting the `.run_in_actor()` non-blocking API
>   going forward other then if we can re-wrap `to_actor.run()`
>   per prior discussion with opus4.8.
> - get the test harness completely green locally and in CI -
>   AND ESPECIALLY without any hangs due to the "the old
>   spawn-backend reaper raced `soft_kill()`'s scope-cancel"
> - update all docs to reflect these changes once we're happy.

plus mid-flight additions:

> make sure both all the test and example code uses the naming
> `an: ActorNursery` for variable names

> where we at in terms of a potential hackaround design for
> supporting a to_actor.run_async() ... without requiring the
> same malarky ... with a `trio.Event` relay ... i'm totes fine
> with rejigging the iface to NOT return a Portal as well.

## Response summary

Completed the entire #477 `run_in_actor` removal on
`drop_ria_nursery` (16 commits this session), gated per-commit:

- ported the remaining `test_cancellation` groups
  (`some_cancels_all`, `nested_multierrors`+`spawn_and_error`,
  SIGINT + sync-sleep) — one-shots become concurrent
  `to_actor.run()` tasks in local task-nurseries; BEG-shape
  assertions loosened for cancel-on-first + the runtime's
  `collapse_eg()` single-member unwrap (a fully-raced nested
  tree relays a bare annotated `RemoteActorError` chain).
- fixed a pre-existing `UnboundLocalError` (`timeout` `match`
  had no default arm for non-trio/MTF backends).
- ported `test_dynamic_pub_sub`, 4 non-debugging examples, all
  8 `debugging/` examples (debugger suite byte-identical,
  28p/6s; `multi_subactors` introduces the "collect don't
  cancel" reap-all replacement pattern), 8 docs pages + the
  `experimental/_pubsub` docstring.
- EXCISED the API + cluster: `run_in_actor`,
  `_reap_ria_portals`, `_cancel_after_result_on_exit`,
  `Portal._submit_for_result/_expect_result_ctx/
  wait_for_result/result`, `exhaust_portal`,
  `cancel_on_completion`, `NoResult` — net -402 lines. The
  reap-hang class dissolves structurally (result-waits now only
  in caller task-scope).
- found + fixed a real migration race: mutual-rendezvous peers
  (`test_trynamic_trio`, `a_trynamic_first_scene.py`) flaked
  because an eagerly-reaped one-shot dies while its peer still
  dials the registry-resolved (dead) sockaddr — such peers now
  pin lifetimes via `start_actor()` + concurrent `Portal.run()`
  + explicit `an.cancel()`.
- `an: ActorNursery` naming sweep across tests/examples (±82
  lines, scoped renames, prose untouched).
- parked a `to_actor.open_one_shot()` design sketch (acm +
  private task-nursery over blocking `run()`; done-Event as
  memo not cancel-relay; no Portal) in the plan doc.

## Files changed

See commits `d01a2123..ad42871e` on `drop_ria_nursery`
(tests, examples, docs, `tractor/{runtime,spawn,to_actor,msg}`
+ `_exceptions/_context/experimental`).
