diff --git a/piker/data/_sampling.py b/piker/data/_sampling.py index 2079eb71..566f2b07 100644 --- a/piker/data/_sampling.py +++ b/piker/data/_sampling.py @@ -227,7 +227,8 @@ async def sample_and_broadcast( # end up triggering backpressure which which will # eventually block this producer end of the feed and # thus other consumers still attached. - subs = bus._subscribers[sym] + subs = bus._subscribers[sym.lower()] + for ctx in subs: # print(f'sub is {ctx.chan.uid}') try: diff --git a/piker/data/feed.py b/piker/data/feed.py index 1a24b29a..1097de50 100644 --- a/piker/data/feed.py +++ b/piker/data/feed.py @@ -203,7 +203,10 @@ async def allocate_persistent_feed( # TODO: make this into a composed type which also # contains the backfiller cs for individual super-based # resspawns when needed. - bus.feeds[symbol] = (cs, init_msg, first_quote) + + # XXX: the ``symbol`` here is put into our native piker format (i.e. + # lower case). + bus.feeds[symbol.lower()] = (cs, init_msg, first_quote) if opened: # start history backfill task ``backfill_bars()`` is @@ -272,7 +275,12 @@ async def attach_feed_bus( ctx=ctx, bus=bus, brokername=brokername, + + # here we pass through the selected symbol in native + # "format" (i.e. upper vs. lowercase depending on + # provider). symbol=symbol, + loglevel=loglevel, ) ) @@ -411,7 +419,7 @@ async def install_brokerd_search( provider_name=brokermod.name, search_routine=search, - pause_period=brokermod._search_conf.get('pause_period'), + pause_period=brokermod._search_conf.get('pause_period', 0.0616), ): yield diff --git a/piker/ui/_chart.py b/piker/ui/_chart.py index 96424c14..64646da3 100644 --- a/piker/ui/_chart.py +++ b/piker/ui/_chart.py @@ -1538,7 +1538,6 @@ async def chart_symbol( }, }) - async with trio.open_nursery() as n: # load initial fsp chain (otherwise known as "indicators") @@ -1598,6 +1597,7 @@ async def load_providers( # search engines. for broker in brokernames: + log.info(f'Loading brokerd for {broker}') # spin up broker daemons for each provider portal = await stack.enter_async_context( maybe_spawn_brokerd( diff --git a/piker/ui/_search.py b/piker/ui/_search.py index a57894b0..27b3e360 100644 --- a/piker/ui/_search.py +++ b/piker/ui/_search.py @@ -497,7 +497,6 @@ async def fill_results( search: SearchBar, symsearch: Callable[..., Awaitable], recv_chan: trio.abc.ReceiveChannel, - # cached_symbols: Dict[str, # kb debouncing pauses min_pause_time: float = 0.0616,