tractor/tractor
Tyler Goodlet c962a1fef9 Handle stale registrar entries; detect and delete
In cases where an actor's transport server task (by default handling new
TCP connections) terminates early but does not de-register from the
pertaining registry (aka the registrar) actor's address table, the
trying-to-connect client actor will get a connection error on that
address. In the case where client handles a (local) `OSError` (meaning
the target actor address is likely being contacted over `localhost`)
exception, make a further call to the registrar to delete the stale
entry and `yield None` gracefully indicating to calling code that no
`Portal` can be delivered to the target address.

This issue was originally discovered in `piker` where the `emsd`
(clearing engine) actor would sometimes crash on rapid client
re-connects and then leave a `pikerd` stale entry. With this fix new
clients will attempt connect via an endpoint which will re-spawn the
`emsd` when a `None` portal is delivered (via `maybe_spawn_em()`).
2026-02-19 19:17:32 -05:00
..
_testing Mk `.devx._debug` a sub-pkg `.devx.debug` 2025-07-14 00:00:12 -04:00
devx Add a `._trace.maybe_pause_bp()` for tpt-broken cases 2026-02-19 13:55:02 -05:00
experimental Add API-modernize-todo on `experimental._pubsub.fan_out_to_ctxs` 2025-07-08 18:05:05 -04:00
ipc Clean up `._transport` error-case comment 2026-02-19 16:18:39 -05:00
msg Drop `name=__name__` from all `get_logger()` calls 2026-02-11 21:04:49 -05:00
trionics Drop `name=__name__` from all `get_logger()` calls 2026-02-11 21:04:49 -05:00
__init__.py move tractor._ipc.py into tractor.ipc._chan.py 2025-07-08 12:57:28 -04:00
_addr.py Drop `name=__name__` from all `get_logger()` calls 2026-02-11 21:04:49 -05:00
_child.py Adjust `._child` instantiation of `Actor` to use newly named `uuid` arg 2025-07-08 12:57:28 -04:00
_clustering.py Fix cluster suite, chng to new `gather_contexts()` 2025-08-18 10:46:37 -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 Drop `trio`-exc-catching if tpt-closed covers them 2026-02-19 13:55:02 -05:00
_discovery.py Handle stale registrar entries; detect and delete 2026-02-19 19:17:32 -05:00
_entry.py Drop `name=__name__` from all `get_logger()` calls 2026-02-11 21:04:49 -05:00
_exceptions.py Move `.is_multi_cancelled()` to `.trioniics._beg` 2025-07-16 15:49:18 -04:00
_forkserver_override.py Re-license code base for distribution under AGPL 2021-12-14 23:33:27 -05:00
_mp_fixup_main.py Avoid importing mp for as long as possible 2022-02-17 11:55:26 -05:00
_multiaddr.py Fix doc string "its" typo.. 2025-03-20 19:50:31 -04:00
_portal.py Drop `trio`-exc-catching if tpt-closed covers them 2026-02-19 13:55:02 -05:00
_root.py Stuff from auto-review in https://github.com/goodboy/tractor/pull/412 .. 2026-02-19 16:20:21 -05:00
_rpc.py Less newlines in `._rpc` log msg 2026-02-19 16:31:54 -05:00
_runtime.py Add `Arbiter.delete_sockaddr()` to remove addrs 2026-02-19 19:17:32 -05:00
_spawn.py Add attempt at non-root-parent REPL guarding 2025-08-19 14:15:14 -04:00
_state.py Add initial `repl_fixture` support B) 2025-07-14 00:00:12 -04:00
_streaming.py Drop `trio`-exc-catching if tpt-closed covers them 2026-02-19 13:55:02 -05:00
_supervise.py Drop `name=__name__` from all `get_logger()` calls 2026-02-11 21:04:49 -05:00
log.py Cleaups per copilot PR review 2026-02-11 21:51:40 -05:00
to_asyncio.py Use bare `get_logger()` in `.to_asyncio` 2026-02-11 22:02:41 -05:00