diff --git a/piker/data/history.py b/piker/data/history.py index aad7d49f..9d110bb2 100644 --- a/piker/data/history.py +++ b/piker/data/history.py @@ -418,6 +418,12 @@ async def start_backfill( start_dt = from_timestamp(start) end_dt = from_timestamp(end) + + # if we get a baddly ordered timestamp + # pair, imeeditately stop backfilling. + if end_dt < start_dt: + break + ( array, next_start_dt,