Greetings and cryptographic salutations. I'm currently packaging merkletools for Gentoo and briefly faceplanted into a minor installation-time issue.
wat is bad?
Specifically, the top-level setup.py script erroneously installs the tests package. This is bad – not simply under Gentoo but under any Python environment. Why? Coupla reasons:
Ambiguity. If every Python project attempted to install an ambiguously named tests package, no Python project would be installable. Since these packages would conflict with one another at installation time, no sane packager (e.g., pip, easy_install) would permit these projects to be concurrently installed.
Irrelevance. By convention, test packages are typically not installed; they're simply bundled with source tarballs for external usage by interested third parties. If you really, really do want the tests package to be installed, it should probably be moved under the top-level merkletools package (e.g., as a new merkletools.tests subpackage).
how to make good?
We've trivially patched this on our end. Here's how you can, too. In setup.py:
# Replace this bad line...
packages=find_packages(),
# ...with this good line.
packages=find_packages(exclude=["tests"]),
That's it. Easy peasy. Thanks for all the fruitful Merkle trees, all! :deciduous_tree:
Greetings and cryptographic salutations. I'm currently packaging
merkletools
for Gentoo and briefly faceplanted into a minor installation-time issue.wat is bad?
Specifically, the top-level
setup.py
script erroneously installs thetests
package. This is bad – not simply under Gentoo but under any Python environment. Why? Coupla reasons:tests
package, no Python project would be installable. Since these packages would conflict with one another at installation time, no sane packager (e.g.,pip
,easy_install
) would permit these projects to be concurrently installed.tests
package to be installed, it should probably be moved under the top-levelmerkletools
package (e.g., as a newmerkletools.tests
subpackage).how to make good?
We've trivially patched this on our end. Here's how you can, too. In
setup.py
:That's it. Easy peasy. Thanks for all the fruitful Merkle trees, all! :deciduous_tree: