Skip to content

FIREFLY-2155: Fix multi-chart views freezing the app on spectral lines plotting - #2055

Merged
jaladh-singhal merged 1 commit into
devfrom
FIREFLY-2155-line-plotting-bug
Oct 30, 2026
Merged

jaladh-singhal merged 1 commit into
devfrom
FIREFLY-2155-line-plotting-bug

Conversation

@jaladh-singhal

Copy link
Copy Markdown
Member

Fixes FIREFLY-2155

Loading spectral lines hung the browser in multi-chart views, e.g. Euclid's data product spectra (one row → 3 spectrum charts) and Pinned Charts after using Zoom/Pan. Plotly emits plotly_selected on its own whenever it fully redraws a chart whose layout.selections (the persisted box/lasso selection outline) is set, even to [], which Firefly sets after table selection syncs, Zoom/Pan and clearing a selection. PlotlyWrapper treated that event as a user selection and activated the chart; activating one chart re-rendered the others, and with spectral lines on that re-render became a full redraw, so the charts kept activating each other in a loop.

A chart is now only activated on plotly_selected after a plotly_selecting event, which Plotly only emits during a user's box/lasso drag.

Testing

https://firefly-2155-line-plotting-bug.irsakubedev.ipac.caltech.edu/applications/euclid/

  • Search by ID → DR1, deep_survey, 2626785781669233495 → Spectra tab → Spectral lines → load SPHEREx line list → all 3 charts get lines, no hang

https://firefly-2155-line-plotting-bug.irsakubedev.ipac.caltech.edu/firefly/

  • Pinned charts: upload any 2 spectra, check "interpret as spectra" and pin each → Pinned Charts → click each chart and then Zoom (or Pan) in the toolbar → Spectral lines → load SPHEREx line list → lines plot, no hang; toggle the lines' select-all a few times → still responsive
  • Regression: clicking a chart, or box/lasso selecting on a chart that isn't active, still makes it active; select/filter on the box selection still work

@jaladh-singhal jaladh-singhal added this to the 2026.4 milestone Oct 30, 2026
@jaladh-singhal jaladh-singhal self-assigned this Oct 30, 2026
@jaladh-singhal jaladh-singhal added bug Charts Anything related to charts labels Oct 30, 2026

@kpuriIpac kpuriIpac left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks good. Thanks for the fix!
Testing works as decribed.

@lrebull

lrebull commented Oct 30, 2026

Copy link
Copy Markdown
Contributor

confirm this works! thank you!

@jaladh-singhal
jaladh-singhal merged commit d7d38e2 into dev Oct 30, 2026
2 checks passed
@jaladh-singhal
jaladh-singhal deleted the FIREFLY-2155-line-plotting-bug branch October 30, 2026 17:03
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

bug Charts Anything related to charts

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants