[update] Ability to set a maximum version for specific variants

This commit is contained in:
pukkandan 2022-06-29 06:43:24 +05:30
parent c2c8921b41
commit b1f94422cc
No known key found for this signature in database
GPG key ID: 7EEE9E1E817D0A39
4 changed files with 81 additions and 30 deletions

View file

@ -10,7 +10,6 @@ import json
import locale
import operator
import os
import platform
import random
import re
import shutil
@ -110,7 +109,6 @@ from .utils import (
number_of_digits,
orderedSet,
parse_filesize,
platform_name,
preferredencoding,
prepend_extension,
register_socks_protocols,
@ -126,6 +124,7 @@ from .utils import (
strftime_or_none,
subtitles_filename,
supports_terminal_sequences,
system_identifier,
timetuple_from_msec,
to_high_limit_path,
traverse_obj,
@ -3656,17 +3655,7 @@ class YoutubeDL:
with contextlib.suppress(Exception):
sys.exc_clear()
def python_implementation():
impl_name = platform.python_implementation()
if impl_name == 'PyPy' and hasattr(sys, 'pypy_version_info'):
return impl_name + ' version %d.%d.%d' % sys.pypy_version_info[:3]
return impl_name
write_debug('Python version %s (%s %s) - %s' % (
platform.python_version(),
python_implementation(),
platform.architecture()[0],
platform_name()))
write_debug(system_identifier())
exe_versions, ffmpeg_features = FFmpegPostProcessor.get_versions_and_features(self)
ffmpeg_features = {key for key, val in ffmpeg_features.items() if val}