forked from goodboy/tractor
1
0
Fork 0
tractor/tractor
Tyler Goodlet 3f9b860210 Obviously keying on tasks isn't going to work
Using the current task as a subscription key fails horribly as soon as
you hand off new subscription receiver to another task you've spawned..

Instead use the underlying ``trio.abc.ReceiveChannel.clone()`` as a key
(so i guess we're assuming cloning is supported by the underlying?)
which makes this all work just like default mem chans. As a bonus, now
we can just close the underlying rx (which may be a clone) on
`.aclose()` and everything should just work in terms of the underlying
channels lifetime (i think?).

Change `.subscribe()` to be async since the receive channel type
interface only expects `.aclose()` and it actually ends up being
nicer for 3.9+ style `async with` parentheses style anyway.
2021-09-01 06:39:21 -04:00
..
testing Drop trailing comma 2021-07-06 08:23:29 -04:00
__init__.py Expose streaming components at top level 2021-07-06 08:23:29 -04:00
_actor.py Hide `_invoke()` tb, move actor error to exceptions mod 2021-07-31 13:56:26 -04:00
_broadcast.py Obviously keying on tasks isn't going to work 2021-09-01 06:39:21 -04:00
_child.py Docstring to the top\!, and redundant spaces goodbye\! 2020-07-29 15:39:38 -03:00
_debug.py Docs and comments tidying 2021-08-01 10:44:13 -04:00
_discovery.py De-densify some code 2021-07-06 08:23:30 -04:00
_entry.py Support sync code breakpointing via built-in 2021-02-21 12:36:00 -05:00
_exceptions.py Hide `_invoke()` tb, move actor error to exceptions mod 2021-07-31 13:56:26 -04:00
_forkserver_override.py Ignore type checks on stdlib overrides 2021-02-21 14:08:23 -05:00
_ipc.py Change trace to transport level 2021-07-07 14:31:15 -04:00
_mp_fixup_main.py Fix more stdlib typing issues with latest mypy 2021-02-21 12:48:03 -05:00
_portal.py Mypy fixes 2021-07-08 12:48:34 -04:00
_root.py Don't log cancelled inceptions seen by the root 2021-08-02 21:15:42 -04:00
_spawn.py Hide `_invoke()` tb, move actor error to exceptions mod 2021-07-31 13:56:26 -04:00
_state.py Add a no runtime error 2021-04-28 12:23:08 -04:00
_streaming.py Drop stream shielding; it was from a legacy design 2021-09-01 06:37:53 -04:00
_trionics.py Drop leftover noisy exception logging.. 2021-08-02 16:56:00 -04:00
log.py Define explicit adapter level methods for mypy 2021-07-08 12:51:35 -04:00
msg.py Adjustments for non-frozen context dataclass change 2021-07-06 08:23:29 -04:00