Skip to content

Conversation

sbidoul
Copy link
Member

@sbidoul sbidoul commented Sep 28, 2025

closes #6334
closes #11457
closes #11859

This is the big one - it does not make much sense to split in smaller PRs.

  • --use-pep517 always on
  • --no-use-pep517 removed (error if used)
  • --global-option and --build-option removed (error if used)
  • legacy editable (setup.py develop) removed
  • legacy build (setup.py bdist_wheel) removed
  • legacy metadata preparation (setup.py egg_info) removed

There is still a lot to do in the test suite, but it looks like it will mostly be adding --no-build-isolation to many tests, in order to use the locally installed setuptools. I'm opening as draft nevertheless in case there are any suggestions.

I tried to split in small commits that should be relatively easy to review.

Documentation update will follow.

@sbidoul sbidoul force-pushed the pep517-only-sbi branch 4 times, most recently from 794a9eb to b9733f3 Compare September 28, 2025 15:00
@sbidoul sbidoul marked this pull request as ready for review September 28, 2025 16:11
We remove
- legacy metadata preparation
- legacy wheel build (bdist_wheel)
- --global-option and --build-option
- --no-use-pep517
- and therefore all setuptools shims

--use-pep517 stays as a no-op

This commits removes some tests that become irrelevant,
but just the minimum so mypy is happy.
This option is now always on, so need to test it.
This option is gone.
Some unit test need to run metadata preparation for setuptools based test projects.
Because pip now uses flit_core as build backend.
Most tests use setup.py-based test packages, and we
want to avoid network access for building them.
@sbidoul sbidoul added this to the 25.3 milestone Sep 28, 2025
@ichard26
Copy link
Member

In terms of availability, I should have some (although not a lot!) time to review starting in mid-late October. If you want to wait for reviews (since this is a major change), then you may want to take that into consideration. Otherwise, it will depend on whether Paul, Pradyun or Damian have any time for reviews.

Anyway, thank you a lot for working on this!

Since there is no 'setup.py develop' fallback anymore,
this check needs to be updated, and also needs to run
when not using build isolation.
@notatallshaw
Copy link
Member

I will try and add my review before 25.3, although this is really outside my wheelhouse (pun intended), so I'll only really be reviewing code quality and doing some smoke tests, I assume there aren't many design choices here, but if there are I won't be able to add much useful input.

@sbidoul
Copy link
Member Author

sbidoul commented Sep 29, 2025

Thanks @ichard26 and @notatallshaw ! I'll also try to make some time to review other 25.3 PRs in the coming 2 weeks.

Regarding this PR, there were not any design decisions left to do. So it's a big diff but it's straightforward removal of all non-pep517 code paths. The code base was already prepared for that thanks to the work we progressively did over the last (10?) years - kudos to everyone involved, by the way!

The vast majority of the changes to the test suite is adding --no-build-isolation in many places so tests don't have to look for setuptools. A few other tests had to be removed as they were testing removed features, or needed to be adjusted to cope with removed options (such as using --config-setting instead of --global-option).

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
3 participants