Diaoul / subliminal

Subtitles, faster than your thoughts
http://subliminal.readthedocs.org
MIT License
2.4k stars 311 forks source link

FYI: Subliminal 2.2.0 can not be used in Fedora and derivatives. #1136

Closed darkshram closed 3 months ago

darkshram commented 3 months ago

For compatibility reasons, Fedora uses virtualenv 20.21.1, which requires platformdirs <4,>=2.4, so Fedora uses platformdirs 3.11.0. Therefore Subliminal 2.2.0 can not be installed/used in Fedora (and many other Linux distributions) because the upgraded requirement to platformdirs >= 4.2. Unfortunately Fedora and derivatives use (and will keep using) platformdirs 3.11.0 to keep compatibility with legacy versions of Python.

Details at https://src.fedoraproject.org/rpms/python-virtualenv. See the comments in python-virtualenv.spec file.

ptrcnull commented 3 months ago

as we only use PlatformDirs.user_config_path and PlatformDirs.user_cache_dir, i think we can safely drop the requirement to at least platformdirs >= 3

darkshram commented 3 months ago

I can confirm, Subliminal 2.2.0 works perfectly with platformdirs 3.11.0. Made rpm package replacing platformdirs>=4.2 with platformdirs>=3.11.

sed -i \
    -e "s|platformdirs>=4.2|platformdirs>=3.11|g" \
    PKG-INFO \
    pyproject.toml \
    subliminal.egg-info/PKG-INFO \
    subliminal.egg-info/requires.txt

Tested downloading Spanish subtitles for a random movie from my colection:

subliminal download -l es xxxxxxx.19xx.1080p.BluRay.x264.AAC.mp4
Not using any configuration file.
Collecting videos  [####################################]  100%
1 video collected / 0 video ignored / 0 error
Downloading subtitles  [####################################]  100%
Downloaded 1 subtitle