Join GitHub today
GitHub is home to over 40 million developers working together to host and review code, manage projects, and build software together.Sign up
1.4.0rc3 Python 3 Timelapse "expected a bytes-like object, str found" #3409
It appears there's an encoding issue in the release candidate for python 3. I didn't see issues in the related package about this but the
What were you doing?
webcam: ffmpeg: /home/pi/mjpg-streamer/mjpg-streamer-experimental/mjpg_streamer snapshot: https://10.0.0.128/webcam/?action=snapshot snapshotSslValidation: false stream: https://10.0.0.128/webcam/?action=stream timelapse: fps: 25 options: minDelay: 5.0 retractionZHop: 0.0 postRoll: 30 type: zchange watermark: false
What did you expect to happen?
Timelapse to function as expected.
What happened instead?
Timelapse feature failed with the error listed above.
Did the same happen when running OctoPrint in safe mode?
Yes. I don't have any extensions on in the fresh install.
Version of OctoPrint
Operating System running OctoPrint
pi@raspberrypi:~ $ cat /etc/os-release PRETTY_NAME="Raspbian GNU/Linux 10 (buster)" NAME="Raspbian GNU/Linux" VERSION_ID="10" VERSION="10 (buster)" VERSION_CODENAME=buster ID=raspbian ID_LIKE=debian HOME_URL="http://www.raspbian.org/" SUPPORT_URL="http://www.raspbian.org/RaspbianForums" BUG_REPORT_URL="http://www.raspbian.org/RaspbianBugs"
Printer model & used firmware incl. version
Probably not relevant, but Prusa Mk2 MMU firmware V3.2.3
Browser and version of browser, operating system running browser
Probably not relevant, but Chrome on Windows and on Ubuntu 18.04
Link to octoprint.log
Link to contents of terminal tab or serial.log
Screenshot(s)/video(s) showing the problem:
I have read the FAQ.
So the issue here is the
The question now is why the universal newline flag was even set on the line in question, and I'll try to dig that up. From the looks of it, things work just fine without it as well, so maybe it's really as easy as removing one single keyword argument (which is deprecated under Py3 anyhow).
Sadly the rabbit hole goes deeper, see 4bf5984 and https://stackoverflow.com/questions/7632589/getting-realtime-output-from-ffmpeg-to-be-used-in-progress-bar-pyqt4-stdout/35422274#35422274
So this is going to need some digging.