I am unable to install psutil by requeriments.txt neither by logging in with heroku run bash command and using the pip install psutil command.
The log is very large, so, I will put the "most important" part of it:
unable to execute 'gcc': No such file or directory
error: command 'gcc' failed with exit status 1
Command "/app/.heroku/python/bin/python -u -c "import setuptools, tokenize;__file__='/tmp/pip-build-759b4csi/psutil/setup.py';f=getattr(tokenize, 'open', open)(__file__);code=f.read().replace('\r\n', '\n');f.close();exec(compile(code, __file__, 'exec'))" install --record /tmp/pip-addox7ji-record/install-record.txt --single-version-externally-managed --compile" failed with error code 1 in /tmp/pip-build-759b4csi/psutil/
Can someone help me with this?
I am using python 3.6.0 and pip 9.0.1
I used pip freeze > requirements.txt to generate a new requirements and this new file was processed by the deploy tool correctly.
Related
When running the command cloud app deploy in the command line, it fails on installing requirements.txt after it hits "Running setup.py install for appscript: started".
Command "/env/bin/python3.6 -u -c "import setuptools, tokenize;__file__='/tmp/pip-install-18grw9xa/appscript/setup.py';f=getattr(tokenize, 'open', open)(__file__);code=f.read().replace('\r\n', '\n');f.close();exec(compile(code, __file__, 'exec'))" install --record /tmp/pip-record-vm76fdr2/install-record.txt --single-version-externally-managed --compile --install-headers /env/include/site/python3.6/appscript" failed with error code 1 in /tmp/pip-install-18grw9xa/appscript/
Step #1: You are using pip version 10.0.1, however version 19.2.2 is available.
Step #1: You should consider upgrading via the 'pip install --upgrade pip' command.
Step #1: The command '/bin/sh -c pip install -r requirements.txt' returned a non-zero code: 1
It seems like you need to upgrade your pip. Take a look here Failed with error code 1 to try to do it. It must works for you.
I couldn't find any good tutorial for installation of Darknet and Lightnet on Windows. However, following the tutorials on their official Git Page, I tried running Python command
pip install darknetpy
On running this, I am seeing the following error:
Failed building wheel for darknetpy
Running setup.py clean for darknetpy
Failed to build darknetpy
Installing collected packages: darknetpy
Running setup.py install for darknetpy ... error
Complete output from command c:\users\pop\appdata\local\programs\python\python36\python.exe -u -c "import setuptools, tokenize;__file__='C:\\Users\\Pop\\AppData\\Local\\Temp\\pip-build-aew1mvz2\\darknetpy\\setup.py';f=getattr(tokenize, 'open', open)(__file__);code=f.read().replace('\r\n', '\n');f.close();exec(compile(code, __file__, 'exec'))" install --record C:\Users\Pop\AppData\Local\Temp\pip-hj4a3ywj-record\install-record.txt --single-version-externally-managed --compile:
running install
running build
running build_ext
'make' is not recognized as an internal or external command,
operable program or batch file.
error: [WinError 2] The system cannot find the file specified: 'C:\\Users\\Pop\\AppData\\Local\\Temp\\darknet\\libdarknet.so'
----------------------------------------
Command "c:\users\pop\appdata\local\programs\python\python36\python.exe -u -c "import setuptools, tokenize;__file__='C:\\Users\\Pop\\AppData\\Local\\Temp\\pip-build-aew1mvz2\\darknetpy\\setup.py';f=getattr(tokenize, 'open', open)(__file__);code=f.read().replace('\r\n', '\n');f.close();exec(compile(code, __file__, 'exec'))" install --record C:\Users\Pop\AppData\Local\Temp\pip-hj4a3ywj-record\install-record.txt --single-version-externally-managed --compile" failed with error code 1 in C:\Users\Pop\AppData\Local\Temp\pip-build-aew1mvz2\darknetpy\
Even with Cygwin(64), the issue darknetpy issue 1 shows it wouldn't work on Windows.
The best options are (on Windows):
use a VM Linux
use a docker image for darknet, like lindt/docker-darknet (with docker-for-windows, which will use a small Linux VM through HyperV)
The pypi page for darketpy indicates that it requires a POSIX operating system. If you want to install it on Windows, you'll need something like cygwin.
I am trying to migrate to Cloud Endpoints Frameworks 2.0 for App Engine from v1 in Python
When I pip install pip install -t lib google-endpoints --ignore-installed, I get an error
Command "/usr/bin/python -u -c "import setuptools, tokenize;__file__='/private/tmp/pip-build-blaNgj/pycrypto/setup.py';f=getattr(tokenize, 'open', open)(__file__);code=f.read().replace('\r\n', '\n');f.close();exec(compile(code, __file__, 'exec'))" install --record /tmp/pip-E6OxwC-record/install-record.txt --single-version-externally-managed --compile --home=/tmp/tmp_5iRxU" failed with error code 1 in /private/tmp/pip-build-blaNgj/pycrypto
How to fix this?
I have also tried sudo pip install -t lib google-endpoints --ignore-installed, but it didn't help
It is very hard to read the error message you pasted, since it's all on one line, but I think the issue you're having may be due to being on a Mac and not having either XCode or the XCode command line tools installed.
Try running 'gcc' at the command line and seeing if it says you need to install something.
After making sure that pip is installed, I tried installing the twitter package using pip install python-twitter in the terminal but i get this error:
Command "/usr/bin/python -u -c "import setuptools, tokenize;file='/private/var/folders/d1/49j6jy0d7hd_5cb6__cqwzhw0000gn/T/pip-build-5dzoDc/oauthlib/setup.py';f=getattr(tokenize, 'open', open)(file);code=f.read().replace('\r\n', '\n');f.close();exec(compile(code, file, 'exec'))" install --record /var/folders/d1/49j6jy0d7hd_5cb6__cqwzhw0000gn/T/pip-GuXf_v-record/install-record.txt --single-version-externally-managed --compile" failed with error code 1 in /private/var/folders/d1/49j6jy0d7hd_5cb6__cqwzhw0000gn/T/pip-build-5dzoDc/oauthlib/
It's worth noting I have Python 3.6 installed on a Mac, apart from the default 2.7.
The code also ends with this "error: could not create '/Library/Python/2.7/site-packages/oauthlib': Permission denied"
I get the following error message:
*bytes, CFIndex length, CFAllocatorRef bytesDeallocator);
^~~~~~~~~~~~~~~~~~~~~~~~~~~
error: command 'gcc' failed with exit status 1
I used this command:
"//anaconda/bin/python -u -c "import setuptools,
tokenize;file='/private/var/folders/sg/p9ztjwgx1v1cctrr2hmdymcr0000gp/T/pip-build-y_mai_3m/kivy/setup.py';f=getattr(tokenize,
'open', open)(file);code=f.read().replace('\r\n',
'\n');f.close();exec(compile(code, file, 'exec'))" install
--record /var/folders/sg/p9ztjwgx1v1cctrr2hmdymcr0000gp/T/pip-_3c7ty_r-record/install-record.txt
--single-version-externally-managed --compile" failed with error code 1 in
/private/var/folders/sg/p9ztjwgx1v1cctrr2hmdymcr0000gp/T/pip-build-y_mai_3m/kivy/
What could be the reason, how to solve this problem?
I figured it out, as Cython was located inside anaconda pip couldn't install kivy, and used pip3 to install Cython and so kivy, now it is installed :) thanks people