The test (pypy3.11, ubuntu-latest, stdlib) matrix job has been failing on main for some time — 53 failures plus 3 errors in a recent run, spread across test_build_meta.py, test_install_scripts.py, test_editable_install.py, test_bdist_wheel.py and test_config_discovery.py. Every one of them is the same warning-turned-error:
E DeprecationWarning: check_home argument is deprecated and ignored.
/opt/hostedtoolcache/PyPy/3.11.15/x64/lib/pypy3.11/sysconfig.py:230: DeprecationWarning
Cause
It is not setuptools' call. PyPy 3.11.15 ships a bundled distutils that is inconsistent with its own sysconfig:
lib/pypy3.11/distutils/command/install.py:339: in finalize_options
if sysconfig.is_python_build(True):
lib/pypy3.11/sysconfig.py:230: in is_python_build
warnings.warn("check_home argument is deprecated and ignored.",
DeprecationWarning, stacklevel=2)
is_python_build deprecated its check_home argument, but the distutils shipped alongside it still passes it positionally. setuptools/command/install.py:74 calls super().finalize_options(), which lands in that code, and pytest.ini sets filterwarnings = error, so the warning fails the test.
Nothing in setuptools passes check_home — grep -rn check_home setuptools/ is empty. The job only fails in the distutils: stdlib configuration, i.e. SETUPTOOLS_USE_DISTUTILS=stdlib, where PyPy's copy is used instead of the vendored one. The other stdlib job in the matrix, 3.10 / ubuntu-latest, is unaffected.
Options
- Report upstream to PyPy — this looks like a genuine bug in their bundled distutils, and the real fix belongs there.
- Add a targeted
ignore::DeprecationWarning filter in pytest.ini scoped to this message, so the job tests setuptools rather than PyPy's stdlib.
- Drop the
pypy3.11 + stdlib combination. distutils is gone from CPython 3.12+, so the stdlib variant is legacy coverage; it may no longer be worth a matrix slot on PyPy specifically.
I have no strong opinion between 2 and 3, but the job is currently red on every PR, which makes it hard to tell a real regression from the standing failure — that is the part worth fixing either way.
Noticed while working on #5325, whose CI it obscured.
The
test (pypy3.11, ubuntu-latest, stdlib)matrix job has been failing onmainfor some time — 53 failures plus 3 errors in a recent run, spread acrosstest_build_meta.py,test_install_scripts.py,test_editable_install.py,test_bdist_wheel.pyandtest_config_discovery.py. Every one of them is the same warning-turned-error:Cause
It is not setuptools' call. PyPy 3.11.15 ships a bundled distutils that is inconsistent with its own
sysconfig:is_python_builddeprecated itscheck_homeargument, but the distutils shipped alongside it still passes it positionally.setuptools/command/install.py:74callssuper().finalize_options(), which lands in that code, andpytest.inisetsfilterwarnings = error, so the warning fails the test.Nothing in setuptools passes
check_home—grep -rn check_home setuptools/is empty. The job only fails in thedistutils: stdlibconfiguration, i.e.SETUPTOOLS_USE_DISTUTILS=stdlib, where PyPy's copy is used instead of the vendored one. The otherstdlibjob in the matrix,3.10 / ubuntu-latest, is unaffected.Options
ignore::DeprecationWarningfilter inpytest.iniscoped to this message, so the job tests setuptools rather than PyPy's stdlib.pypy3.11 + stdlibcombination.distutilsis gone from CPython 3.12+, so thestdlibvariant is legacy coverage; it may no longer be worth a matrix slot on PyPy specifically.I have no strong opinion between 2 and 3, but the job is currently red on every PR, which makes it hard to tell a real regression from the standing failure — that is the part worth fixing either way.
Noticed while working on #5325, whose CI it obscured.