Disable PEP 517 error with editable install
See original GitHub issueIssue description
pipenv install
with an editable source leads to error “Disabling PEP 517 processing is invalid: project specifies a build backend of setuptools.build_meta:legacy in pyproject.toml”.
However, the project doesn’t use any `pyproject.toml, so I have no idea where this is coming from.
The relevant part of the pipfile is
[packages.e1839a8]
path = "."
editable = true
https://github.com/tobiasdiez/sage/blob/fe43eb81da698ab06536c6adf0694b4c508fd65f/src/Pipfile#L29-L31
Expected result
Successful installation.
Actual result
Installing 'e1839a8'
$ ['/Users/runner/.local/share/virtualenvs/src-wmLs4vOe/bin/pip', 'install', '--verbose', '--upgrade', '--no-use-pep517', '--exists-action=i', '-r', '/var/folders/24/8k48jl6d249_n_qfxwsl6xvm0000gn/T/pipenv-15afg11l-requirements/pipenv-rhh7sbpy-requirement.txt', '-i', 'https://pypi.org/simple']
Using source directory: '/Users/runner/.local/share/virtualenvs/src-wmLs4vOe/src'
Using pip 20.2.1 from /Users/runner/.local/share/virtualenvs/src-wmLs4vOe/lib/python3.8/site-packages/pip (python 3.8)
Non-user install by explicit request
Created temporary directory: /private/var/folders/24/8k48jl6d249_n_qfxwsl6xvm0000gn/T/pip-ephem-wheel-cache-6w3f6p4l
Created temporary directory: /private/var/folders/24/8k48jl6d249_n_qfxwsl6xvm0000gn/T/pip-req-tracker-wg3nc7wc
Initialized build tracking at /private/var/folders/24/8k48jl6d249_n_qfxwsl6xvm0000gn/T/pip-req-tracker-wg3nc7wc
Created build tracker: /private/var/folders/24/8k48jl6d249_n_qfxwsl6xvm0000gn/T/pip-req-tracker-wg3nc7wc
Entered build tracker: /private/var/folders/24/8k48jl6d249_n_qfxwsl6xvm0000gn/T/pip-req-tracker-wg3nc7wc
Created temporary directory: /private/var/folders/24/8k48jl6d249_n_qfxwsl6xvm0000gn/T/pip-install-e82f8g60
Obtaining file:///Users/runner/work/sage/sage/src (from -r /var/folders/24/8k48jl6d249_n_qfxwsl6xvm0000gn/T/pipenv-15afg11l-requirements/pipenv-rhh7sbpy-requirement.txt (line 1))
Added file:///Users/runner/work/sage/sage/src (from -r /var/folders/24/8k48jl6d249_n_qfxwsl6xvm0000gn/T/pipenv-15afg11l-requirements/pipenv-rhh7sbpy-requirement.txt (line 1)) to build tracker '/private/var/folders/24/8k48jl6d249_n_qfxwsl6xvm0000gn/T/pip-req-tracker-wg3nc7wc'
Exception information:
Traceback (most recent call last):
File "/Users/runner/.local/share/virtualenvs/src-wmLs4vOe/lib/python3.8/site-packages/pip/_internal/cli/base_command.py", line 216, in _main
status = self.run(options, args)
File "/Users/runner/.local/share/virtualenvs/src-wmLs4vOe/lib/python3.8/site-packages/pip/_internal/cli/req_command.py", line 182, in wrapper
return func(self, options, args)
File "/Users/runner/.local/share/virtualenvs/src-wmLs4vOe/lib/python3.8/site-packages/pip/_internal/commands/install.py", line 324, in run
requirement_set = resolver.resolve(
File "/Users/runner/.local/share/virtualenvs/src-wmLs4vOe/lib/python3.8/site-packages/pip/_internal/resolution/legacy/resolver.py", line 183, in resolve
discovered_reqs.extend(self._resolve_one(requirement_set, req))
File "/Users/runner/.local/share/virtualenvs/src-wmLs4vOe/lib/python3.8/site-packages/pip/_internal/resolution/legacy/resolver.py", line 388, in _resolve_one
abstract_dist = self._get_abstract_dist_for(req_to_install)
File "/Users/runner/.local/share/virtualenvs/src-wmLs4vOe/lib/python3.8/site-packages/pip/_internal/resolution/legacy/resolver.py", line 326, in _get_abstract_dist_for
return self.preparer.prepare_editable_requirement(req)
File "/Users/runner/.local/share/virtualenvs/src-wmLs4vOe/lib/python3.8/site-packages/pip/_internal/operations/prepare.py", line 525, in prepare_editable_requirement
abstract_dist = _get_prepared_distribution(
File "/Users/runner/.local/share/virtualenvs/src-wmLs4vOe/lib/python3.8/site-packages/pip/_internal/operations/prepare.py", line 91, in _get_prepared_distribution
abstract_dist.prepare_distribution_metadata(finder, build_isolation)
File "/Users/runner/.local/share/virtualenvs/src-wmLs4vOe/lib/python3.8/site-packages/pip/_internal/distributions/sdist.py", line 33, in prepare_distribution_metadata
self.req.load_pyproject_toml()
File "/Users/runner/.local/share/virtualenvs/src-wmLs4vOe/lib/python3.8/site-packages/pip/_internal/req/req_install.py", line 503, in load_pyproject_toml
pyproject_toml_data = load_pyproject_toml(
File "/Users/runner/.local/share/virtualenvs/src-wmLs4vOe/lib/python3.8/site-packages/pip/_internal/pyproject.py", line 95, in load_pyproject_toml
raise InstallationError(
pip._internal.exceptions.InstallationError: Disabling PEP 517 processing is invalid: project specifies a build backend of setuptools.build_meta:__legacy__ in pyproject.toml
See https://github.com/tobiasdiez/sage/runs/1204858164?check_suite_focus=true for the full output. (Note that github still marks the step as successful, so the return value is not correctly reflecting that there was an error.)
Steps to replicate
Run pipenv install
with the following pipfile: https://github.com/tobiasdiez/sage/blob/fe43eb81da698ab06536c6adf0694b4c508fd65f/src/Pipfile
The following github action workflow shows this issue: https://github.com/tobiasdiez/sage/blob/public/build/inplace/.github/workflows/ci-pipenv.yml
Note that the same pipfile works on pipenv 11.9.0 (on Ubuntu).
Issue Analytics
- State:
- Created 3 years ago
- Reactions:1
- Comments:5 (1 by maintainers)
May I ask to please reopen this issue as the behavior of hiding the error message and using different cmd arguments for the second compilation is at least very confusing. Moreover, if I remember correctly
no-use-pep517
will always fail for inplace installs.My current workaround is to run
pipenv run pip install PACKAGE --verbose --upgrade --exists-action=i --no-build-isolation
whenever there is an error with some PACKAGE. This yields a quite helpful error message.