tractor/tractor
Gud Boi 99be161ec0 Clean failed remote-task startup state
`Actor.start_remote_task()` registers its caller context before
sending `Start`, but only cancellation cleaned that state.
Encoding, ack timeout, malformed ack and remote authorization
errors leaked it.

Protect the complete send, acknowledgement and validation phase.
Track successful publication, make a remote cancellation attempt
only when protocol-safe and always release the local context while
preserving the original startup error.

Cover both pre-publication serialization failure and a remote
`ModuleNotExposed` rejection without damaging a reused portal.

Caught-during: review remediation
Found-via: `/run-tests` startup-failure regressions

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

Prompt-IO: ai/prompt-io/opencode/20260818T193004Z_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
..
_testing Make UDS reaping platform-aware 2026-08-14 10:36:27 -04:00
devx Fix `pformat_caller_frame()`s bogus `indent` kwarg 2026-08-18 20:13:07 -04:00
discovery Derive transport registries from one list 2026-08-14 23:17:09 -04:00
experimental Use `aid.uid` over manual `(name, uuid)` tuples 2026-06-27 21:38:30 -04:00
ipc Close interrupted `MsgTransport.send()` streams 2026-08-21 15:03:34 -04:00
msg Fix send-side `MsgTypeError` rendering 2026-08-20 11:57:39 -04:00
runtime Clean failed remote-task startup state 2026-08-21 15:03:34 -04:00
spawn Reap `to_actor.run()` children before return 2026-08-21 15:03:34 -04:00
to_actor Reap `to_actor.run()` children before return 2026-08-21 15:03:34 -04:00
trionics Match Trio's startup error exactly 2026-08-12 15:45:23 -04:00
__init__.py Add `tractor.to_actor` one-shot task API subpkg 2026-08-21 15:03:34 -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 Bound cancelled remote-task startup 2026-08-21 15:03:34 -04:00
_exceptions.py Fix send-side `MsgTypeError` rendering 2026-08-20 11:57:39 -04:00
_root.py Move registrar probes to `discovery._api` 2026-08-14 18:43:36 -04:00
_streaming.py Use `aid.uid` over manual `(name, uuid)` tuples 2026-06-27 21:38:30 -04:00
log.py Retain dynamic logger caller discovery 2026-08-12 20:52:47 -04:00
to_asyncio.py Add `maybe_signal_aio_task()` + cause-chain guard 2026-06-17 17:39:44 -04:00