From 2b9ca5f805c27540931319f946c19e89a7c35f2b Mon Sep 17 00:00:00 2001 From: Tyler Goodlet Date: Wed, 30 Nov 2022 11:00:48 -0500 Subject: [PATCH] Call `Viz.bars_range()` from display loop --- piker/ui/_display.py | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/piker/ui/_display.py b/piker/ui/_display.py index 07033a0c..dcc767c8 100644 --- a/piker/ui/_display.py +++ b/piker/ui/_display.py @@ -101,7 +101,8 @@ def chart_maxmin( Compute max and min datums "in view" for range limits. ''' - last_bars_range = chart.bars_range() + main_viz = chart.get_viz(chart.name) + last_bars_range = main_viz.bars_range() out = chart.maxmin(name=fqsn) if out is None: @@ -217,7 +218,8 @@ class DisplayState(Struct): append_diff = i_step - _i_last_append # real-time update necessary? - _, _, _, r = chart.bars_range() + main_viz = chart.get_viz(chart.name) + _, _, _, r = main_viz.bars_range() liv = r >= shm.index # update the "last datum" (aka extending the vizs graphic with