Formatting

stream_contexts
Tyler Goodlet 2021-04-27 11:08:20 -04:00
parent 897ab79946
commit 81f3558494
2 changed files with 4 additions and 1 deletions

View File

@ -4,7 +4,6 @@ Inter-process comms abstractions
import typing
from typing import Any, Tuple, Optional
from functools import partial
import inspect
import msgpack
import trio

View File

@ -29,9 +29,13 @@ async def fan_out_to_ctxs(
return tuple(topics2ctxs.keys())
agen = pub_async_gen_func(get_topics=get_topics)
async with aclosing(agen) as pub_gen:
async for published in pub_gen:
ctx_payloads: Dict[str, Any] = {}
for topic, data in published.items():
log.debug(f"publishing {topic, data}")
# build a new dict packet or invoke provided packetizer