ffsubsync icon indicating copy to clipboard operation
ffsubsync copied to clipboard

fix: don't report sync as successful if best score is in negatives

Open ajitid opened this issue 1 year ago • 0 comments

This is easy to reproduce. Try using an input subtitle file that is not related to the video. Score is reported as negative while sync_was_successful is still reported as true.

skip_sync is untouched. So if skip_sync is true (which means best score would be 0), sync_was_successful will still report as true.

PS: sorry for this being such a crude PR. I don't usually work in python and I couldn't come up with a test to add. I would happily take up the feedback to improve the PR if you give any.

@morpheus65535 please weigh in if you feel otherwise.

ajitid avatar Feb 17 '24 16:02 ajitid