Skip to content
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

license, docs and tests missing from pypi sdist #52

Closed
dvzrv opened this issue Jan 17, 2020 · 5 comments
Closed

license, docs and tests missing from pypi sdist #52

dvzrv opened this issue Jan 17, 2020 · 5 comments

Comments

@dvzrv
Copy link

dvzrv commented Jan 17, 2020

Hi! I'm packaging python-django-classy-tags for Arch Linux.
When packaging we usually run tests and add (certain) licenses to the package. Unfortunately the sdist tarballs on pypi.org don't contain either.

Given, that also fixes for python3.8 and django 3.0 have made their way into this repository since version 0.9.0, I guess it would be a great time for a new release. Thank you!

@maddrum
Copy link

maddrum commented Jan 20, 2020

Waiting for that release to migrate to django3.

@FinalAngel
Copy link
Member

we have just released classy tags 1.0.0 with Django 3 compatibility :)

@dvzrv
Copy link
Author

dvzrv commented Jan 22, 2020

@FinalAngel Thanks for the release!
However, the sdist still doesn't contain the tests, so this ticket is still valid. If you want I can do a pull request for MANIFEST.in to fix this.

@FinalAngel
Copy link
Member

@dvzrv sorry I overread this. The tests are currently not part of the package by intention (design decision by our team). It could be as easy as to remove: https://github.com/divio/django-classy-tags/blob/master/setup.py#L50

Though considering that we practice this on all our packages I'm hesitant on changing it only for this package...

@dvzrv
Copy link
Author

dvzrv commented Jan 23, 2020

@FinalAngel maybe there's a misunderstanding about the tests directory and which tarball I'm referring to.

To my understanding MANIFEST.in is used to (more specifically) define what goes into a source tarball (when using python setup.py sdist).
The setup() function on the other hand defines what will be installed to a target system, when packages have been built (python setup.py build) from a source tarball (with find_packages(), include_package_data or package_data giving more finely grained access over what is included/excluded) and then installed (python setup.py install).

While it is absolutely reasonable to exclude the tests from e.g. a wheel distributable (python setup.py bdist_wheel), which happens automatically because of your above stated line in setup(), it is not good to distribute the sdist without tests (because noone can test the sources after building from them when using the tarball from pypi.org).

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants