Install & Compatibility
Where this runs
tested against v1.1.0 · pip install
no network on importno background threads
Install × environment matrix
Each cell = how many times install + import succeeded across repeated harness runs. Partial = flaky.
glibc = Debian/Ubuntu slim · musl = Alpine Linux
muslpy 3.10–3.95 runs
installs and imports cleanly · install 0.0s · import 0.112s · 92.9MB
glibcpy 3.10–3.95 runs
installs and imports cleanly · install 4.6s · import 0.100s · 93MB
93MB installed
● package 93MB
Code
Verified usage
Verified import paths — ran on the pinned version, not inferred.
plotly
✓ import plotly
✗ import chart_studio.plotly as py
chart_studio.plotly is the legacy Chart Studio interface; prefer plain plotly for offline charts.
plotly_plotly
✓ from chart_studio import plotly as py
✗ import plotly.plotly as py
plotly.plotly was removed after plotly v2. Use chart_studio.plotly for legacy chart_studio users.
plotly_credentials
✓ from chart_studio import plotly as py
py.sign_in(username, api_key)
✗ plotly.tools.set_credentials_file()
Credentials are now managed via chart_studio.
Basic example: set credentials and upload a figure to Chart Studio.
import chart_studio
import chart_studio.plotly as py
import plotly.graph_objects as go
chart_studio.tools.set_credentials_file(username='your_username', api_key='your_api_key')
fig = go.Figure(data=go.Bar(y=[2, 3, 1]))
py.plot(fig, filename='basic-bar', auto_open=True)
Errors
Common errors & fixes
AttributeError: module 'plotly' has no attribute 'plotly'
Migrating from old plotly (pre-v3) to newer versions: 'plotly.plotly' was removed. Use chart_studio.plotly for Chart Studio functionality.
fixReplace `import plotly.plotly as py` with `from chart_studio import plotly as py`.
ImportError: cannot import name 'plotly' from 'chart_studio' (unknown location)
chart_studio package not installed or version mismatch.
fixRun `pip install chart-studio` to install the package.
HTTPError: 401 Client Error: Unauthorized for url: https://api.plot.ly/v2/...
Credentials are missing, invalid, or expired.
fixSet credentials: `chart_studio.tools.set_credentials_file(username='your_username', api_key='your_api_key')`. Obtain API key from https://plotly.com/settings/api.
Upgrade
Version history
1.1.0latest on PyPI · released Apr 1, 2020
Audit
Dependencies
No dependency data recorded yet.