pdm install
does not install all files included in sdist with pdm build
#2972
Labels
🐛 bug
Something isn't working
Steps to reproduce
pdm-backend
src/
directory and add a Python script to the top-level, e.g.foobar.py
pdm install
python -m foobar
in another directory (such that Python doesn't findfoobar.py
in the current directory) and note how it is not able to find thefoobar
modulepdm build
andtar -tf dist/yourpackage-0.1.0.tar.gz
to find that it containsfoobar.py
Expected behavior
I would expect that
foobar.py
gets linked into the the virtual environment because it is also included in the source distribution.That being said, I'm not 100% sure about the exact process that PDM uses to find which Python source files make up the distribution and I have struggled to find this in the docs. It might be worthwhile to document the behaviour and double down to ensure this behaviour is consistent across
pdm install
andpdm build
.Environment Information
Additional notes
The behaviour I'm looking for is actually to have a PDM project that doesn't really require a distribution, but I want to be able to use
pdm install
to install Python files from the top-level of the project (i.e. next to thepyproject.toml
) in subdirectories. The idea here is to create a simple layout for a repository that contains one-off scripts that can do a bit of importing from each other.The text was updated successfully, but these errors were encountered: