BCDA-APS / gemviz

Data visualization for tiled
https://bcda-aps.github.io/gemviz/
Other
4 stars 0 forks source link

BUG: KeyError when primary stream does not exist #189

Closed prjemian closed 8 months ago

prjemian commented 11 months ago

Clicking on a run in the runs table and the run does not have a primary stream raises:

  File "/home/beams1/JEMIAN/Documents/projects/BCDA-APS/gemviz/gemviz/bluesky_runs_catalog.py", line 135, in doRunSelectedSlot
    self.brc_run_viz.setData(self.getDataDescription(run))
                             ^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/home/beams1/JEMIAN/Documents/projects/BCDA-APS/gemviz/gemviz/bluesky_runs_catalog.py", line 150, in getDataDescription
    analysis = run.plottable_signals()
               ^^^^^^^^^^^^^^^^^^^^^^^
  File "/home/beams1/JEMIAN/Documents/projects/BCDA-APS/gemviz/gemviz/tapi.py", line 108, in plottable_signals
    descriptors = self.stream_metadata(stream).get("descriptors", {})
                  ^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/home/beams1/JEMIAN/Documents/projects/BCDA-APS/gemviz/gemviz/tapi.py", line 248, in stream_metadata
    return self.streams_md[stream_name]
           ~~~~~~~~~~~~~~~^^^^^^^^^^^^^
KeyError: 'primary'

8idi_xpcs, uid=3d57d67a-d7b3-42d7-8d1c-b8bde7f5539e

prjemian commented 10 months ago

image