Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Line chart zoom sync bug #15

Open
danieltsoukup opened this issue Aug 3, 2024 · 3 comments
Open

Line chart zoom sync bug #15

danieltsoukup opened this issue Aug 3, 2024 · 3 comments
Labels
bug Something isn't working good first issue Good for newcomers wontfix This will not be worked on

Comments

@danieltsoukup
Copy link
Collaborator

danieltsoukup commented Aug 3, 2024

Describe the bug
If one line chart is zoomed in and then the other zoomed out, the second syncing does not happen despite the current callback watching for changes in plot properties.

To Reproduce
Start the dashboard.

  1. Zoom in the first chart (the two plots will sync still).
  2. Zoom out on the second chart.
  3. See error: now the two plots are out of sync.
image

Expected behavior
The syncing callback should keep the two line chart zoom setting in sync at all times regardless of the order of zooming.

Additional context
Look at app_components.py and the update_zoom() callback.

@danieltsoukup danieltsoukup added bug Something isn't working good first issue Good for newcomers labels Aug 3, 2024
@Zen-cronic
Copy link

I was debugging update_zoom and found that:

  1. The reverse case can happen too: zoom out on 2nd (raw) and zoom in on 1st (hourly).
  2. The above happens because update_zoom is not triggered for that particular zoom.
  3. Upstream issue from dash (the same problem as this) hasn't been addressed yet.

A workaround is to click again (zoom in or out on either plot) and both plots should be synced.

@danieltsoukup
Copy link
Collaborator Author

Hey @Zen-cronic thanks for looking into this and linking the dash issue! I feel we can park this task for now given that this is a known problem in dash.

@Zen-cronic
Copy link

Agreed. Let's keep an eye on the upstream repo.

@danieltsoukup danieltsoukup added the wontfix This will not be worked on label Oct 12, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working good first issue Good for newcomers wontfix This will not be worked on
Projects
None yet
Development

No branches or pull requests

2 participants