Error installing telethon with pip3 install telethon - python

When i try to install telethon from pip3 i got this error, why?
I run this in a windows 10 of 32 bits in the cmd.
C:\Users\JUAN>pip3 install telethon
Collecting telethon
Using cached Telethon-1.16.4-py3-none-any.whl (483 kB)
Collecting pyaes
Using cached pyaes-1.6.1.tar.gz (28 kB)
ERROR: Command errored out with exit status 1:
command: 'c:\users\juan\appdata\local\programs\python\python38-32\python.exe' -c 'import sys, setuptools, tokenize; sys.argv[0] = '"'"'C:\\Users\\JUAN\\AppData\\Local\\Temp\\pip-install-i2of7eld\\pyaes\\setup.py'"'"'; __file__='"'"'C:\\Users\\JUAN\\AppData\\Local\\Temp\\pip-install-i2of7eld\\pyaes\\setup.py'"'"';f=getattr(tokenize, '"'"'open'"'"', open)(__file__);code=f.read().replace('"'"'\r\n'"'"', '"'"'\n'"'"');f.close();exec(compile(code, __file__, '"'"'exec'"'"'))' egg_info --egg-base 'C:\Users\JUAN\AppData\Local\Temp\pip-pip-egg-info-pffewwkh'
cwd: C:\Users\JUAN\AppData\Local\Temp\pip-install-i2of7eld\pyaes\
Complete output (24 lines):
Traceback (most recent call last):
File "c:\users\juan\appdata\local\programs\python\python38-32\lib\site-packages\pkg_resources\__init__.py", line 2867, in get_entry_map
ep_map = self._ep_map
File "c:\users\juan\appdata\local\programs\python\python38-32\lib\site-packages\pkg_resources\__init__.py", line 2825, in __getattr__
raise AttributeError(attr)
AttributeError: _ep_map
During handling of the above exception, another exception occurred:
Traceback (most recent call last):
File "<string>", line 1, in <module>
File "C:\Users\JUAN\AppData\Local\Temp\pip-install-i2of7eld\pyaes\setup.py", line 10, in <module>
setup(name = 'pyaes',
File "c:\users\juan\appdata\local\programs\python\python38-32\lib\distutils\core.py", line 108, in setup
_setup_distribution = dist = klass(attrs)
File "c:\users\juan\appdata\local\programs\python\python38-32\lib\site-packages\setuptools\dist.py", line 423, in __init__
for ep in pkg_resources.iter_entry_points('distutils.setup_keywords'):
File "c:\users\juan\appdata\local\programs\python\python38-32\lib\site-packages\pkg_resources\__init__.py", line 657, in <genexpr>
for entry in dist.get_entry_map(group).values()
File "c:\users\juan\appdata\local\programs\python\python38-32\lib\site-packages\pkg_resources\__init__.py", line 2869, in get_entry_map
ep_map = self._ep_map = EntryPoint.parse_map(
File "c:\users\juan\appdata\local\programs\python\python38-32\lib\site-packages\pkg_resources\__init__.py", line 2550, in parse_map
raise ValueError("Entry points must be listed in groups")
ValueError: Entry points must be listed in groups
----------------------------------------
ERROR: Command errored out with exit status 1: python setup.py egg_info Check the logs for full command output.

I solved the problem by uninstalling python and pip, the python version I had was 3.8.5 and the latest version is 3.8.9.

Related

Could not install PyCurl 7.43.0.6 on Python 3.8.8 | RHEL 8.3

Workstation details:
RHEL 8.3 - x86_64
Python 3.8.8
libcurl 7.61.1-14.el8_3.1
I tried
pip install pycurl==7.43.0.6
The error [traceback]:
ERROR: Command errored out with exit status 1:
command: /home/raa/Projects/venv/test55/bin/python -c 'import sys, setuptools, tokenize; sys.argv[0] = '"'"'/tmp/pip-install-s049piq0/pycurl_e1573e1fea9a47e5a16d1e71517e3013/setup.py'"'"'; __file__='"'"'/tmp/pip-install-s049piq0/pycurl_e1573e1fea9a47e5a16d1e71517e3013/setup.py'"'"';f=getattr(tokenize, '"'"'open'"'"', open)(__file__);code=f.read().replace('"'"'\r\n'"'"', '"'"'\n'"'"');f.close();exec(compile(code, __file__, '"'"'exec'"'"'))' egg_info --egg-base /tmp/pip-pip-egg-info-46mx471v
cwd: /tmp/pip-install-s049piq0/pycurl_e1573e1fea9a47e5a16d1e71517e3013/
Complete output (22 lines):
Traceback (most recent call last):
File "/tmp/pip-install-s049piq0/pycurl_e1573e1fea9a47e5a16d1e71517e3013/setup.py", line 236, in configure_unix
p = subprocess.Popen((self.curl_config(), '--version'),
File "/usr/local/lib/python3.8/subprocess.py", line 858, in __init__
self._execute_child(args, executable, preexec_fn, close_fds,
File "/usr/local/lib/python3.8/subprocess.py", line 1706, in _execute_child
raise child_exception_type(errno_num, err_msg, err_filename)
FileNotFoundError: [Errno 2] No such file or directory: 'curl-config'
During handling of the above exception, another exception occurred:
Traceback (most recent call last):
File "<string>", line 1, in <module>
File "/tmp/pip-install-s049piq0/pycurl_e1573e1fea9a47e5a16d1e71517e3013/setup.py", line 988, in <module>
ext = get_extension(sys.argv, split_extension_source=split_extension_source)
File "/tmp/pip-install-s049piq0/pycurl_e1573e1fea9a47e5a16d1e71517e3013/setup.py", line 649, in get_extension
ext_config = ExtensionConfiguration(argv)
File "/tmp/pip-install-s049piq0/pycurl_e1573e1fea9a47e5a16d1e71517e3013/setup.py", line 101, in __init__
self.configure()
File "/tmp/pip-install-s049piq0/pycurl_e1573e1fea9a47e5a16d1e71517e3013/setup.py", line 241, in configure_unix
raise ConfigurationError(msg)
__main__.ConfigurationError: Could not run curl-config: [Errno 2] No such file or directory: 'curl-config'
----------------------------------------
WARNING: Discarding https://files.pythonhosted.org/packages/50/1a/35b1d8b8e4e23a234f1b17a8a40299fd550940b16866c9a1f2d47a04b969/pycurl-7.43.0.6.tar.gz#sha256=8301518689daefa53726b59ded6b48f33751c383cf987b0ccfbbc4ed40281325 (from https://pypi.org/simple/pycurl/) (requires-python:>=3.5). Command errored out with exit status 1: python setup.py egg_info Check the logs for full command output.
ERROR: Could not find a version that satisfies the requirement pycurl==7.43.0.6
ERROR: No matching distribution found for pycurl==7.43.0.6
Kindly help.
The source of the error is not related to Python or the package pycurl. It was due to the missing libcurl-devel on RHEL.
The error message/trackback did not mention this clearly.
In RHEL 8, I installed the library using sudo dnf install libcurl-devel.
Later, pip install pycurl==7.43.0.6 solved the issue.

EROR when trying to download pygame on to python

I've tried lots of different ways of installing pygame and none work it always comes up with an error message.
I need this module for a game: I'm trying to make a multiplayer game for a project for school and online told me to use this module.
Any help would be great!! Also I've never put a question on here before so hope I'm doing it right! Thanks
C:\Users\RDSTw>py -m pip install pygame==2.0.0.dev6
Collecting pygame==2.0.0.dev6
Using cached pygame-2.0.0.dev6.tar.gz (3.7 MB)
ERROR: Command errored out with exit status 1:
command: 'C:\Python\python.exe' -c 'import sys, setuptools, tokenize; sys.argv[0] = '"'"'C:\\Users\\RDSTw\\AppData\\Local\\Temp\\pip-install-lgh1zxp0\\pygame\\setup.py'"'"'; __file__='"'"'C:\\Users\\RDSTw\\AppData\\Local\\Temp\\pip-install-lgh1zxp0\\pygame\\setup.py'"'"';f=getattr(tokenize, '"'"'open'"'"', open)(__file__);code=f.read().replace('"'"'\r\n'"'"', '"'"'\n'"'"');f.close();exec(compile(code, __file__, '"'"'exec'"'"'))' egg_info --egg-base 'C:\Users\RDSTw\AppData\Local\Temp\pip-pip-egg-info-ov5fgttm'
cwd: C:\Users\RDSTw\AppData\Local\Temp\pip-install-lgh1zxp0\pygame\
Complete output (31 lines):
WARNING, No "Setup" File Exists, Running "buildconfig/config.py"
Using WINDOWS configuration...
Traceback (most recent call last):
File "<string>", line 1, in <module>
File "C:\Users\RDSTw\AppData\Local\Temp\pip-install-lgh1zxp0\pygame\setup.py", line 258, in <module>
buildconfig.config.main(AUTO_CONFIG)
File "C:\Users\RDSTw\AppData\Local\Temp\pip-install-lgh1zxp0\pygame\buildconfig\config.py", line 208, in main
deps = CFG.main(**kwds)
File "C:\Users\RDSTw\AppData\Local\Temp\pip-install-lgh1zxp0\pygame\buildconfig\config_win.py", line 559, in main
and download_win_prebuilt.ask(**download_kwargs):
File "C:\Users\RDSTw\AppData\Local\Temp\pip-install-lgh1zxp0\pygame\buildconfig\download_win_prebuilt.py", line 269, in ask
update(x86=x86, x64=x64, sdl2=sdl2)
File "C:\Users\RDSTw\AppData\Local\Temp\pip-install-lgh1zxp0\pygame\buildconfig\download_win_prebuilt.py", line 252, in update
download_prebuilts(download_dir, x86=x86, x64=x64, sdl2=sdl2)
File "C:\Users\RDSTw\AppData\Local\Temp\pip-install-lgh1zxp0\pygame\buildconfig\download_win_prebuilt.py", line 101, in download_prebuilts
download_sha1_unzip(url, checksum, temp_dir, 1)
File "C:\Users\RDSTw\AppData\Local\Temp\pip-install-lgh1zxp0\pygame\buildconfig\download_win_prebuilt.py", line 17, in download_sha1_unzip
import requests
ModuleNotFoundError: No module named 'requests'
Making dir :prebuilt_downloads:
---
For help with compilation see:
https://www.pygame.org/wiki/CompileWindows
To contribute to pygame development see:
https://www.pygame.org/contribute.html
---
----------------------------------------
ERROR: Command errored out with exit status 1: python setup.py egg_info Check the logs for full command output.
This says that you don't have the requests module installed. So first install requests using pip install -U requests and then again install pygame. I also did it this way.

Python Urllib ContextualVersionConflict

Till Oct 20, it was fine. Oct 21, it failed with the below messages. Can any one help here
command: /usr/local/bin/python -c 'import sys, setuptools, tokenize; sys.argv[0] = '"'"'/tmp/pip-install-i8sl36tr/elasticsearch-curator/setup.py'"'"'; __file__='"'"'/tmp/pip-install-i8sl36tr/elasticsearch-curator/setup.py'"'"';f=getattr(tokenize, '"'"'open'"'"', open)(__file__);code=f.read().replace('"'"'\r\n'"'"', '"'"'\n'"'"');f.close();exec(compile(code, __file__, '"'"'exec'"'"'))' egg_info --egg-base /tmp/pip-pip-egg-info-et0c4kgw
cwd: /tmp/pip-install-i8sl36tr/elasticsearch-curator/
Complete output (20 lines):
Traceback (most recent call last):
File "/tmp/pip-install-i8sl36tr/elasticsearch-curator/setup.py", line 39, in <module>
from cx_Freeze import setup, Executable
ModuleNotFoundError: No module named 'cx_Freeze'
Traceback (most recent call last):
File "<string>", line 1, in <module>
File "/tmp/pip-install-i8sl36tr/elasticsearch-curator/setup.py", line 177, in <module>
tests_require = ["mock", "nose", "coverage", "nosexcover"]
File "/usr/local/lib/python3.7/site-packages/setuptools/__init__.py", line 152, in setup
_install_setup_requires(attrs)
File "/usr/local/lib/python3.7/site-packages/setuptools/__init__.py", line 147, in _install_setup_requires
dist.fetch_build_eggs(dist.setup_requires)
File "/usr/local/lib/python3.7/site-packages/setuptools/dist.py", line 676, in fetch_build_eggs
replace_conflicting=True,
File "/usr/local/lib/python3.7/site-packages/pkg_resources/__init__.py", line 775, in resolve
raise VersionConflict(dist, req).with_context(dependent_req)
pkg_resources.ContextualVersionConflict: (urllib3 1.24.3 (/tmp/pip-install-i8sl36tr/elasticsearch-curator/.eggs/urllib3-1.24.3-py3.7.egg), Requirement.parse('urllib3<1.26,>=1.25.4'), {'botocore'})
----------------------------------------
ERROR: Command errored out with exit status 1: python setup.py egg_info Check the logs for full command output.```
On 19.10.2020 AWS released new botocore version 1.19.0.
So far versions 1.19.0, 1.19.1, 1.19.2 are not compatible with elasticsearch-curator - version 5.8.1.
I had same problem and temporary fixed issue by installing older version of elasticsearch-curator - version 5.6.0.
I believe AWS will soon release botocore version that is compatible with elasticsearch-curator - version 5.8.1.
It looks like your Python environment is inconsistent with the versions requires by your packages. Have you tried installing your environment with the --use-feature=2020-resolver flag?
python -m pip install --use-feature=2020-resolver elasticsearch elasticsearch-curator ...

Can't install nim inside of env

I'm attempting to install nim into a folder where I'm experimenting using virtual environment, but I can't seem to install nim using pip install nim. Any ideas why, I've included the error message. Thank you! :)
Collecting nim
Using cached nim-0.1.0.tar.gz (11 kB)
ERROR: Command errored out with exit status 1:
command: /Library/Frameworks/Python.framework/Versions/3.8/bin/python3.8 -c 'import sys, setuptools, tokenize; sys.argv[0] = '"'"'/private/var/folders/jq/_5zq1xh91hgcj49vb9lh689h0000gn/T/pip-install-c6r0gd5_/nim/setup.py'"'"'; __file__='"'"'/private/var/folders/jq/_5zq1xh91hgcj49vb9lh689h0000gn/T/pip-install-c6r0gd5_/nim/setup.py'"'"';f=getattr(tokenize, '"'"'open'"'"', open)(__file__);code=f.read().replace('"'"'\r\n'"'"', '"'"'\n'"'"');f.close();exec(compile(code, __file__, '"'"'exec'"'"'))' egg_info --egg-base /private/var/folders/jq/_5zq1xh91hgcj49vb9lh689h0000gn/T/pip-pip-egg-info-lhsvapoi
cwd: /private/var/folders/jq/_5zq1xh91hgcj49vb9lh689h0000gn/T/pip-install-c6r0gd5_/nim/
Complete output (11 lines):
Traceback (most recent call last):
File "<string>", line 1, in <module>
File "/private/var/folders/jq/_5zq1xh91hgcj49vb9lh689h0000gn/T/pip-install-c6r0gd5_/nim/setup.py", line 171, in <module>
pkg_data = _package_data(__file__.replace('setup.py', '__init__.py'))
File "/private/var/folders/jq/_5zq1xh91hgcj49vb9lh689h0000gn/T/pip-install-c6r0gd5_/nim/setup.py", line 150, in _package_data
data = literal_eval(u''.join(lines))
File "/private/var/folders/jq/_5zq1xh91hgcj49vb9lh689h0000gn/T/pip-install-c6r0gd5_/nim/setup.py", line 122, in literal_eval
return _convert(node_or_string)
File "/private/var/folders/jq/_5zq1xh91hgcj49vb9lh689h0000gn/T/pip-install-c6r0gd5_/nim/setup.py", line 69, in _convert
if isinstance(node, (Str, Bytes)):
NameError: name 'Str' is not defined
----------------------------------------
ERROR: Command errored out with exit status 1: python setup.py egg_info Check the logs for full command output.

How to solve error installing PyObjC in Ubuntu 18.04

I try to installing PyObjC using pip but still getting error
ERROR: Command errored out with exit status 1:
command: /usr/bin/python3.6 -c 'import sys, setuptools, tokenize; sys.argv[0] = '"'"'/tmp/pip-install-819f93sh/pyobjc-framework-ScreenSaver/setup.py'"'"'; __file__='"'"'/tmp/pip-install-819f93sh/pyobjc-framework-ScreenSaver/setup.py'"'"';f=getattr(tokenize, '"'"'open'"'"', open)(__file__);code=f.read().replace('"'"'\r\n'"'"', '"'"'\n'"'"');f.close();exec(compile(code, __file__, '"'"'exec'"'"'))' egg_info --egg-base pip-egg-info
cwd: /tmp/pip-install-819f93sh/pyobjc-framework-ScreenSaver/
Complete output (15 lines):
Traceback (most recent call last):
File "<string>", line 1, in <module>
File "/tmp/pip-install-819f93sh/pyobjc-framework-ScreenSaver/setup.py", line 21, in <module>
extra_link_args=['-framework', 'ScreenSaver']),
File "/tmp/pip-install-819f93sh/pyobjc-framework-ScreenSaver/pyobjc_setup.py", line 392, in Extension
os_level = get_os_level()
File "/tmp/pip-install-819f93sh/pyobjc-framework-ScreenSaver/pyobjc_setup.py", line 206, in get_os_level
pl = plistlib.readPlist('/System/Library/CoreServices/SystemVersion.plist')
File "/usr/lib/python3.6/plistlib.py", line 162, in readPlist
with _maybe_open(pathOrFile, 'rb') as fp:
File "/usr/lib/python3.6/contextlib.py", line 81, in __enter__
return next(self.gen)
File "/usr/lib/python3.6/plistlib.py", line 120, in _maybe_open
with open(pathOrFile, mode) as fp:
FileNotFoundError: [Errno 2] No such file or directory: '/System/Library/CoreServices/SystemVersion.plist'
----------------------------------------
ERROR: Command errored out with exit status 1: python setup.py egg_info Check the logs for full command output.
You cannot. PyObjC can only be installed at MacOS X.
try this :
git clone https://github.com/ronaldoussoren/pyobjc
install it manually :
python3 pyobjc/install.py or python2 pyobjc/install.py or by going in the directory.

Categories

Resources