aceinnolab / Inkycal

Create awesome e-paper dashboards within minutes! Modularity? Check! Python3? Check? Works on Raspberry Pi Zero W? Check! Support for own modules? Check!
https://aceinnolab.github.io/Inkycal/
GNU General Public License v3.0
1.15k stars 124 forks source link

[BUG]: ImportError: libopenjp2.so (Related to Bookworm or Python3.11 ?) #348

Closed naeldavid closed 2 months ago

naeldavid commented 3 months ago

So I have a headless raspberry pi and while scrolling on github, I found Inkycal. For me it was happiness at first sight. Finally something to do with my raspberry pi ! I flashed my micro sd card with a brand new Raspi OS and followed all instructions. While running the code python3 inky_run.py I got this Import error : ImportError: libopenjp2.so.7: cannot open shared object file: No such file or directory

I made sure everything from the requirements.txt file was installed, even started off from scratch twice but I still get the issue. Any Help ?

image

Any module I should install ? Or is it a directory/file error and I need to re-install ?

github-actions[bot] commented 3 months ago

Hi there and welcome to Inkycal. Thanks for opening this issue. As this is your first issue in this repository, please read through the contributing guidelines

aceisace commented 3 months ago

@naeldavid Hi there, thanks for informing me about this. Are you sure you ran the following command from the README:

sudo apt-get install git zlib1g libjpeg-dev libatlas-base-dev rustc libopenjp2-7 python-dev-is-python3 scons libssl-dev python3-venv python3-pip git libfreetype6-dev wkhtmltopdf libopenblas-dev

This issue would be new to me as the tests on Raspberry Pi OS are passing. Which OS and version are you using?

naeldavid commented 3 months ago

Hey @aceisace, I'm sure I ran the command, did it 2 two times to make sure everything works but still get the issue. I have a Raspberry Pi Zero with Bookworm Running :

image

I re-flashed the micro-sd card and while reconfiguring the Pi and running the command sudo apt-get install git zlib1g libjpeg-dev libatlas-base-dev rustc libopenjp2-7 python-dev-is-python3 scons libssl-dev python3-venv python3-pip git libfreetype6-dev wkhtmltopdf libopenblas-dev I got this :

image

maybe the issue is linked to this ?

also I restarted from zero running the install and everything and im getting the same error code :

image
naeldavid commented 3 months ago

Could it be related to the version i'm using or Python 3.11 ?

naeldavid commented 3 months ago

I also have an idea that could, in my opinion make Inkycal world famous. If we could get in touch to talk about it, it would be great.

aceisace commented 3 months ago

I'll try to reproduce this myself on bookworm, though currently I believe that I am using bullseye. However, this will still have to wait at least a few days, as I currently only have access to my own Inkycal. At the moment, this is being used for testing PiSugar integration and stability according to #311 .

I cannot rule out the possibility that it is related to python3.11 , yet, this appears to be a known issue related to dependencies of Pillow and ought to be easy to fix: https://stackoverflow.com/questions/48012582/pillow-libopenjp2-so-7-cannot-open-shared-object-file-no-such-file-or-directo

I'm open to all new suggestions and improvement ideas and there is also a lot of work happening behind the scenes too. You can get in touch with me via Discord on the official Support server

naeldavid commented 3 months ago

While following instruction on the link you sent I got some new errors but I think I know the solution. Anyways, I do not have discord so I cant contact you from there. Basically my idea create a prayer time table and if audio output is connected in my case this and so when it is prayer time eg: Fajr (morning prayer) it would be outputing the Adhan (prayer call). This module could help muslim people far from a mosque be aware of the prayer time at any time by a cool project ! )

What do you think ?

naeldavid commented 3 months ago

Thank You for the email and I think I found the solution : In the Manual Installation documentation you're asking to download python libraries with sudo apt-get install. Install with pip and the person should be good.

image

I saved it as Ace Github if thats ok with you :)

aceisace commented 2 months ago

Closing this issue as the problem has been resolved