[SPARK-48107][PYTHON] Exclude tests from Python distribution#46354
Closed
nchammas wants to merge 1 commit into
Closed
[SPARK-48107][PYTHON] Exclude tests from Python distribution#46354nchammas wants to merge 1 commit into
nchammas wants to merge 1 commit into
Conversation
nchammas
commented
May 3, 2024
| # Reference: https://setuptools.pypa.io/en/latest/userguide/miscellaneous.html | ||
|
|
||
| graft pyspark | ||
| recursive-include pyspark *.pyi py.typed *.json |
Contributor
Author
There was a problem hiding this comment.
@HyukjinKwon - Instead of this, I prefer to exclude tests as follows:
$ diff python/MANIFEST-json.in python/MANIFEST-notests.in
19c19
< recursive-include pyspark *.pyi py.typed *.json
---
> graft pyspark
31a32
> global-exclude **/tests/**That way, if we add new files in the future that don't happen to match the glob expressions on this line they will still be picked up.
But I believe you prefer the approach taken here, so I've started with that.
HyukjinKwon
approved these changes
May 3, 2024
Member
|
Merged to master. |
Member
|
:-) |
Member
|
:) |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
What changes were proposed in this pull request?
Change the Python manifest so that tests are excluded from the packages that are built for distribution.
Why are the changes needed?
Tests were unintentionally included in the distributions as part of #44920. See this comment.
Does this PR introduce any user-facing change?
No, since #44920 hasn't been released to any users yet.
How was this patch tested?
I built Python packages and inspected
SOURCES.txtto confirm that tests were excluded:Was this patch authored or co-authored using generative AI tooling?
No.