Why are some versions of packages unavailable for certain systems?

I have two servers with Python 3.9 installed on both, one Centos 7.9, the other Rocky Linux 8.5.

I have minify-html 0.8.0 installed on Rocky Linux with no issue, but when trying to install on Centos 7.9 I’m getting this error:

ERROR: Could not find a version that satisfies the requirement minify-html==0.8.0 (from versions: none)
ERROR: No matching distribution found for minify-html==0.8.0
...
pip._internal.exceptions.DistributionNotFound: No matching distribution found for minify-html==0.8.0
Removed build tracker: '/tmp/pip-req-tracker-t1upjpgq'

These are my available compatible tags for Python 3.9 on Centos 7.9

Compatible tags: 369
cp39-cp39-manylinux_2_17_x86_64
cp39-cp39-manylinux2014_x86_64
cp39-cp39-manylinux_2_16_x86_64
cp39-cp39-manylinux_2_15_x86_64
cp39-cp39-manylinux_2_14_x86_64
cp39-cp39-manylinux_2_13_x86_64
cp39-cp39-manylinux_2_12_x86_64
cp39-cp39-manylinux2010_x86_64
cp39-cp39-manylinux_2_11_x86_64
cp39-cp39-manylinux_2_10_x86_64
cp39-cp39-manylinux_2_9_x86_64
cp39-cp39-manylinux_2_8_x86_64
cp39-cp39-manylinux_2_7_x86_64
cp39-cp39-manylinux_2_6_x86_64
cp39-cp39-manylinux_2_5_x86_64
cp39-cp39-manylinux1_x86_64
cp39-cp39-linux_x86_64

I had to install Python from source on Centos 7.9 where Rocky had everything taken care of with dnf installer.

Is this because the package manager didn’t compile a compatible package for Centos 7.9?

RHEL/CentOS 7 ships with glibc 2.17 (as the compatibility tags suggest), whereas as can be seen on PyPI, the minify_html wheels for CPython 3.9 on x64/ARM64 are built against ManyLinux (i.e. glibc) 2.24 (the AArch64/ARM64 wheels are built against 2.17), and no sdist is available to build from source (presumably since the package’s code is written in Rust with Python bindings). Aside from building from source using a GitHub checkout/tarball and installing from there, you could request that the package lower its glibc requirement on x64 to 2.17, since such is apparently supported on AAarch64.

1 Like

Thank for the fast and detailed answer, it all makes sense now. I’ve reached out to the developers to see what they recommend. This is just one more annoyance that is pushing me to update the OS on our servers sooner than later.