-
-
Notifications
You must be signed in to change notification settings - Fork 2.6k
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
6.0.0 vs. 5.24.1 → go.FigureWidget → same syntax broken output in JN 7.3.2 #4998
Comments
My index won't align either under 6.0.0, tested on py3.11.11 this morning, switched back to 5.2.4. I think there is a bug in index session, not sure what it is. |
Hi @XstormLeigh and @MichalRIcar , thanks for reporting - any chance either of you could post a reproducible example please? That would make it much easier (and faster!) to resolve, thanks 🙏 |
@MarcoGorelli
|
Sorry what's your data? If you post a complete reproducible examples which can be copied-and-pasted and run from top to bottom, this will be much easier to triage and resolve Here's a post I usually recommend on making reproducible examples in bug reports: https://matthewrocklin.com/minimal-bug-reports.html |
Just to further belabour the point: I've tried coming up with some code to reproduce the issue import plotly.graph_objects as go
from plotly.subplots import make_subplots
import pandas as pd
import numpy as np
date_rng = pd.date_range(start='2023-01-01', end='2023-01-10', freq='D')
y1 = np.random.randn(len(date_rng)).cumsum()
y2 = np.random.randn(len(date_rng)).cumsum()
fig = make_subplots(rows=2, cols=1, shared_xaxes=True, vertical_spacing=0.1,
subplot_titles=("Time Series 1", "Time Series 2"))
fig.add_trace(go.Scatter(x=date_rng, y=y1, name="Series 1"), row=1, col=1)
fig.add_trace(go.Scatter(x=date_rng[1:], y=y2[1:], name="Series 1"), row=2, col=1)
fig.show() but the plot looks fine: Could you please try to create a little example like this one which reproduces the issue? This will help narrow down where the issue is (e.g. is it in |
Hi, thank you @MarcoGorelli for such a prompt response. Here is a brief code which reproduces the issue on my side. Result from 6.0.0: Result from 5.24.1: Code:
python packages: |
I may be facing a similar issue as OP with empty plots rendering in v6.0.0 which worked perfectly in prior releases though my use case is Plotly within a Flask app. See my issue #5045 with a reproducible example. |
Hi,
I am using plotly for the last 5 years with the same syntax without an issue to show graphs in Jupyter Notebook (JN).
However, new v6 has broken functionality of the go.FigureWidget while transiting to anywidgets.
On the other hand, any other graphs (flow generates thousands of them across plotly lib) seems to work OK.
The usecase is that go.FigureWidget is inside python's widgets HBox to show dynamically two graphs next to each other in JN 7.3.2.
Please let me know what other info would be needed.
The code snippet goes like this:
Any version < 6 (e.g. 5.2.4) provides designed output:
Version 6 turns to (wrong size and no graph data is shown):
python packages versions:
notebook 7.3.2
ipywidgets 8.1.5
IPython 8.31.0
plotly 6.0.0
anywidget 0.9.13
The text was updated successfully, but these errors were encountered: