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

Add distribution constraint options to pip download #3092

Closed

Conversation

patricklaw
Copy link

@patricklaw patricklaw commented Sep 10, 2015

This is a continuation of #2965. Right now this branch also includes the changes in #3085, pending 3085 being merged. This PR is to trigger Travis and to prepare for a quick followup once 3085 is merged.

Review on Reviewable

@patricklaw
Copy link
Author

Working on updating this and adding some more thorough tests now

@jorgebastida
Copy link

Hello @patricklaw I'm really looking forward to --platform to arrive to pip. There is anything missing in this PR I could help with in order to move it forward? Thanks!

@patricklaw
Copy link
Author

Hi @jorgebastida, this ended up falling to the backburner as I got caught up in other things. I'll try to refresh my memory on it today and report back. Last I remember there were still some issues with plumbing the pep425 tags down. Nothing seemed particularly monumental, just needs a little tweaking and some more tests.

@patricklaw patricklaw force-pushed the pl.pip-install-additional-options branch from dc42857 to b84836a Compare April 24, 2016 20:44
@patricklaw
Copy link
Author

Could someone clarify what the issue is with this shard? https://travis-ci.org/pypa/pip/jobs/125431745

I wasn't particularly comfortable checking in binaries, but it seemed to be the standard practice for the test fixture. If it's preferred, I can instead programmatically generate these wheels in a temp directory using a fixture.

@patricklaw
Copy link
Author

Okay, based on the failing pypy shard it seems like I should just generalize this patch to also deal with interpreter implementation and ABI. Working on that now.

@patricklaw
Copy link
Author

Added those options and figured out the packaging issue (silly mistake; accidentally checked in some debugging output). If this CI run is green then this PR is ready for review.

@patricklaw patricklaw changed the title Pl.pip install additional options Add distribution constraint options to pip download Apr 25, 2016
@patricklaw
Copy link
Author

It looks like a couple of shards are failing due to unrelated timeouts. Hopefully this next run is green. This is finished from my end and ready to be reviewed/merged. Please let me know if there's anything else that needs to be done.

)

cmd_opts.add_option(
'--manylinux1',
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Do we really need this special case flag ?
pip download numpy --platform=manylinux1_x86_64 could maybe do the job ?

Copy link
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Agreed, with the caveat that when the user is specifying a platform, manylinux1 should definitely be considered false, since it could otherwise leak into the tags in addition to what the user specified.

@patricklaw
Copy link
Author

@xavfernandez Done!

@xavfernandez
Copy link
Member

xavfernandez commented Apr 27, 2016

This needs more documentation I think with a big warning on its limitation:
if we are using pip download --python-version=27 foo from a Python 3.5 and foo comes through a .tar.gz the setup.py egg_info will be executed as Python 3.5 and the downloaded dependencies might be the ones for 3.5 and not those for 2.7.

@patricklaw
Copy link
Author

@xavfernandez Good catch. I changed it to enforce --only-binary=:all: (and disallow any --no-binary=foo exceptions), added a test for the enforcement, and noted this requirement in the docs.

@patricklaw
Copy link
Author

Travis shard failure looks spurious.

@patricklaw
Copy link
Author

Anything in particular blocking this being merged?

@patricklaw patricklaw force-pushed the pl.pip-install-additional-options branch from cf43c49 to 35034d1 Compare May 11, 2016 15:19
@patricklaw
Copy link
Author

Rebased and squashed to fix merge conflicts.

Mathew Jennings and others added 3 commits May 12, 2016 15:32
With the --platform option, a user can download wheels with
a different platform than that of the local machine running the command.

With the --python-version option, a user can
download wheels that are explicitly compatible with a specific
Python interpreter version.

This functionality is meant for utilities that gather dependencies
and prepare distributions for other platforms.
Add thorough tests, usage documentation, and handle some merge issues.
@patricklaw patricklaw force-pushed the pl.pip-install-additional-options branch from b76b0cd to bdb5741 Compare May 12, 2016 19:33
@patricklaw
Copy link
Author

Force pushed to resolve another merge conflict

@xavfernandez xavfernandez added this to the 8.2 milestone May 13, 2016
@dstufft dstufft closed this May 18, 2016
@dstufft
Copy link
Member

dstufft commented May 18, 2016

Accidentally closed this, reopening. Sorry!

@dstufft dstufft reopened this May 18, 2016
@BrownTruck
Copy link
Contributor

Hello!

As part of an effort to ease the contribution process and adopt a more standard workflow pip has switched to doing development on the master branch. However, this Pull Request was made against the develop branch so it will need to be resubmitted against master. Unfortunately, this pull request does not cleanly merge against the current master branch.

If you do nothing, this Pull Request will be automatically closed by @BrownTruck since it cannot be merged.

If this pull request is still valid, please rebase it against master (or merge master into it) and resubmit it against the master branch, closing and referencing the original Pull Request.

If you choose to rebase/merge and resubmit this Pull Request, here is an example message that you can copy and paste:

This is a continuation of #2965.  Right now this branch also includes the changes in #3085, pending 3085 being merged.  This PR is to trigger Travis and to prepare for a quick followup once 3085 is merged.

---

*This was migrated from pypa/pip#3092 to reparent it to the ``master`` branch. Please see original pull request for any previous discussion.*

@BrownTruck BrownTruck added asked to reparent auto-bitrotten PRs that died because they weren't updated and removed asked to reparent labels May 19, 2016
@BrownTruck
Copy link
Contributor

This Pull Request was closed because it cannot be automatically reparented to the master branch and it appears to have bit rotted.

Please feel free to re-open it or re-submit it if it is still valid and you have rebased it onto master or merged master into it.

@BrownTruck BrownTruck closed this May 26, 2016
@lock lock bot added the auto-locked Outdated issues that have been locked by automation label Jun 3, 2019
@lock lock bot locked as resolved and limited conversation to collaborators Jun 3, 2019
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
auto-bitrotten PRs that died because they weren't updated auto-locked Outdated issues that have been locked by automation
Projects
None yet
Development

Successfully merging this pull request may close these issues.

5 participants