themoosman / weewx-ambientweatherapi-json

An AmbientWeather API driver for the weewx weather software using JSON.
14 stars 0 forks source link

No module named ambient_api.ambientapi #5

Closed cyberralf83 closed 4 years ago

cyberralf83 commented 4 years ago

Hello, After running an update I am now getting the "No module named ambient_api.ambientapi" error. I have tried uninstalling and then re-installing the with "sudo -H pip3 install ambient_api" but without luck. Here is a log:

Jun 10 00:25:32 PiBridge weewx[8373]: Starting weewx weather system: weewx. Jun 10 00:25:32 PiBridge systemd[1]: Started LSB: weewx weather system. Jun 10 00:25:32 PiBridge weewx[8389] DEBUG main: Initializing engine Jun 10 00:25:32 PiBridge weewx[8389] INFO weewx.engine: Loading station type ambientweatherapi (user.ambientweatherapi) Jun 10 00:25:32 PiBridge weewx[8389] CRITICAL main: Caught unrecoverable exception: Jun 10 00:25:32 PiBridge weewx[8389] CRITICAL main: No module named ambient_api.ambientapi Jun 10 00:25:32 PiBridge weewx[8389] CRITICAL main: Traceback (most recent call last): Jun 10 00:25:32 PiBridge weewx[8389] CRITICAL main: File "/usr/share/weewx/weewxd", line 148, in main Jun 10 00:25:32 PiBridge weewx[8389] CRITICAL main: engine = weewx.engine.StdEngine(config_dict) Jun 10 00:25:32 PiBridge weewx[8389] CRITICAL main: File "/usr/share/weewx/weewx/engine.py", line 69, in init Jun 10 00:25:32 PiBridge weewx[8389] CRITICAL main: self.setupStation(config_dict) Jun 10 00:25:32 PiBridge weewx[8389] CRITICAL main: File "/usr/share/weewx/weewx/engine.py", line 92, in setupStation Jun 10 00:25:32 PiBridge weewx[8389] CRITICAL main: import(driver) Jun 10 00:25:32 PiBridge weewx[8389] CRITICAL main: File "/usr/share/weewx/user/ambientweatherapi.py", line 9, in Jun 10 00:25:32 PiBridge weewx[8389] CRITICAL main: from ambient_api.ambientapi import AmbientAPI Jun 10 00:25:32 PiBridge weewx[8389] CRITICAL main: ImportError: No module named ambient_api.ambientapi Jun 10 00:25:32 PiBridge weewx[8389] CRITICAL main: Exiting. Jun 10 00:26:09 PiBridge weewxd: ambientweatherapi driver encountered an error. Jun 10 00:26:09 PiBridge weewx[3729] ERROR root: ambientweatherapi driver encountered an error. Jun 10 00:26:09 PiBridge weewxd: Error caught was: global name 'AmbientAPI' is not defined

themoosman commented 4 years ago

What happens if you run sudo pip3 install ambient_api?

cyberralf83 commented 4 years ago

pi@PiBridge:~ $ sudo pip3 install ambient_api Looking in indexes: https://pypi.org/simple, https://www.piwheels.org/simple Requirement already satisfied: ambient_api in /usr/local/lib/python3.7/dist-packages (1.5.5) Requirement already satisfied: requests in /usr/local/lib/python3.7/dist-packages (from ambient_api) (2.23.0) Requirement already satisfied: urllib3 in /usr/local/lib/python3.7/dist-packages (from ambient_api) (1.25.9) Requirement already satisfied: idna<3,>=2.5 in /usr/local/lib/python3.7/dist-packages (from requests->ambient_api) (2.9) Requirement already satisfied: certifi>=2017.4.17 in /usr/local/lib/python3.7/dist-packages (from requests->ambient_api) (2020.4.5.2) Requirement already satisfied: chardet<4,>=3.0.2 in /usr/local/lib/python3.7/dist-packages (from requests->ambient_api) (3.0.4)

themoosman commented 4 years ago

What changed from your previous config? This is weird. What version of weewx?

themoosman commented 4 years ago

@cyberralf83 Are you still seeing an issue? If no, I'd like to close this out.

cyberralf83 commented 4 years ago

I started on a fresh operating system and it worked. Thanks.