-
-
Notifications
You must be signed in to change notification settings - Fork 2.6k
fig.add_vline limited from 0 to 1 when rendered with plotly.offline #2980
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
Comments
I have the same issue [plotting only in row 1 between 0 and 1]. For me though, it appears when I plot in dash. add_vline works fine if I render in Spyder, png or the browser: python 3.8 |
I was able to reproduce the error with dash 4.13.0. It appears that it is a bug in the initial implementation of vline/hline in multiple graphs in version 4.12.0 - #2840. |
See my answer here https://community.plotly.com/t/why-does-the-vertical-line-created-by-add-vline-does-not-extend-indefinetely-on-the-y-axis/49683/3?u=nicolaskruchten ... you'll need to ensure your rendering environment has the latest Plotly.js version. See https://plotly.com/python/troubleshooting/ for details. |
From the troubleshooting guide: "first ensure that you have upgraded dash to the latest version, which will automatically upgrade dash-core-components to the latest version, ensuring that Dash is using an up-to-date version of the Plotly.js rendering engine for plotly." This is not completely true with conda, as upgrading dash does not automatically upgrade dash-core-components (at least in my corporate environment). I had dash-core-components 1.3.0 (Oct 2019?) and was able to upgrade to 1.15.0 using: That fixed my issue! Also, This is related to: https://community.plotly.com/t/why-does-the-vertical-line-created-by-add-vline-does-not-extend-indefinetely-on-the-y-axis/49683 |
Hi - we are trying to tidy up the stale issues and PRs in Plotly's public repositories so that we can focus on things that are still important to our community. Since this one has been sitting for several years, I'm going to close it; if it is still a concern, please add a comment letting us know what recent version of our software you've checked it with so that I can reopen it and add it to our backlog. Thanks for your help - @gvwilson |
The add_vline still have a weird issue,
fig.add_hline(x=2)
results in a line at 2 on the x axis but only extends from 0 to 1 on the y axis. The problem occurs only when plotly.offline is used to generate the HTML plot, while the problem doesn't occur in the Python Spyder console or using dash.Environment:
Python 3.7
Plotly 4.14.1
dash 1.18.1
Here how it is using plotly.offline to generate the HTML plot (error occurs):

Here how it looks in the Spyder console:

Here how it looks in dash:

The text was updated successfully, but these errors were encountered: