tractor/tractor
Gud Boi e617b498ec Merge the supervise error handlers into one
Step B2 of the `._ria_nursery` removal (issue #477; see
`ai/conc-anal/ria_nursery_removal_plan.md`). With the 2ndary
nursery gone (step B), the two nested error handlers in
`_open_and_supervise_one_cancels_all_nursery` collapse to one,

- the outer `except (Exception, BaseExceptionGroup,
  trio.Cancelled)` existed to catch errors bubbling from the
  old `._ria_nursery.__aexit__` reaper-group; that nursery no
  longer exists.
- trace shows the outer handler's `raise` was already DEAD: the
  inner handler records `errors[uid]` as its first action, so
  `errors` is always non-empty by the time anything could reach
  the outer handler, and the `finally`'s raise-from-`errors`
  always superseded the outer `raise`.
- so fold both into a single `except BaseException as
  _scope_err` guarding the lone daemon nursery; the `finally`
  (unchanged) still raises the collected `errors` as a single
  exc or `BaseExceptionGroup`.
- drop the now-unused `outer_err`/`inner_err` locals.

Behaviour-preserving (net ~30 lines lighter); the big diff is
the one-level de-indent of the handler body. The two remaining
`maybe_wait_for_debugger()` guards collapse to the single
pre-teardown wait.

Prompt-IO: ai/prompt-io/claude/20260702T222544Z_9201a2ed_prompt_io.md

(this patch was generated in some part by [`claude-code`][claude-code-gh])
[claude-code-gh]: https://github.com/anthropics/claude-code
2026-07-02 18:33:17 -04:00
..
_testing Uniquify no-runtime UDS `get_random()` paths 2026-06-29 18:08:50 -04:00
devx Fix informal-RST in docstrings for clean autodoc 2026-06-28 13:29:01 -04:00
discovery Fix informal-RST in docstrings for clean autodoc 2026-06-28 13:29:01 -04:00
experimental Use `aid.uid` over manual `(name, uuid)` tuples 2026-06-27 21:38:30 -04:00
ipc Fix uds `get_random` reaper-regex break (+2 nits) 2026-06-29 18:51:26 -04:00
msg Fix informal-RST in docstrings for clean autodoc 2026-06-28 13:29:01 -04:00
runtime Merge the supervise error handlers into one 2026-07-02 18:33:17 -04:00
spawn Hoist ria-reaping out of the spawn backends 2026-07-02 13:11:47 -04:00
to_actor Add `tractor.to_actor` one-shot task API subpkg 2026-07-02 12:10:19 -04:00
trionics Fix informal-RST in docstrings for clean autodoc 2026-06-28 13:29:01 -04:00
__init__.py Add `tractor.to_actor` one-shot task API subpkg 2026-07-02 12:10:19 -04:00
_child.py Add per-actor `setproctitle` via `devx._proctitle` 2026-06-17 17:39:44 -04:00
_clustering.py Use `.aid.uid` to avoid deprecation warns 2026-03-13 21:10:52 -04:00
_code_load.py Mv `load_module_from_path()` to a new `._code_load` submod 2026-02-11 21:03:29 -05:00
_context.py Fix informal-RST in docstrings for clean autodoc 2026-06-28 13:29:01 -04:00
_exceptions.py Fix informal-RST in docstrings for clean autodoc 2026-06-28 13:29:01 -04:00
_root.py Code-style, couple newline/ws tweaks 2026-06-24 16:20:50 -04:00
_streaming.py Use `aid.uid` over manual `(name, uuid)` tuples 2026-06-27 21:38:30 -04:00
log.py Fix `add_log_level()` re-registration value drift 2026-06-24 18:03:28 -04:00
to_asyncio.py Add `maybe_signal_aio_task()` + cause-chain guard 2026-06-17 17:39:44 -04:00