Skip to content

allow install --download to download AND install #2508

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

Closed
nils-werner opened this issue Mar 9, 2015 · 5 comments
Closed

allow install --download to download AND install #2508

nils-werner opened this issue Mar 9, 2015 · 5 comments
Labels
auto-locked Outdated issues that have been locked by automation

Comments

@nils-werner
Copy link

Currently pip disables installation when using the --download option with install.

This is very unfortunate as downloading AND installing could be used to allow more comfortable Fast & Local Installs, especially when your company has an internal cheeseshop that is only accessible from the inside or via VPN.

I would have a pip.conf

[global]
find-links =
    https://internal-cheeseshop/

[install]
download = ~/.pip/tgzcache

and an offline.conf

[global]
find-links =
    ~/.pip/tgzcache
no-index = true

And then, for convenience set an alias

alias offlinepip="PIP_CONFIG_FILE=~/.pip/offline.conf pip"

So when on the train, I could force a local install using offlinepip and as long as I have installed a req'd package using pip once, the installation would work.

Currently, even with caching in place; the installation never works and is super annoying: pip tries to reach our internal cheeseshop repeatedly for each dependency I am trying to install, fails, tries again etc.

Alternatively, a force-cache flag would be nice (and less hackish), too. Anything to circumvent pip from trying to use the network.

@nils-werner
Copy link
Author

Yes, I have (updated the entry to reflect hat). Doing the offline install is not the problem. I cannot collect all pip installed packages in one place to reuse them later.

@piotr-dobrogost
Copy link

I cannot collect all pip installed packages in one place to reuse them later.

You don't have to as pip does it for you in the form of its cache.

Currently, even with caching in place; the installation never works and is super annoying: pip tries to reach our internal cheeseshop repeatedly for each dependency I am trying to install, fails, tries again etc.

This is the real reason it doesn't work as you would like; having packages in cache does not prevent pip from reaching out to PyPI. See #2090

@nils-werner
Copy link
Author

#2090 is unrelated, it revolves around PIP going to PyPI, no matter if find-links defined or not.

This issue revolves around PIP going to PyPI, no matter if package already exists in cache.

@piotr-dobrogost
Copy link

Right. Then #1572 is related although it goes much further.

@nils-werner
Copy link
Author

Closing this as download and wheel do most of what I want, I just wanted some additional convenience that's not really necessary.

@lock lock bot added the auto-locked Outdated issues that have been locked by automation label Jun 5, 2019
@lock lock bot locked as resolved and limited conversation to collaborators Jun 5, 2019
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
auto-locked Outdated issues that have been locked by automation
Projects
None yet
Development

No branches or pull requests

2 participants