I have a script that utilizes picamera on a raspberry pi 5. It's been working great for months, the all of sudden it started throwing errors. Here is the start of the script
# Import libraries
import os
import time
import sys
import requests
from picamera2 import PiCamera
There are a bunch of comment lines before that, documenting the purpose of the script, how it works, etc., but those are the first real lines in the script. The script is now dying on that last import line with this error
siggib@raspberrypi3D:~/prusacam $ python prusacam.py
Traceback (most recent call last):
File "/home/siggib/prusacam/prusacam.py", line 17, in <module>
from picamera2 import PiCamera
File "/usr/lib/python3/dist-packages/picamera2/__init__.py", line 3, in <module>
import libcamera
ValueError: source code string cannot contain null bytes
siggib@raspberrypi3D:~/prusacam $ python -V
Python 3.11.2
siggib@raspberrypi3D:~/prusacam $
The only thing that has changed lately is a few apt update to keep the system up to date, other than that nothing has changed. There was a power outage the other day but the system appears to be unaffected.
Anyone have any leads on what might have broken?