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

Fix #5 by adding 'xerror' and 'stderr' psuedo err_detect options #21

Open
wants to merge 12 commits into
base: master
Choose a base branch
from

Conversation

crass
Copy link

@crass crass commented Mar 31, 2024

This is dependent on PR #19. Really this PR is just the last 2 commits. It also fixes issue #5.

The xerror option adds the -xerror option to ffmpeg which causes it to exit early on any corrupt frames. The stderr option causes the ffmpeg_check call to fail if there is any error level log messages.

This was implemented as psuedo options to err_detect instead of a new option to have all ffmpeg error handling options go through one option. Also, even though ffmpeg's -err_detect option has no effect for me, even on the video files with corruption that I've tried, I've left this capability as it might be working for others.

aaronkollasch and others added 12 commits August 20, 2022 03:07
If ffmpeg was run, when check_mi.py completes echo for the terminal has
been disabled. Instead do not have ffmpeg stdin come from the terminal.
Presumably the --strict_level option should apply to single files as well.
When the identify command fails the stderr output can be useful in
diagnosing why it failed, which could be due to a configuratin issue
and not a real failure.
On a timeout error the following output has been observed:
Traceback (most recent call last):
  File "./check_mi.py", line 475, in <module>
    main()
  File "./check_mi.py", line 460, in main
    print("Waiting other results for too much time, perhaps you have to raise the timeout", e.message)
AttributeError: 'Empty' object has no attribute 'message'

Do not assume that exception objects have a message attribute.
The 'xerror' option adds the '-xerror' option to ffmpeg which causes it
to exit early on any corrupt frames. The 'stderr' option causes the
ffmpeg_check to fail if there is any error level log messages.
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