It can be reproduced with a mostly empty project:

$ ls ~/.local/lib/python3.10  # I have no locally installed packages:
ls: impossible d'accéder à '/home/mdk/.local/lib/python3.10': Aucun fichier ou 
dossier de ce type

$ which python  # My python is the system one:
/usr/bin/python

$ python --version  # Yes I do use python-is-python3:
Python 3.10.4

$ ls  # A very simple "project":
pyproject.toml  youpi.py

$ cat pyproject.toml
[build-system]
requires = ["setuptools", "wheel"]
build-backend = "setuptools.build_meta"

[project]
name = "test"
description = "Just a test"
requires-python = ">= 3.7"

[tool.setuptools]
py-modules = ["youpi"]
include-package-data = false

$ cat youpi.py
"coucou"

$ pip install .
[...]
      RecursionError: maximum recursion depth exceeded while calling a Python 
object

      During handling of the above exception, another exception occurred:

      Traceback (most recent call last):
[...]
        File "/usr/lib/python3.10/_distutils_system_mod.py", line 125, in 
_inject_headers
          scheme['headers'] = 
orig_install._load_schemes()['posix_prefix']['headers']
        File "/usr/lib/python3.10/_distutils_system_mod.py", line 137, in 
wrapped_load_schemes
          _inject_headers(name, scheme)
        File "/usr/lib/python3.10/_distutils_system_mod.py", line 125, in 
_inject_headers
          scheme['headers'] = 
orig_install._load_schemes()['posix_prefix']['headers']
        File "/usr/lib/python3.10/_distutils_system_mod.py", line 137, in 
wrapped_load_schemes
          _inject_headers(name, scheme)
        File "/usr/lib/python3.10/_distutils_system_mod.py", line 125, in 
_inject_headers
          scheme['headers'] = 
orig_install._load_schemes()['posix_prefix']['headers']
        File "/usr/lib/python3.10/_distutils_system_mod.py", line 137, in 
wrapped_load_schemes
          _inject_headers(name, scheme)
        File "/usr/lib/python3.10/_distutils_system_mod.py", line 125, in 
_inject_headers
          scheme['headers'] = 
orig_install._load_schemes()['posix_prefix']['headers']
        File "/usr/lib/python3.10/_distutils_system_mod.py", line 135, in 
wrapped_load_schemes
          schemes = _load_schemes()
        File 
"/usr/lib/python3/dist-packages/setuptools/_distutils/command/install.py", line 
103, in _load_schemes
          sysconfig_schemes = _load_sysconfig_schemes() or {}
        File 
"/usr/lib/python3/dist-packages/setuptools/_distutils/command/install.py", line 
91, in _load_sysconfig_schemes
          with contextlib.suppress(AttributeError):
        File "/usr/lib/python3.10/contextlib.py", line 436, in __exit__
          return exctype is not None and issubclass(exctype, self._exceptions)
      RecursionError: maximum recursion depth exceeded in __subclasscheck__
      [end of output]

  note: This error originates from a subprocess, and is likely not a problem 
with pip.
  ERROR: Failed building wheel for UNKNOWN
Failed to build UNKNOWN
ERROR: Could not build wheels for UNKNOWN, which is required to install 
pyproject.toml-based projects

-- 
Julien Palard
https://mdk.fr

Reply via email to