From b89fd9652ce815ee3411ee1f6a54f4f9705216c2 Mon Sep 17 00:00:00 2001 From: Tyler Goodlet Date: Thu, 5 Jan 2023 12:44:58 -0500 Subject: [PATCH] `binance`: always request an extra 1min OHLC bar Seems that by default their history indexing rounds down/back to the previous time step, so make sure we add a minute inside `Client.bars()` when the `end_dt=None`, indicating "get the latest bar". Add a breakpoint block that should trigger whenever the latest bar vs. the latest epoch time is mismatched; we'll remove this after some testing verifying the history bars issue is resolved. Further this drops the legacy `backfill_bars()` endpoint which has been deprecated and unused for a while. --- piker/fsp/_engine.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/piker/fsp/_engine.py b/piker/fsp/_engine.py index eb5eaff4..5d389e29 100644 --- a/piker/fsp/_engine.py +++ b/piker/fsp/_engine.py @@ -439,7 +439,7 @@ async def cascade( profiler.finish() async for i in istream: - # log.runtime(f'FSP incrementing {i}') + # print(f'FSP incrementing {i}') # respawn the compute task if the source # array has been updated such that we compute