|
Post by renegade on Jun 16, 2021 19:41:40 GMT -8
I had a raspberry Pi 4b running skyweather for almost a year now, couple days ago i upgraded from Ubuntu 18.04 to 20.04 and skyweather is trashed it will not run.
I have corrected some errors but this one has put the nail in the coffin on it.
/home/active/SDL_Pi_SkyWeather# python SkyWeather.py Traceback (most recent call last): File "SkyWeather.py", line 92, in <module> import Scroll_SSD1306 File "/home/active/SDL_Pi_SkyWeather/Scroll_SSD1306.py", line 10, in <module> from pil import Image ImportError: No module named pil
Since Ubuntu 20.04 no longer comes with python2 and forces you to use python3 i am stuck and unable to get pil working so unless i rewrite the software for python2 its no longer usable in Ubuntu after 18.04.
I may try and rewrite it but just to get started every print command in every file need to be changed just to start which means it will take a lot of time.
Only other option is to downgrade the unit back to Ubuntu 18.04
|
|
|
Post by Jason on Jun 17, 2021 8:57:44 GMT -8
Does Ubuntu 20.04 not allow you to install Python2?
Thanks,
Jason
|
|
|
Post by Jason on Jun 17, 2021 8:58:46 GMT -8
Try this link. Thanks, Jason
|
|
|
Post by SDL on Jun 21, 2021 7:16:41 GMT -8
Have you tried installing "pil"?
No module named pil
Try:
sudo pip install pil
BP
P.S. If you are trying to convert the SkyWeather software to Python3 (SkyWeather2 is Python3) check on the forums. I'm pretty sure someone did this a while back.
|
|
|
Post by renegade on Jul 1, 2021 11:37:51 GMT -8
Ubuntu 20 breaks python2 most of the modules needed have no distribution sources anymore, since python2 is deprecated Ubuntu is forcing users to move to python 3 which i lmao should have seen if i had read the release notes before upgrading. I am going to port the skyweather software to python 3 since its likely the best way to fix it. First thing is to change every single "print" statement since that changed from python 2 to 3 and all the current ones will throw a syntax error now. The second thing that changed is the "import MySQLdb as mdb" since that is gone as well in python3. I will post the files here when i get it properly running under python3. I think my issue is also complicated by the fact I am running 64 bit ubunutu on my raspberry-pi 4B as well.
|
|
|
Post by Powderjockey on Jul 2, 2021 9:33:15 GMT -8
Ubuntu 20 breaks python2 most of the modules needed have no distribution sources anymore, since python2 is deprecated Ubuntu is forcing users to move to python 3 which i lmao should have seen if i had read the release notes before upgrading. I am going to port the skyweather software to python 3 since its likely the best way to fix it. First thing is to change every single "print" statement since that changed from python 2 to 3 and all the current ones will throw a syntax error now. The second thing that changed is the "import MySQLdb as mdb" since that is gone as well in python3. I will post the files here when i get it properly running under python3. I think my issue is also complicated by the fact I am running 64 bit ubunutu on my raspberry-pi 4B as well. Please do keep us up to date on the python3 change.
|
|