Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add stderr text to exception thrown when ffmpeg invocation fails #42

Merged
merged 4 commits into from
Nov 17, 2023

Conversation

stephenjolly
Copy link
Collaborator

Local testing on a machine with a faulty ffmpeg installation resulted in an ffmpeg invocation failure, which revealed that the current code suppresses ffmpeg output, preventing debugging. This PR captures stderr when invoking ffmpeg and adds it to the exception thrown when ffmpeg invocation fails.

@stephenjolly
Copy link
Collaborator Author

Not sure how we would/should add tests for this - mock the ffmpeg binary maybe?

@chrisn
Copy link
Member

chrisn commented Nov 17, 2023

I added a test to cause ffmpeg to generate a file not found error. I also reduced the log level from "panic" to "error" based on https://ffmpeg.org/ffmpeg.html#toc-Generic-options, which says "panic" isn't currently used.

@stephenjolly stephenjolly merged commit 93bcd59 into master Nov 17, 2023
23 checks passed
@stephenjolly stephenjolly deleted the report-ffmpeg-errors branch November 17, 2023 11:11
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants