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

Included tests make the package large #117

Open
1 task done
ryanvolz opened this issue Apr 8, 2022 · 6 comments
Open
1 task done

Included tests make the package large #117

ryanvolz opened this issue Apr 8, 2022 · 6 comments
Labels

Comments

@ryanvolz
Copy link

ryanvolz commented Apr 8, 2022

Solution to issue cannot be found in the documentation.

  • I checked the documentation.

Issue

Recent builds of the pillow package, which include the tests and test images, weigh in at ~45 MB. Without the tests included, the package occupies less than 1 MB of space. The tests don't get installed into the environment, so the main effect is a bigger download and more space occupied in the package cache. Since nobody is likely to want to run the tests themselves from the packaged tarball, I think that shrinking the package back down to its previous size would be a big benefit (particularly since pillow is a dependency of matplotlib-base, which I assume many people will install).

Conda-build has a --no-copy-test-source-files which would allow the tests to still run in the feedstock and prevent them from ending up in the package, but I don't know if there is a way to use that. Another possible solution could be to create a separate output (e.g. pillow-tests) and run the tests through that. That way they would still be available in a package, but the majority of users would not have to use the extra space.

Installed packages

N/A

Environment info

N/A
@ryanvolz ryanvolz added the bug label Apr 8, 2022
@h-vetinari
Copy link
Member

Unless there's a simple way to pass arguments to conda-build from cf infrastructure (CC @conda-forge/core), I think the pillow-tests approach would be the most reasonable.

Thanks for the report!

@hmaarrfk
Copy link
Contributor

hmaarrfk commented Apr 9, 2022

Yeah, i've been trying to think of a good name of this extra package.

For the conda-package, I gave up on finding a solution:
https://github.com/conda-forge/conda-feedstock/blob/main/recipe/meta.yaml#L5

The tests were never run prior to adding that flag.

@hmaarrfk
Copy link
Contributor

hmaarrfk commented Apr 9, 2022

my issue wit hthe tests package, is that it may overlap with a real package name from upstream.

I think maybe pillow__tests__ ? or something like that. Fewer chances of collisions.

@h-vetinari
Copy link
Member

my issue with the tests package, is that it may overlap with a real package name from upstream.

TBH, I don't think that's an issue. And if upstream ever were to publish something like that, we could build some deprecation for our output. The scipy-feedstock would similarly take scipy-tests.

@hmaarrfk
Copy link
Contributor

Ok. The tests name sounds fine

@hmaarrfk
Copy link
Contributor

hmaarrfk commented Jul 5, 2022

I guess we are at the point where a PR would be accepted.

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

No branches or pull requests

3 participants