mirror of
https://git.vectorsigma.ru/public/tubearchivist.git
synced 2026-08-08 21:39:32 +00:00
handle NA in ffprobe duration extractor
This commit is contained in:
@@ -169,7 +169,11 @@ class DurationConverter:
|
|||||||
capture_output=True,
|
capture_output=True,
|
||||||
check=True,
|
check=True,
|
||||||
)
|
)
|
||||||
duration_sec = int(float(duration.stdout.decode().strip()))
|
duration_raw = duration.stdout.decode().strip()
|
||||||
|
if duration_raw == "N/A":
|
||||||
|
return 0
|
||||||
|
|
||||||
|
duration_sec = int(float(duration_raw))
|
||||||
return duration_sec
|
return duration_sec
|
||||||
|
|
||||||
@staticmethod
|
@staticmethod
|
||||||
|
|||||||
Reference in New Issue
Block a user