import error
See original GitHub issueHi, when I try to run this classic api example:
import plotly.plotly as py
from plotly.graph_objs import *
py.sign_in("myusername", "mykey")
data = Data([
Bar(
x=['giraffes', 'orangutans', 'monkeys'],
y=[20, 14, 23]
)
])
plot_url = py.plot(data, filename='basic-bar')
I get this error:
Traceback (most recent call last):
File "test.py", line 1, in <module>
import plotly.plotly as py
File "/usr/local/lib/python2.7/dist-packages/plotly/__init__.py", line 31, in <module>
from plotly import plotly, graph_objs, tools, utils
File "/usr/local/lib/python2.7/dist-packages/plotly/plotly/__init__.py", line 12, in <module>
from plotly.plotly.plotly import *
File "/usr/local/lib/python2.7/dist-packages/plotly/plotly/plotly.py", line 29, in <module>
from plotly import tools
File "/usr/local/lib/python2.7/dist-packages/plotly/tools.py", line 20, in <module>
from . graph_objs import graph_objs
File "/usr/local/lib/python2.7/dist-packages/plotly/graph_objs/__init__.py", line 12, in <module>
from plotly.graph_objs.graph_objs import *
File "/usr/local/lib/python2.7/dist-packages/plotly/graph_objs/graph_objs.py", line 281, in <module>
@six.add_metaclass(ListMeta)
AttributeError: 'module' object has no attribute 'add_metaclass'
i’m on linux mint 16 - Python 2.7.5+ Any clues ?
Issue Analytics
- State:
- Created 9 years ago
- Comments:11
Top Results From Across the Web
How to Fix ImportError: Cannot Import Name in Python - Rollbar
The Python ImportError: cannot import name error occurs when an imported class is not accessible or is in a circular dependency.
Read more >Python Exception Handling: ImportError and ... - Airbrake Blog
The ImportError is raised when an import statement has trouble successfully importing the specified module. Typically, such a problem is due to ...
Read more >Python Import Error (ModuleNotFoundError) - Finxter
Python's ImportError ( ModuleNotFoundError ) indicates that you tried to import a module that Python doesn't find. It can usually be eliminated by...
Read more >import error: 'No module named' *does* exist - python
I set the PYTHONPATH to '.' and that solved it for me. export PYTHONPATH='.' For a one-liner you could as easily do: PYTHONPATH='....
Read more >How to catch ImportError Exception in Python? - Tutorialspoint
ImportError is raised when a module, or member of a module, cannot be imported. There are a two conditions where an ImportError might...
Read more >Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start FreeTop Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Top GitHub Comments
Hi i am new to using mac and trying to install plotly on mac using python 2.7. pip install plotly (worked) pip install --upgrade plotly (worked) Still i am getting import error as follows:
thanks for help.
That was it! Have misunderstood what “–upgrade” is for, as I thought I have installed the latest stable version with “pip install plotly” anyway. Apparently the dependencies where upgraded too.
Thanks, you made my day!
Márk
2014-08-16 22:18 GMT+02:00 Charles-Emmanuel notifications@github.com: