setuptools: [BUG] easy-install.pth when updated during installation is overwritten without the recently added changes
setuptools version
setuptools==60.9.3
Python version
CPython 3.8
OS
Ubuntu 20.04
Additional environment information
Used in combination/on top of a CMake project using sub-projects via cmake FetchContent module : https://cmake.org/cmake/help/git-stage/module/FetchContent.html#fetchcontent
Description
Basically : my setup.py is calling cmake to build a cmake project with pybind11 extensions.
the main project includes others cmake (sub-)projects using FetchContent. I control everything in the picture.
I want to be able to install in editable mode the main project and I want all the sub-projects to be also installed along the way as dependencies/automatically (given they all contains pybind11 extensions), also in editable mode/the same way the main/top one. I so tried to put a pip install -e
or (python setup.py develop) of the sub-project(s) as a cmake dedicated custom target(s) on the main project. it’s well correctly called … BUT : actually it’s a pip install or setup.py develop which is called during/inside another one…
and the net effect is all is done correctly BUT the easy-install.pth file gets overwritten by the main pip install (after the inner one finish)… basically the directory added to it by the inner installation is lost after the outer one writes its resulting one…
does that ring a bell to someone ?
Expected behavior
I would have expected that the outer/main pip install/setup.py develop read again the content of the easy-install.pth file (so to get a fresh content) before writing it… and merging what’s need to as necessary/correctly.
How to Reproduce
Call pip install / setup.py develop inside another one.
Output
can produce on demand.
About this issue
- Original URL
- State: closed
- Created 2 years ago
- Comments: 25 (9 by maintainers)
Releasing as v67.8.0.