-
Notifications
You must be signed in to change notification settings - Fork 14
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
This is not a bug!!! i am unable to execute pipgrip. #60
Comments
Which error do you get exactly? Is it a Python traceback (some ImportError or so)? Can you try Hope that helps, please report back what fixed it :) |
Hello
Thank you very much for replying so fast!
In fact the error I am getting is when I fire up my shell and then
issuing *pipgrip --help * the output is *pipgrip : command not found.*
I am not on my computer right now. Will try tonight and give feedback.
Thanks
Le jeu. 22 juil. 2021 à 12:36, ddelange ***@***.***> a écrit :
… Which error do you get exactly? Is it a Python traceback (some ImportError
or so)? Can you try which python, which pip and compare the two paths?
Maybe your pip install pipgrip was using the system python version (2.7)
with an old pip version messing up the console_scripts registration
specified in the setup.py. Can you confirm import pipgrip works from
py3.8? Alternatively, can you try python -m pipgrip --help? Maybe
something went wrong with installing, and might be worth a shot
re-installing with the pip of your python dist, e.g. python3.8 -m pip
install --force-reinstall pipgrip
Hope that helps, please report back what fixed it :)
—
You are receiving this because you authored the thread.
Reply to this email directly, view it on GitHub
<#60 (comment)>,
or unsubscribe
<https://github.com/notifications/unsubscribe-auth/APIGQLYQP7GYERYVIQMLW23TY77C3ANCNFSM5AZM7SIA>
.
|
I am back !! Import pipgrip works perfectly with Python 3.8 Input: python3.8 -m pip install --force-reinstall pipgrip Now I type again pipgrip --help and I keep receiving the command not found message. |
Sounds like a PATH issue indeed: python3.8 (is in PATH) works, so in that case I will close as it's not an issue with pipgrip, however do feel free to follow up if necessary :) |
After installing pyenv and also direnv I try to reload pipgrip. Input: python3.8 -m pipgrip --help Output: /usr/bin/python3.8: No module named pipgrip.main; 'pipgrip' is a package and cannot be directly executed. Any idea on what it means? |
My bad, the suggestion So after you set up your shell to use python distributions that were installed using pyenv (the bash hook + installing python via pyenv, see link below), you can use See also https://github.com/ddelange/new-mac-setup#pyenv-and-pyenv-virtualenv for a quick start with pyenv |
Thanks for your feedback. So what I could certainly do without giving up is to somehow repackage every project and then install each in separate virtual env. Looks like my only option is to write a script where pipgrip should look inside my downloaded packages, build the dep tree for each project and print the output in a requirements.txt file. I am wondering if it will work like that. |
pipgrip just calls pip in a subprocess, so if the packages are available to pip's cache mechanism, there should not be additional downloads. If you dont have the pip cache anymore, but only the distributions unpacked in the
Continuing on that thought: if you're really low on internet, you could go one step further and host your own pypi registry (e.g. devpi) on localhost, and let it cache anything it doesnt have yet (would mirror the official pypi). You can then You can also install pipgrip via brew.sh, but it requires some setup of the brew package manager, and it will download/install latest python in the background upon Good luck! |
Thanks, I'll check it out.
Le lun. 26 juil. 2021 à 10:38, ddelange ***@***.***> a écrit :
… pipgrip just calls pip in a subprocess, so if the packages are available
to pip's cache mechanism, there should not be additional downloads. If you
dont have the pip cache anymore, but only the distributions unpacked in the
site-packages folder of python (venv), you should avoid pipgrip. I can
suggest extracting from the local dist metadata for instance like:
pipdeptree --reverse --packages <your-installed-package> | grep '=='
Continuing on that thought: if you're really low on internet, you could go
one step further and host your own pypi registry (e.g. devpi) on localhost,
and let it cache anything it doesnt have yet (would mirror the official
pypi). You can then pip install --index-url <localhost-url> ..., and so
your local devpi will only talk to the internet if you're
installing/requesting a package (version) that is not on your local
registry yet. pipgrip supports --index-url as well, but of course the
setup a bit overkill if this is a one time thing.
You can also install pipgrip via brew.sh, but it requires some setup of
the brew package manager, and it will download/install latest python in the
background upon brew install pipgrip, so I guess it's not a data saving
option 😅
Good luck!
—
You are receiving this because you authored the thread.
Reply to this email directly, view it on GitHub
<#60 (comment)>,
or unsubscribe
<https://github.com/notifications/unsubscribe-auth/APIGQL7BB2Q2DG722U4AXB3TZUUHTANCNFSM5AZM7SIA>
.
|
I am on Ubuntu 20.04 LTS
Python 3.8.10
pip 20.0.2
Issuing pipgrip --help throws me command not found.
I have edited the .bashrc file by adding
export PATH=/usr/local:$PATH
And The path to site-packages file where pip modules are downloaded in my system.
But still getting the same output.
Please how can I run pipgrip need help.
The text was updated successfully, but these errors were encountered: