So I've tested that my script does attempt to run and I'm recording the error message of
Traceback (most recent call last):
File "/home/pi/steamFriendStatus_v0.3.py", line 6, in <module>
import telepot
ImportError: No module named 'telepot'
This module works fine running the script from terminal/IDLE/Thonny and I'm declaring to use Python 3 / full Python 3 directory in the rc.local command
My rc.local file is below:
exec > /tmp/rc-local.log 2>&1
# Print the IP address
_IP=$(hostname -I) || true
if [ "$_IP" ]; then
printf "My IP address is %s\n" "$_IP"
fi
/usr/bin/python3 /home/pi/steamFriendStatus_v0.3.py
exit 0
export
from a regular shell and compare this with anexport
command in yourrc.local
(in the log file) you'll be able to see any difference, and you can fix this withexport VAR=...
in your rc.local file.