Egg include setup py#1554
Merged
pganssle merged 4 commits intopypa:masterfrom Nov 4, 2018
Merged
Conversation
Member
|
@shashanksingh28 Can you add a changelog here? |
pganssle
reviewed
Oct 28, 2018
pganssle
reviewed
Oct 28, 2018
pganssle
reviewed
Oct 30, 2018
Member
|
@gaborbernat Do you mind taking a look at this? Are there tests that cover your use case? |
gaborbernat
approved these changes
Oct 31, 2018
Contributor
gaborbernat
left a comment
There was a problem hiding this comment.
It does solve my problem, thanks a lot !
gaborbernat
approved these changes
Nov 1, 2018
1e8cb17 to
421f49d
Compare
pganssle
pushed a commit
to shashanksingh28/setuptools
that referenced
this pull request
Nov 2, 2018
This tests that `setup.py` is included by default in the distribution with the egg_info command and when an sdist is built with build_meta.build_sdist
Fixes GH issue pypa#1506
421f49d to
932c72d
Compare
pganssle
pushed a commit
to shashanksingh28/setuptools
that referenced
this pull request
Nov 3, 2018
pganssle
approved these changes
Nov 3, 2018
932c72d to
bff67db
Compare
Member
|
@shashanksingh28 Thanks for your PR, and thanks for following up with all the changes! |
Contributor
Author
|
Thanks @pganssle and @gaborbernat for your help :) This was my first open source PR, will try to be more involved |
Closed
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.
Summary of changes
While creating sdists, we want the source dist .tar.gz to contain
setup.pybecause this is what pip would use to install the source distribution.python setup.py sdistensured setup.py was included because distutils by default adds the script_name that was executing the build process. However, for someone callingbuild_sdist('.')programatically, the script name is the script callind build_sdist function and notsetup.py.The problem is that sdist command uses the
egg-infocommand to extract file list to be tar-ziped, which did not include setup.py as default (unless it was called via 'setup.py' as the script name). This fix adds an explicit check in theegg-infocommand for setup.py.An alternative solution is solving this one level deeper at distutils add_defaults method which
egg-infocommand uses.Closes #1506
Will update changelog once we agree on the approach
Pull Request Checklist