ODFPY no possible installation

I’m experiencing an issue while trying to install odfpy library with pip or pip+git.
There’s no way to install it because of a dependency with setuptools.
I also tried in a virtual env. No way !
Setuptools is installed (69.0.3).

ERROR: Could not find a version that satisfies the requirement setuptools>=40.8.0 (from versions: none)
ERROR: No matching distribution found for setuptools>=40.8.0

Looking for an idea !

  • Python 3.12.1
  • Pip 23.2.1
  • Windows 11

The error very clearly tells you that it is not - in the place where it would need to be. But this isn’t enough to expect people to solve the problem on their own.

The specific problem with Setuptools occurs because Pip tried to make a new environment in order to build a wheel for the new library - the library isn’t pre-built for your system, so Pip has to download the source and build it locally.

Pip is supposed to install Setuptools (also from PyPI) into that new environment automatically, if necessary; but depending on other configuration options, it might not be able to. You can work around this by turning off the build isolation that Pip uses by default (creating the new environment for the wheel-building).

Prior to 3.12, virtual environments would also contain setuptools (and wheel) by default anyway. So when Pip created its new environment (by using venv), setuptools would be present without Pip even needing to look up the dependency. But this does not happen in 3.12: