-
-
Notifications
You must be signed in to change notification settings - Fork 1.2k
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
Editable install using setup.py breaks without legacy feature [BUG] #3499
Comments
@vogre Does your package make use of |
@synchronizing -- no, not using |
Hi @vogre, it seems that somehow, your build is indeed using v64 (the editable install was not present in v63.2.0).
Could you share some form of reproducer (for example, containing a |
In #3502, I think I manage to reproduce this particular error. |
@vogre, please checkout v64.0.1. If it does not work for you, let me know and I will re-open this issue. |
@abravalheri |
Hi @bipalauthomize can you create a new issue and share a small/simplified reproducer there? Please also have a look on this docs section. |
Hi @bipalauthomize, regarding this issue, have you figured out something regarding the sole presence of In the build configuration, we put: [build-system]
requires = ["setuptools>=58,<63"]
build-backend = "setuptools.build_meta" This ensures we get the legacy editable installation without needing the environment variable tweek. how to replicate?Given the project's structure: .:
total 46
drwxr-xr-x 1 UserName 4096 0 Jan 19 08:10 .
drwxr-xr-x 1 UserName 4096 0 Dec 28 11:31 ..
-rw-r--r-- 1 UserName 4096 89 Jan 19 08:10 pyproject.toml
-rw-r--r-- 1 UserName 4096 227 Jan 18 15:36 requirements.txt
-rw-r--r-- 1 UserName 4096 259 Jan 19 07:52 setup.py
drwxr-xr-x 1 UserName 4096 0 Jan 19 07:55 src
drwxr-xr-x 1 UserName 4096 0 Jan 19 07:48 venv
src:
total 24
drwxr-xr-x 1 UserName 4096 0 Jan 19 07:55 .
drwxr-xr-x 1 UserName 4096 0 Jan 19 08:10 ..
drwxr-xr-x 1 UserName 4096 0 Jan 18 15:31 super_project
src/super_project:
total 16
drwxr-xr-x 1 UserName 4096 0 Jan 18 15:31 .
drwxr-xr-x 1 UserName 4096 0 Jan 19 07:55 ..
-rw-r--r-- 1 UserName 4096 772 Jan 18 15:31 __init__.py
-rw-r--r-- 1 UserName 4096 1302 Jan 18 15:25 __main__.py The isolated environment is based on pip==22.1.2
setuptools==62.6.0
wheel==0.37.1
Let's spawn a
With solely a from setuptools import setup, find_packages
setup(
name='super-project',
version='0.1',
author='Super Company',
description='Super Project',
package_dir={'': 'src'},
packages=find_packages(where='src'),
python_requires='>=3.8',
) We clearly see that pip installs build dependencies and collects
Let's uninstall it:
Now, we add a very basic build configuration: [build-system]
requires = ["setuptools"]
build-backend = "setuptools.build_meta" And we re-do the installation:
Again, let's uninstall it:
And now restrict setuptools' version: [build-system]
requires = ["setuptools>=58,<63"]
build-backend = "setuptools.build_meta" Here our legacy-editable install happens with
When it gets uninstalled, files removed are a bit different:
|
setuptools version
63.2.0
Python version
Python 3.10
OS
Ubuntu 22.04 LTS
Additional environment information
No response
Description
Running
pip install -e .
in a repository with apyproject.toml
present, even ifpyproject.toml
is only used for tool configurationResults in the error
exporting SETUPTOOLS_ENABLE_FEATURES="legacy-editable" does behave as expected, as does removing the
pyproject.toml
file.Expected behavior
Expected install to ignore
pyproject.toml
without any build configuration.How to Reproduce
No specific steps to reproduce, since a similar package installs successfully with the same
setuptools
version.The command failing is
pip install -e .
Output
The text was updated successfully, but these errors were encountered: