|
Post by Powderjockey on Jun 18, 2022 12:56:43 GMT -8
Traceback (most recent call last): File "WeatherSenseMonitor.py", line 6, in <module> import wirelessSensors File "/home/pi/SDL_Pi_WeatherSense/wirelessSensors.py", line 18, in <module> import util File "/home/pi/SDL_Pi_WeatherSense/util.py", line 4, in <module> from past.utils import old_div ModuleNotFoundError: No module named 'past'
|
|
|
Post by Jason on Jun 18, 2022 16:39:36 GMT -8
Pretty sure sudo pip3 install past should do the trick
Thanks,
Jason
|
|
|
Post by Powderjockey on Jun 19, 2022 7:07:15 GMT -8
Pretty sure sudo pip3 install past should do the trick Thanks, Jason I tried that before and received the message below. I searched around for the error and it advised to in stall "future". That hasn't worked either. pi@SkyWeather:~$ pip3 install past Looking in indexes: https://pypi.org/simple, https://www.piwheels.org/simple Collecting past Could not find a version that satisfies the requirement past (from versions: ) No matching distribution found for past pi@SkyWeather:~$
|
|
|
Post by Jason on Jun 19, 2022 7:24:25 GMT -8
Have you tried the apt version python3-future?
Thanks,
Jason
|
|
|
Post by Powderjockey on Jun 19, 2022 7:45:01 GMT -8
Have you tried the apt version python3-future? Thanks, Jason Thanks, that worked, now another error. I'll work thru it. adding items not installed. sudo python3 WeatherSenseMonitor.py using updateWebConfig Traceback (most recent call last): File "WeatherSenseMonitor.py", line 6, in <module> import wirelessSensors File "/home/pi/SDL_Pi_WeatherSense/wirelessSensors.py", line 22, in <module> from paho.mqtt import publish ModuleNotFoundError: No module named 'paho' Installed the paho package. using updateWebConfig Traceback (most recent call last): File "WeatherSenseMonitor.py", line 6, in <module> import wirelessSensors File "/home/pi/SDL_Pi_WeatherSense/wirelessSensors.py", line 24, in <module> import aqi ModuleNotFoundError: No module named 'aqi'
No python aqi for python3 in either the pip3 or apt.
|
|
|
Post by SDL on Jun 19, 2022 9:58:01 GMT -8
From the README.md
sudo pip3 install python-aqi
BP
|
|
|
Post by Powderjockey on Jun 19, 2022 18:10:51 GMT -8
When I run sudo python3 WeatherSenseMonitor.py I get the following:
pi@SkyWeather:~/SDL_Pi_WeatherSense $ sudo python3 WeatherSenseMonitor.py using updateWebConfig -------- MySQL Database WeatherSenseWireless Updates Not Installed. Run this command: sudo mysql -u root -p WeatherSenseWireless < updateWeatherSenseWireless.sql WeatherSenseMonitor Stopped -------- WeatherSenseMonitor Requirements Error Exit But when I when I run sudo mysql -u root -p WeatherSenseWireless < updateWeatherSenseWireless.sql as suggested above, I get the following:
Enter password: ERROR 1146 (42S02) at line 5: Table 'WeatherSenseWireless.AQI433MHZ' doesn't exist
|
|
|
Post by Powderjockey on Jun 20, 2022 14:47:53 GMT -8
MariaDB [(none)]> show databases; +----------------------+ | Database | +----------------------+ | SkyWeather | | WeatherSenseWireless | | information_schema | | mysql | | performance_schema | | phpmyadmin | +----------------------+ 6 rows in set (0.007 sec)
MariaDB [(none)]>
|
|
|
Post by doxidad on Jun 20, 2022 16:34:00 GMT -8
Use the script WeatherSenseWireless.sql
It won't try to re-create the the WeatherSenseWireless database if it already exists.
It will check to see if the tables needed are present and if not it will creates them.
|
|
|
Post by Powderjockey on Jun 20, 2022 17:05:44 GMT -8
Use the script WeatherSenseWireless.sql Not quite sure what you mean or which script?
|
|
|
Post by doxidad on Jun 20, 2022 17:25:51 GMT -8
sudo mysql -p -u root < WeatherSenseWireless.sql
|
|
|
Post by Powderjockey on Jun 20, 2022 17:28:05 GMT -8
sudo mysql -p -u root < WeatherSenseWireless.sql sudo mysql -u root -p < WeatherSenseWireless.sql Enter password: ERROR 1046 (3D000) at line 5: No database selected I'm not sure what I'm doing wrong with this. Not that complicated. But frustrating.
|
|
|
Post by doxidad on Jun 21, 2022 3:22:39 GMT -8
Whoops! It should be
sudo mysql -p -u root WeatherSenseWireless < WeatherSenseWireless.sql
I forgot the database name. Note to self: Read what you write before committing it!
|
|
|
Post by Powderjockey on Jun 21, 2022 15:13:58 GMT -8
Whoops! It should be sudo mysql -p -u root WeatherSenseWireless < WeatherSenseWireless.sqlI forgot the database name. Note to self: Read what you write before committing it! pi@SkyWeather:~/SDL_Pi_WeatherSense $ sudo mysql -p -u root WeatherSenseWireless < WeatherSenseWireless.sql Enter password: ERROR 1146 (42S02) at line 5: Table 'WeatherSenseWireless.AQI433MHZ' doesn't exist
|
|
|
Post by Powderjockey on Jun 21, 2022 15:18:45 GMT -8
MariaDB [(none)]> show databases; +----------------------+ | Database | +----------------------+ | SkyWeather | | WeatherSenseWireless | | information_schema | | mysql | | performance_schema | +----------------------+ 5 rows in set (0.001 sec)
MariaDB [(none)]> use WeatherSenseWireless; Database changed MariaDB [WeatherSenseWireless]> show tables; Empty set (0.001 sec)
MariaDB [WeatherSenseWireless]> So if I follow the instructions, why is the database WeatherSenseWireless empty of tables?
This is what shows in the directory:
root@SkyWeather:/var/lib/mysql/WeatherSenseWireless# ls db.opt root@SkyWeather:/var/lib/mysql/WeatherSenseWireless#
|
|