Answer the question
In order to leave comments, you need to log in
Error when running c pyowm code, what's the problem?
Hello, I copied exactly the code from the pyomw site ( https://github.com/csparpa/pyowm#example ), but when I run it, it gives an error:
C:\Users\Daniil Romin>"C:\Users\ Daniil Romin\Desktop\python\pyowm.py"
Traceback (most recent call last):
File "C:\Users\Daniil Romin\Desktop\python\pyowm.py", line 1, in
from pyowm import OWM
File "C: \Users\Daniil Romin\Desktop\python\pyowm.py", line 1, in
from pyowm import OWM
ImportError: cannot import name 'OWM' from partially initialized module 'pyowm' (most likely due to a circular import) (C: \Users\Daniil Romin\Desktop\python\pyowm.py)
The code itself I wrote :
from pyowm import OWM
12) I can not understand what the problem is! The version of pip and pyowm are new.
Answer the question
In order to leave comments, you need to log in
You cannot name a script the same as a module imported from it.
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question