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

Pr ignore video file under size #366

Merged
merged 2 commits into from
Dec 12, 2023

Conversation

yajrendrag
Copy link
Contributor

Added fix to allow video duration to be obtained from ffprobe format section if streams section is void of duration value.

@BlakeGardner
Copy link

This PR fixes the issue for me. Some video files were causing an exception to raise because ffprobe could not find the duration. Below I will provide the ffprobe command before and after this change and how it surfaces the duration on some video files.

Before change

ffprobe -v error -show_entries stream=duration,width,height -print_format json test_video.mkv
{
    "programs": [

    ],
    "streams": [
        {
            "width": 720,
            "height": 480,
            "side_data_list": [
                {

                }
            ]
        },
        {

        }
    ]
}

After change

ffprobe -v error -show_entries stream=duration,width,height:format=duration -print_format json test_video.mkv
{
    "programs": [

    ],
    "streams": [
        {
            "width": 720,
            "height": 480,
            "side_data_list": [
                {

                }
            ]
        },
        {

        }
    ],
    "format": {
        "duration": "633.472000"
    }
}

@Josh5 Josh5 merged commit aa00a28 into Unmanic:official Dec 12, 2023
2 checks passed
@yajrendrag yajrendrag deleted the pr-ignore_video_file_under_size branch January 17, 2024 00:58
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.

3 participants