Hi im newbie un tweepy i need install this component in my RedHat but i 'cant
Here the message:
ec2-user#ip-172-30-0-62 opitrends]$ sudo pip install tweepy
Traceback (most recent call last):
File "/usr/bin/pip", line 5, in <module>
from pkg_resources import load_entry_point
File "/usr/lib/python2.7/dist-packages/pkg_resources/__init__.py", line 3020, in <module>
working_set = WorkingSet._build_master()
File "/usr/lib/python2.7/dist-packages/pkg_resources/__init__.py", line 616, in _build_master
return cls._build_from_requirements(__requires__)
File "/usr/lib/python2.7/dist-packages/pkg_resources/__init__.py", line 629, in _build_from_requirements
dists = ws.resolve(reqs, Environment())
File "/usr/lib/python2.7/dist-packages/pkg_resources/__init__.py", line 807, in resolve
raise DistributionNotFound(req)
pkg_resources.DistributionNotFound: pip==6.1.1
[ec2-user#ip-172-30-0-62 opitrends]$
Someone help me??
Thanks
Bruno
I can't quite tell what's going on, but that's an older version of pip and that might be the problem. Try upgrading pip:
sudo pip install --upgrade pip
and then retry.
Related
Using MacOS Sierra 10.12.6
Installing Django project dependencies from requirement.txt file
sudo pip install --user -r requirement.txt
I have looked over internet for the similar issues but none of them helped.
I even have tried uninstalling pyOpenSSL using command:
pip uninstall pyOpenSSL
even this command is giving an error:
Traceback (most recent call last):
File "/Users/RitZz/Desktop/work/bin/pip", line 11, in <module>
load_entry_point('pip==19.1', 'console_scripts', 'pip')()
File "/Users/RitZz/Desktop/work/lib/python2.7/site-packages/pkg_resources/__init__.py", line 489, in load_entry_point
return get_distribution(dist).load_entry_point(group, name)
File "/Users/RitZz/Desktop/work/lib/python2.7/site-packages/pkg_resources/__init__.py", line 2843, in load_entry_point
return ep.load()
File "/Users/RitZz/Desktop/work/lib/python2.7/site-packages/pkg_resources/__init__.py", line 2434, in load
return self.resolve()
File "/Users/RitZz/Desktop/work/lib/python2.7/site-packages/pkg_resources/__init__.py", line 2440, in resolve
module = __import__(self.module_name, fromlist=['__name__'], level=0)
File "/Users/RitZz/Desktop/work/lib/python2.7/site-packages/pip/_internal/__init__.py", line 40, in <module>
from pip._internal.cli.autocompletion import autocomplete
File "/Users/RitZz/Desktop/work/lib/python2.7/site-packages/pip/_internal/cli/autocompletion.py", line 8, in <module>
from pip._internal.cli.main_parser import create_main_parser
File "/Users/RitZz/Desktop/work/lib/python2.7/site-packages/pip/_internal/cli/main_parser.py", line 12, in <module>
from pip._internal.commands import (
File "/Users/RitZz/Desktop/work/lib/python2.7/site-packages/pip/_internal/commands/__init__.py", line 6, in <module>
from pip._internal.commands.completion import CompletionCommand
File "/Users/RitZz/Desktop/work/lib/python2.7/site-packages/pip/_internal/commands/completion.py", line 6, in <module>
from pip._internal.cli.base_command import Command
File "/Users/RitZz/Desktop/work/lib/python2.7/site-packages/pip/_internal/cli/base_command.py", line 20, in <module>
from pip._internal.download import PipSession
File "/Users/RitZz/Desktop/work/lib/python2.7/site-packages/pip/_internal/download.py", line 15, in <module>
from pip._vendor import requests, six, urllib3
File "/Users/RitZz/Desktop/work/lib/python2.7/site-packages/pip/_vendor/requests/__init__.py", line 97, in <module>
from pip._vendor.urllib3.contrib import pyopenssl
File "/Users/RitZz/Desktop/work/lib/python2.7/site-packages/pip/_vendor/urllib3/contrib/pyopenssl.py", line 46, in <module>
import OpenSSL.SSL
File "/Users/RitZz/Desktop/work/lib/python2.7/site-packages/OpenSSL/__init__.py", line 8, in <module>
from OpenSSL import rand, crypto, SSL
File "/Users/RitZz/Desktop/work/lib/python2.7/site-packages/OpenSSL/SSL.py", line 124, in <module>
SSL_ST_INIT = _lib.SSL_ST_INIT
AttributeError: 'module' object has no attribute 'SSL_ST_INIT'
At few place it is mentioned to use:
sudo easy_install -U pyopenssl/pyOpenSSL
still getting same error.
even after deleting manually
> pyopenssl from python/2.7/site-packages/
and then reinstalling using command:
sudo pip install pyopenssl
it is not working, giving same error, (have also tried commands using --user flag)
I tried to install eb cli throw pip or msi and i always get the same wierd message after i check if eb was installed successfully:
PS C:\Users\liron> eb --version
Traceback (most recent call last):
File "C:\Users\liron\AppData\Roaming\Python\Python36\site-packages\pkg_resources__init__.py", line 570, in _build_master
ws.require(requires)
File "C:\Users\liron\AppData\Roaming\Python\Python36\site-packages\pkg_resources__init__.py", line 888, in require
needed = self.resolve(parse_requirements(requirements))
File "C:\Users\liron\AppData\Roaming\Python\Python36\site-packages\pkg_resources__init__.py", line 779, in resolve
raise VersionConflict(dist, req).with_context(dependent_req)
pkg_resources.ContextualVersionConflict: (colorama 0.3.9 (c:\users\liron\appdata\roaming\python\python36\site-packages), Requirement.parse('colorama==0.3.7'), {'awsebcli'})
During handling of the above exception, another exception occurred:
Traceback (most recent call last):
File "C:\Users\liron\AppData\Roaming\Python\Scripts\eb-script.py", line 6, in
from pkg_resources import load_entry_point
File "C:\Users\liron\AppData\Roaming\Python\Python36\site-packages\pkg_resources__init__.py", line 3095, in
#_call_aside
File "C:\Users\liron\AppData\Roaming\Python\Python36\site-packages\pkg_resources__init__.py", line 3079, in _call_aside
f(*args, **kwargs)
File "C:\Users\liron\AppData\Roaming\Python\Python36\site-packages\pkg_resources__init__.py", line 3108, in _initialize_master_working_set
working_set = WorkingSet._build_master()
File "C:\Users\liron\AppData\Roaming\Python\Python36\site-packages\pkg_resources__init__.py", line 572, in _build_master
return cls._build_from_requirements(requires)
File "C:\Users\liron\AppData\Roaming\Python\Python36\site-packages\pkg_resources__init__.py", line 585, in _build_from_requirements
dists = ws.resolve(reqs, Environment())
File "C:\Users\liron\AppData\Roaming\Python\Python36\site-packages\pkg_resources__init__.py", line 779, in resolve
raise VersionConflict(dist, req).with_context(dependent_req)
pkg_resources.ContextualVersionConflict: (colorama 0.3.7 (c:\users\liron\appdata\roaming\python\lib\site-packages), Requirement.parse('colorama<0.4,>=0.3.9; sys_platform == "win32"'), {'docker-compose'})
i tried to install with pip and msi.
aws version: aws-cli/1.15.35 Python/3.6.0 Windows/7 botocore/1.10.35
python version: Python 3.6.3
pip version: pip 10.0.1 from c:\users\liron\appdata\roaming\python\lib\site-packages\pip (python 3.6).
i tried to update and uninstall everything without any luck.
thank you for your help :)
i want to create python virtualenv with python version 2.7.6 but there is error as follow , even i wanted to reinstall pip but it showed that pip is of latest version:
$ virtualenv cow-env
New python executable in cow-env/bin/python Installing setuptools,
pip...
Complete output from command /home/cow/cow/cow-env/bin /python -c "import sys, pip; sys...d\"] + sys.argv[1:]))" setuptools pip:
Traceback (most recent call last):
File "<string>", line 1, in <module>
File "/usr/share/python-virtualenv/pip-1.5debian1-py2.py3-
none-any.whl /pip/__init__.py", line 10, in <module>
File "/usr/share/python-virtualenv/pip-1.5debian1-py2.py3-none-any.whl
/pip/util.py", line 18, in <module>
File "/usr/share/python-virtualenv/pip-1.5debian1-py2.py3-none-any.whl
/pip/_vendor/distlib/version.py", line 14, in <module>
File "/usr/share/python-virtualenv/pip-1.5debian1-py2.py3-none-any.whl
/pip/_vendor/distlib/compat.py", line 31, in <module>
ImportError: cannot import name HTTPSHandler
----------------------------------------
...Installing setuptools, pip...done.
Traceback (most recent call last):
File "/usr/bin/virtualenv", line 3, in <module>
virtualenv.main()
File "/usr/lib/python2.7/dist-packages/virtualenv.py", line 825, in main
symlink=options.symlink)
File "/usr/lib/python2.7/dist-packages/virtualenv.py", line 993, in
create_environment
install_wheel(to_install, py_executable, search_dirs)
File "/usr/lib/python2.7/dist-packages/virtualenv.py", line 961, in
install_wheel
'PIP_NO_INDEX': '1'
File "/usr/lib/python2.7/dist-packages/virtualenv.py", line 903,
in call_subprocess
% (cmd_desc, proc.returncode))
OSError: Command /home/cow/cow/cow-env/bin/python -c "import sys,pip; sys...d\"] + sys.argv[1:]))" setuptools pip failed with error code 1
output of $pip --version is as follow:
Traceback (most recent call last):
File "/usr/local/bin/pip", line 7, in <module>
from pip import main
File "/usr/lib/python2.7/dist-packages/pip/__init__.py", line 60, in <module>
from pip.util import get_installed_distributions, get_prog
File "/usr/lib/python2.7/dist-packages/pip/util.py", line 19, in <module>
from distlib import version
File "/usr/share/python-wheels/distlib-0.1.8-py2.py3-none-any.whl /distlib/version.py", line 14, in <module>
File "/usr/share/python-wheels/distlib-0.1.8-py2.py3-none-any.whl /distlib/compat.py", line 31, in <module>
ImportError: cannot import name HTTPSHandler
this issue has been resolved by reinstalling the libpython2.7-stdlib package.
sudo apt-get --reinstall install libpython2.7-stdlib
this re installation placed the missing file _ssl.so in /usr/lib/python2.7/lib-dynload.
I'd been working on Python distribution from Anaconda, as default. To use virtual environments, installed virtualenv. It shows that it was installed in the default location as in Anaconda. But, while creating one, it shows error. I do not understand anything as I'm not a pro. Please help. Thanks!!
avijit#avijit-Inspiron-3521:~$ virtualenv --version
15.0.3
avijit#avijit-Inspiron-3521:~$ cd Downloads/alieturklmugermany/virtualbcf/
avijit#avijit-Inspiron-3521:~/Downloads/alieturklmugermany/virtualbcf$ virtualenv bcfenv1
New python executable in /home/avijit/Downloads/alieturklmugermany/virtualbcf/bcfenv1/bin/python
Installing setuptools, pip, wheel...
Complete output from command /home/avijit/Downloa...f/bcfenv1/bin/python - setuptools pip wheel:
Traceback (most recent call last):
File "<stdin>", line 4, in <module>
File "/home/avijit/anaconda2/lib/python2.7/tempfile.py", line 32, in <module>
import io as _io
File "/home/avijit/anaconda2/lib/python2.7/io.py", line 51, in <module>
import _io
ImportError: /home/avijit/Downloads/alieturklmugermany/virtualbcf/bcfenv1/lib/python2.7/lib-dynload/_io.so: undefined symbol: _PyCodec_LookupTextEncoding
----------------------------------------
...Installing setuptools, pip, wheel...done.
Traceback (most recent call last):
File "/home/avijit/anaconda2/bin/virtualenv", line 11, in <module>
sys.exit(main())
File "/home/avijit/anaconda2/lib/python2.7/site-packages/virtualenv.py", line 711, in main
symlink=options.symlink)
File "/home/avijit/anaconda2/lib/python2.7/site-packages/virtualenv.py", line 944, in create_environment
download=download,
File "/home/avijit/anaconda2/lib/python2.7/site-packages/virtualenv.py", line 900, in install_wheel
call_subprocess(cmd, show_stdout=False, extra_env=env, stdin=SCRIPT)
File "/home/avijit/anaconda2/lib/python2.7/site-packages/virtualenv.py", line 795, in call_subprocess
% (cmd_desc, proc.returncode))
OSError: Command /home/avijit/Downloa...f/bcfenv1/bin/python - setuptools pip wheel failed with error code 1
When I try to install Review Board via this command on Ubuntu 14.04:
sudo rb-site install /var/www/reviewboard.mysite.com
I get the following error:
Traceback (most recent call last):
File "/usr/local/bin/rb-site", line 5, in <module>
from pkg_resources import load_entry_point
File "build/bdist.linux-x86_64/egg/pkg_resources/__init__.py", line 2927, in <module>
File "build/bdist.linux-x86_64/egg/pkg_resources/__init__.py", line 2913, in _call_aside
File "build/bdist.linux-x86_64/egg/pkg_resources/__init__.py", line 2940, in _initialize_master_working_set
File "build/bdist.linux-x86_64/egg/pkg_resources/__init__.py", line 635, in _build_master
File "build/bdist.linux-x86_64/egg/pkg_resources/__init__.py", line 943, in require
File "build/bdist.linux-x86_64/egg/pkg_resources/__init__.py", line 829, in resolve
pkg_resources.DistributionNotFound: The 'cryptography>=1.1' distribution was not found and is required by paramiko
How do I fix it?
You need to run:
sudo easy_install --upgrade cryptography