Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

cannot disable PEP-517 #6230

Closed
gaborbernat opened this issue Feb 1, 2019 · 5 comments
Closed

cannot disable PEP-517 #6230

gaborbernat opened this issue Feb 1, 2019 · 5 comments
Labels
auto-locked Outdated issues that have been locked by automation

Comments

@gaborbernat
Copy link

2019-02-01T17:30:51.5986637Z python3.7 -m pip wheel --no-use-pep517 --no-deps -w /home/vsts/work/1/a 'git+https://github.com/pypa/setuptools.git'
2019-02-01T17:30:51.6018420Z [command]/bin/bash --noprofile --norc /home/vsts/work/_temp/05fff709-f0d4-4189-a7a4-3202635fb045.sh
2019-02-01T17:30:51.9739954Z Collecting git+https://github.com/pypa/setuptools.git
2019-02-01T17:30:51.9741503Z   Cloning https://github.com/pypa/setuptools.git to /tmp/pip-req-build-u29rjlh8
2019-02-01T17:30:55.7151472Z Disabling PEP 517 processing is invalid: project specifies a build backend of setuptools.build_meta in pyprojec

I must be missing here something but why?

@pfmoore
Copy link
Member

pfmoore commented Feb 1, 2019

If you explicitly specify build-backend, we can't presume that the setup.py fallback can't build your project (after all, you could have specified a backend of flit).

Yes, we could have checked for whether you had a setup.py, and you specifiied setuptools.build_meta in pyproject.toml, and if you did, allowed --no-use-pep517, but we don't. The intention was that --no-use-pep517 would only be needed for projects without a build-backend which for some reason needed to opt out of the new logic (which would get triggered even if pyproject.toml only contained tool settings). But if you've specified build-backend, you've already chosen to opt in.

What's your use case? Specifically, why don't you just remove build-backend from your pyproject.toml if you want to use the legacy code path?

@gaborbernat
Copy link
Author

gaborbernat commented Feb 1, 2019

setuptools excluded the pyproject.toml to solve https://discuss.python.org/t/pep-517-backend-bootstrapping/789/45, but seems they need to remove the backend key for a durable solution instead then. My expectation was if we disable it would fall back to pip 18.1 behaviour aka install via PEP-518.

@pfmoore
Copy link
Member

pfmoore commented Feb 1, 2019

Yeah, that's a particular special case (as you know), and unfortunately, --no-use-pep517 won't help you there (and any change we'd make to allow it to wouldn't happen any faster than the "real" solution we're working towards in that Discourse conversation).

@gaborbernat
Copy link
Author

I'll close it for now as the current recommended solution in such cases is to remove the build-backend keyword altogether.

@lock
Copy link

lock bot commented May 29, 2019

This thread has been automatically locked since there has not been any recent activity after it was closed. Please open a new issue for related bugs.

@lock lock bot added the auto-locked Outdated issues that have been locked by automation label May 29, 2019
@lock lock bot locked as resolved and limited conversation to collaborators May 29, 2019
ls-amaury-yacksmith referenced this issue in pyca/cryptography May 31, 2019
This puts a new minimum on the PEP 518 requirement for `setuptools`
because older versions of setuptools' PEP 517 backend will fail to
include `setup.py` in an sdist.
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
auto-locked Outdated issues that have been locked by automation
Projects
None yet
Development

No branches or pull requests

2 participants