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.
Related
I am trying to install genetic algorithm in Anaconda by doing below with errors. Could you please advise the issue? Thanks
pip install genetic algorithm
then I got below error:
(tf_cpu) C:\Users\test>pip install genetic algorithm
Collecting algorithm
Downloading algorithm-1.2.0-py3-none-any.whl (10 kB)
Collecting genetic
Downloading genetic-0.1.dev3.tar.gz (5.5 kB)
ERROR: Command errored out with exit status 1:
command: 'C:\Users\yongn\miniconda3\envs\tf_cpu\python.exe' -c 'import sys, setuptools, tokenize; sys.argv[0] = '"'"'C:\\Users\\yongn\\AppData\\Local\\Temp\\pip-install-qm3ds3_2\\genetic_0c5368225ac6428486c14ebef370f1c5\\setup.py'"'"'; __file__='"'"'C:\\Users\\yongn\\AppData\\Local\\Temp\\pip-install-qm3ds3_2\\genetic_0c5368225ac6428486c14ebef370f1c5\\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\yongn\AppData\Local\Temp\pip-pip-egg-info-yctesttu'
cwd: C:\Users\yongn\AppData\Local\Temp\pip-install-qm3ds3_2\genetic_0c5368225ac6428486c14ebef370f1c5\
Complete output (9 lines):
Traceback (most recent call last):
File "<string>", line 1, in <module>
File "C:\Users\yongn\AppData\Local\Temp\pip-install-qm3ds3_2\genetic_0c5368225ac6428486c14ebef370f1c5\setup.py", line 39, in <module>
packages=find_packages("./"),
File "C:\Users\yongn\miniconda3\envs\tf_cpu\lib\site-packages\setuptools\__init__.py", line 64, in find
convert_path(where),
File "C:\Users\yongn\miniconda3\envs\tf_cpu\lib\distutils\util.py", line 124, in convert_path
raise ValueError("path '%s' cannot end with '/'" % pathname)
ValueError: path './' cannot end with '/'
----------------------------------------
ERROR: Command errored out with exit status 1: python setup.py egg_info Check the logs for full command output.
refer to this : https://pypi.org/project/geneticalgorithm/
pip install geneticalgorithm
Cannot install PROJ
>>pip install git+https://github.com/OSGeo/PROJ.git
Collecting git+https://github.com/OSGeo/PROJ.git
Cloning https://github.com/OSGeo/PROJ.git to c:\users\lenovo\appdata\local\temp\pip-req-build-jwr6msmg
ERROR: Command errored out with exit status 1:
command: 'c:\python37\python.exe' -c 'import sys, setuptools, tokenize; sys.argv[0] = '"'"'C:\\Users\\lenovo\\AppData\\Local\\Temp\\pip-req-build-jwr6msmg\\setup.py'"'"'; __file__='"'"'C:\\Users\\lenovo\\AppData\\Local\\Temp\\pip-req-build-jwr6msmg\\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\lenovo\AppData\Local\Temp\pip-pip-egg-info-w2azftsy'
cwd: C:\Users\lenovo\AppData\Local\Temp\pip-req-build-jwr6msmg\
Complete output (5 lines):
Traceback (most recent call last):
File "<string>", line 1, in <module>
File "c:\python37\lib\tokenize.py", line 447, in open
buffer = _builtin_open(filename, 'rb')
FileNotFoundError: [Errno 2] No such file or directory: 'C:\\Users\\lenovo\\AppData\\Local\\Temp\\pip-req-build-jwr6msmg\\setup.py'
----------------------------------------
ERROR: Command errored out with exit status 1: python setup.py egg_info Check the logs for full command output.
I tried installing it manually using the source file, But it is also giving the following error
>>> pip install proj-7.1.1.tar.gz
Processing e:\wihg\15-09-2020\surfacewave tomography\iris_data\test\proj-7.1.1.tar.gz
ERROR: Command errored out with exit status 1:
command: 'c:\python37\python.exe' -c 'import sys, setuptools, tokenize; sys.argv[0] = '"'"'C:\\Users\\lenovo\\AppData\\Local\\Temp\\pip-req-build-3y5iufx3\\setup.py'"'"'; __file__='"'"'C:\\Users\\lenovo\\AppData\\Local\\Temp\\pip-req-build-3y5iufx3\\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\lenovo\AppData\Local\Temp\pip-pip-egg-info-2t2y4p78'
cwd: C:\Users\lenovo\AppData\Local\Temp\pip-req-build-3y5iufx3\
Complete output (5 lines):
Traceback (most recent call last):
File "<string>", line 1, in <module>
File "c:\python37\lib\tokenize.py", line 447, in open
buffer = _builtin_open(filename, 'rb')
FileNotFoundError: [Errno 2] No such file or directory: 'C:\\Users\\lenovo\\AppData\\Local\\Temp\\pip-req-build-3y5iufx3\\setup.py'
----------------------------------------
ERROR: Command errored out with exit status 1: python setup.py egg_info Check the logs for full command output.
How to solve this error? (Have to install it in Non-conda environment)
PROJ is a C library, not a Python package, so you cannot use pip to install it.
If you just want to work with PROJ from Python, you can use PyPROJ and install it with pip install pyproj. On MacOS, Linux, and Windows this will give you pre-built wheels that already include PROJ.
If you're trying to install it for CartoPy (based on your tags) you'll need to install PROJ separately following their install instructions.
I am using python 2.7 with Django. and after I was install pip install mysqlclient, I got this error.
ERROR: Command errored out with exit status 1:
command: /usr/local/opt/python#2/bin/python2.7 -c 'import sys, setuptools, tokenize; sys.argv[0] = '"'"'/private/var/folders/tj/vjwl0qpd6l5ct6bdjgwyk1rh0000gp/T/pip-install-QSWu02/MySQL-python/setup.py'"'"'; __file__='"'"'/private/var/folders/tj/vjwl0qpd6l5ct6bdjgwyk1rh0000gp/T/pip-install-QSWu02/MySQL-python/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/tj/vjwl0qpd6l5ct6bdjgwyk1rh0000gp/T/pip-install-QSWu02/MySQL-python/pip-egg-info
cwd: /private/var/folders/tj/vjwl0qpd6l5ct6bdjgwyk1rh0000gp/T/pip-install-QSWu02/MySQL-python/
Complete output (10 lines):
sh: mysql_config: command not found
Traceback (most recent call last):
File "<string>", line 1, in <module>
File "/private/var/folders/tj/vjwl0qpd6l5ct6bdjgwyk1rh0000gp/T/pip-install-QSWu02/MySQL-python/setup.py", line 17, in <module>
metadata, options = get_config()
File "setup_posix.py", line 43, in get_config
libs = mysql_config("libs_r")
File "setup_posix.py", line 25, in mysql_config
raise EnvironmentError("%s not found" % (mysql_config.path,))
EnvironmentError: mysql_config not found
----------------------------------------
ERROR: Command errored out with exit status 1: python setup.py egg_info Check the logs for full command output.
In mac OSX I have already installed mariadb 10.1.20 now while i Try to install mysql-python using pip install mysql-python system showing following error:
Collecting mysql-python
Using cached https://files.pythonhosted.org/packages/a5/e9/51b544da85a36a68debe7a7091f068d802fc515a3a202652828c73453cad/MySQL-python-1.2.5.zip
ERROR: Command errored out with exit status 1:
command: /Users/eskimi/Development/ErpNext/venv/bin/python -c 'import sys, setuptools, tokenize; sys.argv[0] = '"'"'/private/var/folders/1r/0z4_dp3j0237vqx1jvc0sn3c0000gp/T/pip-install-s0tXN_/mysql-python/setup.py'"'"'; __file__='"'"'/private/var/folders/1r/0z4_dp3j0237vqx1jvc0sn3c0000gp/T/pip-install-s0tXN_/mysql-python/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/1r/0z4_dp3j0237vqx1jvc0sn3c0000gp/T/pip-install-s0tXN_/mysql-python/pip-egg-info
cwd: /private/var/folders/1r/0z4_dp3j0237vqx1jvc0sn3c0000gp/T/pip-install-s0tXN_/mysql-python/
Complete output (10 lines):
sh: mysql_config: command not found
Traceback (most recent call last):
File "<string>", line 1, in <module>
File "/private/var/folders/1r/0z4_dp3j0237vqx1jvc0sn3c0000gp/T/pip-install-s0tXN_/mysql-python/setup.py", line 17, in <module>
metadata, options = get_config()
File "setup_posix.py", line 43, in get_config
libs = mysql_config("libs_r")
File "setup_posix.py", line 25, in mysql_config
raise EnvironmentError("%s not found" % (mysql_config.path,))
EnvironmentError: mysql_config not found
----------------------------------------
ERROR: Command errored out with exit status 1: python setup.py egg_info Check the logs for full command output.
How can resolve this issue?
N.B I am using python 2.7
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.