pypa / pyproject-hooks

A low-level library for calling build-backends in `pyproject.toml`-based project
https://pyproject-hooks.readthedocs.io/
MIT License
119 stars 49 forks source link

test_setup fails with setuptools >= 70.1.0 #203

Open dirkmueller opened 6 days ago

dirkmueller commented 6 days ago

pytest -k "test_setup"

gives


    def test_setup_py():
        hooks = get_hooks("setup-py")
        with modified_env({"PYTHONPATH": BUILDSYS_PKGS}):
            res = hooks.get_requires_for_build_wheel({})
        # Some versions of setuptools list setuptools itself here
        res = [x for x in res if x != "setuptools"]
>       assert res == ["wheel"]
E       AssertionError: assert [] == ['wheel']
E         
E         Right contains one more item: 'wheel'
E         Use -v to get more diff

tests/test_call_hooks.py:213: AssertionError

it works when downgrading to setuptools 70.0.0

pfmoore commented 6 days ago

bdist_wheel was merged into setuptools recently, so it no longer adds wheel as a dependency in get_requires_for_build_wheel.