You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
plotly.express line documentation error in line_shape #2812
I got tripped up by this as well. My workaround was to set render_mode="svg" so plotly.express doesn't try to created a scattergl object like it does when render_mode="auto" is set as the default.
I also tried line_shape="linear"; render_mode="auto", which works fine. So basically one has to decide on performance vs. the line_shape.
I really want splines and also didn't notice that big a difference in the performance. (my plot is probably just over the large size though)
Hoping for a better solution from the plotly team!
Reacted by abogaard, jake horban, corvagliaandrea and BioScoutNick
Moving to the plotly.py repo, as there really isn't an issue in plotly.js, it's just the internal logic in px. Perhaps the right solution here is to prevent automatically switching from scatter to scattergl when spline is used? Any other options that scattergl does not support and should prevent switching? I guess another option would be if an error occurs in constructing the final scattergl objects, try switching back to scatter and see if the error disappears; if we get a new error just reraise the original one. Not sure about the performance implications of that, but it would be the most adaptable solution if these conditions change in future plotly.js versions.
{"logs": ["ERROR: \n Invalid value of type 'builtins.str' received for the 'shape' property of scattergl.line\n Received value: 'spline'\n\n
The 'shape' property is an enumeration that may be specified as:\n - One of the following enumeration values:\n ['linear', 'hv', 'vh', 'hvh', 'vhv']; datasheet.py:641"], "success": false, "time": 0.095167}
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 a while, 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. Alternatively, if it's a request for tech support, please post in our community forum. Thank you - @gvwilson
Activity
kevbroch commentedon Oct 7, 2020
I got tripped up by this as well. My workaround was to set
render_mode="svg"so plotly.express doesn't try to created a scattergl object like it does whenrender_mode="auto"is set as the default.I also tried
line_shape="linear"; render_mode="auto", which works fine. So basically one has to decide on performance vs. the line_shape.I really want splines and also didn't notice that big a difference in the performance. (my plot is probably just over the large size though)
Hoping for a better solution from the plotly team!
alexcjohnson commentedon Oct 7, 2020
Moving to the plotly.py repo, as there really isn't an issue in plotly.js, it's just the internal logic in px. Perhaps the right solution here is to prevent automatically switching from
scattertoscatterglwhensplineis used? Any other options thatscattergldoes not support and should prevent switching? I guess another option would be if an error occurs in constructing the finalscatterglobjects, try switching back toscatterand see if the error disappears; if we get a new error just reraise the original one. Not sure about the performance implications of that, but it would be the most adaptable solution if these conditions change in future plotly.js versions.ronak1009 commentedon Dec 1, 2022
I am also getting the error after migrating to Python 3.9 and plotly==5.10.0
Error comes for
Error message:
Does anyone know work-around to fix this issue ?
zupdaz commentedon Dec 24, 2022
Getting same error when I load my df from multiple csv.
gvwilson commentedon Jul 5, 2024
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 a while, 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. Alternatively, if it's a request for tech support, please post in our community forum. Thank you - @gvwilson