I have virtualenv-13.1.2 set up with python 3.4 (global python is python-2.7) in ubuntu 14.04. When I try to install GoogleScraper using coammandpip install GoogleScraper it gives an error
setuptools must be installed to install from a source distribution
If I do pip install setuptools
Requirement already satisfied (use --upgrade to upgrade): setuptools in ./env/lib/python3.4/site-packages
If I do pip install setuptools --upgrade
Requirement already up-to-date: setuptools in ./env/lib/python3.4/site-packages
How can I successfully install GoogleScraper?
I was missing python3-dev tools. I did sudo apt-get install python3-dev and it worked like a charm.
After upgrading the python3.4 package in Ubuntu 14.04 I get the same error.
A quick solution is to delete and re-create the virtualenv.
Related
How can I fix this issue? This makes no sense, i guess i have two different python path so python gets confused how can i fix this issue as well?
C:\Users\user>pip install pip
Requirement already satisfied: pip in c:\users\user\appdata\local\programs\python\python38-32\lib\site-packages (19.3.1)
WARNING: You are using pip version 19.3.1; however, version 20.0.2 is available.
You should consider upgrading via the 'python -m pip install --upgrade pip' command.
C:\Users\user>python -m pip install --upgrade pip
Requirement already up-to-date: pip in c:\users\user\appdata\local\programs\python\python37-32\lib\site-packages (20.0.2)
You have 2 different versions of Python (hence 2 different versions of pip) installed.
pip in c:\users\user\appdata\local\programs\python\python38-32
and
pip in c:\users\user\appdata\local\programs\python\python37-32
In the first example you did pip install pip but in the second python -m pip install --upgrade pip (The help text gave you a bad advice in this case).
If you want to upgrade the Python 3.8 pip, do pip install --upgrade pip or with the full path c:\users\kayra\appdata\local\programs\python\python38-32\python.exe -m pip install --upgrade pip.
I want to install PyInstaller package through pip, So I typed "pip install pyinstaller", but it occur errors
and I was trying to upgrade the alt graph to latest version.. but it occur same errors
how can I install the PyInstaller or how can I upgrade the package altgraph ?
Therefore, even I can't delete altgraph using
rm -rf /System/Library/Frameworks/Python.framework/.../altgraph
What I did in terminal
pip install pyinstall - not working
pip install --upgrade altgraph - not working
pip uninstall altgraph - not working
I found a solution from
http://marcelog.github.io/articles/mac_osx_python_pip_install_operation_not_permitted.html
install package under a user
pip install <package> --user
As the title states I am trying to install torch on linux using pip.
I run the command pip install torch==0.3.1
And I get the following output:
Collecting torch==0.3.1
Could not find a version that satisfies the requirement torch==0.3.1 (from versions: 0.1.2, 0.1.2.post1)
No matching distribution found for torch==0.3.1
Any ideas what the issue might be?
Try update pip itself, using
pip install --upgrade pip
then,
pip install torch==0.3.1
Try to do like this:
sudo apt-get update
then,
pip install torch==0.3.1
Somehow pip --upgrade doesn't upgrade any packages.
I'm on OSX El Capitan (10.11.3) and installed python using brew install python
Python: /usr/local/bin/python# -> ../Cellar/python/2.7.11/bin/python
Pip: /usr/local/bin/pip# -> ../Cellar/python/2.7.11/bin/pip
After successful install I run pip install --upgrade pip.
Full output:
$ pip install --upgrade pip
Collecting pip
Using cached pip-8.1.0-py2.py3-none-any.whl
Installing collected packages: pip
Successfully installed pip-8.0.2
You are using pip version 8.0.2, however version 8.1.0 is available.
You should consider upgrading via the 'pip install --upgrade pip' command.
Why doesn't pip install the new version?
Update
I think it has something to do with my ~/.pydistutils.cfg file which fixes the DistutilsOptionError: must supply either home or prefix/exec-prefix -- not both error when running pip. I followed these instructions
Related SO question
$ sudo pip install -U pip
Collecting pip
Downloading pip-9.0.3-py2.py3-none-any.whl (1.4MB)
100% |████████████████████████████████| 1.4MB 335kB/s
Installing collected packages: pip
Found existing installation: pip 9.0.1
Uninstalling pip-9.0.1:
Successfully uninstalled pip-9.0.1
Successfully installed pip-9.0.3
Getting annoyed by things not working I created a new OSX profile. In the new profile everything was working fine so after investigating further I found a file ~/Library/Application\ Support/pip/pip.conf in my main profile containing:
[global]
target=/usr/local/lib/python2.7/site-packages
I don't know how it got there but removing it resolved the issue.
This also resolved the need for the ~/.pydistutils.cfg file.
I can't uninstall setuptools. How come?
$ sudo pip uninstall setuptools
Can't uninstall 'setuptools'. No files were found to uninstall.
$ sudo pip install setuptools
Requirement already satisfied (use --upgrade to upgrade): setuptools in /usr/local/lib/python2.7/dist-packages
Cleaning up...
How can I uninstall setuptools?
Considering that current Python versions are shipped with setuptools, pretty sure you shouldn't remove it.
And since pip uninstall setuptools doesn't work (thankfully), you could try just deleting the C:\Python27\Lib\site-packages\setuptools, or equivalent, folder. (On *nix systems: /usr/lib/python2.7/dist-packages.)
Disclaimer: this is a very bad idea, pip may not work at all afterwards.