This repository was archived by the owner on Feb 7, 2024. It is now read-only.
-
-
Notifications
You must be signed in to change notification settings - Fork 123
This repository was archived by the owner on Feb 7, 2024. It is now read-only.
failed to make an editable install #331
Copy link
Copy link
Open
Labels
bugSomething isn't workingSomething isn't working
Description
🐛 Bug Report
failed to make an editable install
🔬 How To Reproduce
Steps to reproduce the behavior:
- system-wide it's
Anaconda 3.8
. there existspoetry
, but it's not used as shown below - create an project using all default settings (named
python-project
) - in the project folder, create a
setup.py
as follows:
from setuptools import find_packages, setup
setup(
name="python_project",
version='0.0.1',
author='author',
packages=find_packages(where='python_project'),
package_dir={'': 'python_project'}
)
- in system-wide
python
& in project folder, runpip install -e ./
- getting error:
ERROR: Command errored out with exit status 1:
command: 'C:\Users\xxx\anaconda3\python.exe' -c 'import sys, setuptools, tokenize; sys.argv[0] = '"'"'C:\\path-to\\python-project\\setup.py'"'"'; __file__='"'"'C:\\path-to\\python-pro
ject\\setup.py'"'"';f=getattr(tokenize, '"'"'open'"'"', open)(__file__);code=f.read().replace('"'"'\r\n'"'"', '"'"'\n'"'"');f.close();exec(compile(code, __file__, '"'"'exec'"'"'))' develop --no-deps
cwd: C:\path-to\python-project\
Complete output (3 lines):
Traceback (most recent call last):
File "<string>", line 1, in <module>
ModuleNotFoundError: No module named 'setuptools'
----------------------------------------
ERROR: Command errored out with exit status 1: 'C:\Users\xxx\anaconda3\python.exe' -c 'import sys, setuptools, tokenize; sys.argv[0] = '"'"'C:\\path-to\\python-project\\setup.py'"'"'; __file__='"'"
'C:\\path-to\\python-project\\setup.py'"'"';f=getattr(tokenize, '"'"'open'"'"', open)(__file__);code=f.read().replace('"'"'\r\n'"'"', '"'"'\n'"'"');f.close();exec(compile(code, __file__, '"'"'exec'"
'"'))' develop --no-deps Check the logs for full command output.
- delete
pyproject.toml
as well as related.pre-commit-config.yaml
and.github
; - run
pip install -e ./
again and it succeeds.
Code sample
NA
Environment
- OS: Win10 x64
- Python version, get it with: Anaconda x64 3.8.8
Screenshots
NA
📈 Expected behavior
to create an editable install by just adding a setup.py
file.
📎 Additional context
For my specific project, an editable install fits better as it involves pywin32
.
I found a "fix" as follows:
- comment out the
build-backend = "poetry.core.masonry.api"
line inpyproject.toml
; - make an editable install with
pip install -e . --no-use-pep517
Metadata
Metadata
Assignees
Labels
bugSomething isn't workingSomething isn't working