You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Or, did sampleproject intentionally change the name to avoid sdist's inclusion of the test files? That'd be a weird way to do so. It would be better to rename it back to test and explicitly put an exclude line in MANIFEST.in if you want the exclusion.
The PR there (pypa/setuptools#2494) got closed for some... technical reasons, it is complicated to add tests/test* until other problems are solved...
So I guess here's what we can do now:
In sampleproject, add a line recursive-include tests test*.py to MANIFEST.in (include all test*.py in tests folder and its subfolders, this does not include __init__.py and .pyc)
Activity
dmtucker commentedon Dec 20, 2020
testsis far more common in my experience. I'm kinda surprised to heartestis included in sdists by default... not sure why that would be desirable.chrahunt commentedon Dec 20, 2020
The only reason I know of for naming the folder
testsis to avoid conflicting with theteststandard library module.tomchen commentedon Dec 20, 2020
Yeah right. It should be a pypa/setuptools issue, I opened a PR there.
Meanwhile, there is still something sampleproject could do: maybe add a include line to
MANIFEST.into ask setuptools for the inclusion oftests?tomchen commentedon Dec 20, 2020
The PR there (pypa/setuptools#2494) got closed for some... technical reasons, it is complicated to add
tests/test*until other problems are solved...So I guess here's what we can do now:
recursive-include tests test*.pytoMANIFEST.in(include all test*.py in tests folder and its subfolders, this does not include __init__.py and .pyc)testthere contradictstestsin the same user guide's "Packaging Python Projects" page and in pypa/sampleproject, and suggest what users should do, what the folder name and what sdist inclusion strategy might be good.di commentedon Oct 30, 2021
The directory in this project should probably just change to
testso that it aligns with the defaultsetuptoolsbehavior.