tractor/tests/discovery
Gud Boi caebf60f4e Add dup-name cancel-cascade escalation test
Extend `test_register_duplicate_name` w/ cancel-level log
breadcrumbs and `try/finally` for better diag on the cancel-cascade
hang.

Add `test_dup_name_cancel_cascade_escalates_to_hard_kill` as a
regression test for the TCP+MTF duplicate-name cancel-cascade
deadlock. Spawns N same-name actors, calls `an.cancel()`, and
asserts teardown completes within a `trio.fail_after()` budget that
scales w/ `n_dups`.

Deats,
- parametrize `n_dups` (2, 4, 8) to widen the race window for
  concurrent `register_actor` RPCs.
- `n_dups=4` xfail'd — exposes a separate boot-race bug (doggy
  `rc=2` under rapid same-name spawn), tracked in #456.
- post-teardown asserts all `Portal` chans disconnect, verifying
  hard-kill escalation worked.

Relates to https://github.com/goodboy/tractor/issues/456

(this patch was generated in some part by [`claude-code`][claude-code-gh])
[claude-code-gh]: https://github.com/anthropics/claude-code
2026-05-07 23:33:23 -04:00
..
__init__.py Add `test_multiaddr.py` suite for `mk_maddr()` 2026-04-14 19:54:14 -04:00
conftest.py Mv `daemon` + `test_multi_program` to `discovery/` 2026-05-06 13:23:42 -04:00
test_multi_program.py Add dup-name cancel-cascade escalation test 2026-05-07 23:33:23 -04:00
test_multiaddr.py Add `parse_endpoints()` to `_multiaddr` 2026-04-14 19:54:14 -04:00
test_registrar.py Drop test-local timeouts, +`sync_pause` to dev 2026-04-29 18:10:40 -04:00
test_tpt_bind_addrs.py Fix `test_registrar_merge_binds_union` for UDS collision 2026-04-14 19:54:15 -04:00