Open dodalovic opened 2 years ago
When I execute the command /usr/bin/python3 /home/dodalovic/me/projects/opensource/AirStatus/main.py /tmp/airstatus.out
, it works just fine, stays running indefinitely
Pop!_OS 21.10
uname -a
Linux pop-os 5.15.8-76051508-generic #202112141040~1639505278~21.10~0ede46a SMP Tue Dec 14 22:38:29 U x86_64 x86_64 x86_64 GNU/Linux
Hello @dodalovic,
Does something show up with journalctl
?
@delphiki I'm getting this via journalctl
:
Jan 26 15:35:56 pop-os systemd[1]: Started AirPods Battery Monitor.
Jan 26 15:35:56 pop-os python3[473254]: Traceback (most recent call last):
Jan 26 15:35:56 pop-os python3[473254]: File "/home/dodalovic/me/tools/AirStatus/main.py", line 1, in <module>
Jan 26 15:35:56 pop-os python3[473254]: from bleak import discover
Jan 26 15:35:56 pop-os python3[473254]: ModuleNotFoundError: No module named 'bleak'
@dodalovic You probably forgot to install the requirements:
pip install -r requirements.txt
@delphiki After doing that, and restarting service, i still have:
Jan 26 16:38:11 pop-os systemd[1]: airstatus.service: Scheduled restart job, restart counter is at 32.
Jan 26 16:38:11 pop-os systemd[1]: Stopped AirPods Battery Monitor.
Jan 26 16:38:11 pop-os systemd[1]: Started AirPods Battery Monitor.
Jan 26 16:38:11 pop-os python3[498384]: Traceback (most recent call last):
Jan 26 16:38:11 pop-os python3[498384]: File "/home/dodalovic/me/tools/AirStatus/main.py", line 1, in <module>
Jan 26 16:38:11 pop-os python3[498384]: from bleak import discover
Jan 26 16:38:11 pop-os python3[498384]: ModuleNotFoundError: No module named 'bleak'
Jan 26 16:38:11 pop-os systemd[1]: airstatus.service: Main process exited, code=exited, status=1/FAILURE
Jan 26 16:38:11 pop-os systemd[1]: airstatus.service: Failed with result 'exit-code'.
Jan 26 16:38:15 pop-os systemd[1]: airstatus.service: Scheduled restart job, restart counter is at 33.
Jan 26 16:38:15 pop-os systemd[1]: Stopped AirPods Battery Monitor.
Jan 26 16:38:15 pop-os systemd[1]: Started AirPods Battery Monitor.
Also, the numbers read are way different from the ones i see on my IPad. Not sure why though.
Thx @Movisivi, but it's not related to that. Also, I prefer not to use sudo
for installing dependencies. :)
I get the following error:
/usr/bin/python3: can't open file '/tmp/airstatus.out': [Errno 2] No such file or directory
What might cause the problem?
Maybe this could help: