ImportError: cannot import name 'Location' from 'astral'
WhyNotHugo opened this issue · comments
Running automathemely
fails for me:
➜ automathemely
Traceback (most recent call last):
File "/usr/bin/automathemely", line 11, in <module>
load_entry_point('AutomaThemely==1.3', 'console_scripts', 'automathemely')()
File "/usr/lib/python3.8/site-packages/automathemely/bin/run.py", line 29, in main
from automathemely.autoth_tools import argmanager, extratools, envspecific, updsuntimes
File "/usr/lib/python3.8/site-packages/automathemely/autoth_tools/updsuntimes.py", line 8, in <module>
from astral import Location
ImportError: cannot import name 'Location' from 'astral' (/usr/lib/python3.8/site-packages/astral/__init__.py)
Looking at astral's code, it seems that this should probably be from astral.location import Location
? This was changed upstream mid-2019.
I got it to work by changing a few lines, as in #41
I still got this error today, it was changed on master branch?
@AndersonGI See #41
Closing this, discussion can carry on there.
Ok. Probably you guys already thought of using geoclue istead of this one, but if not yet, here it comes a suggestion.