Command : sudopip install jupyter
Error :
Complete output from command /usr/bin/python -u -c "import setuptools, tokenize;__file__='/tmp/pip-build-En0PFz/scandir/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-OVVJzg-record/install-record.txt --single-version-externally-managed --compile:
running install
running build
running build_py
creating build
creating build/lib.linux-x86_64-2.7
copying scandir.py -> build/lib.linux-x86_64-2.7
running build_ext
building '_scandir' extension
creating build/temp.linux-x86_64-2.7
x86_64-linux-gnu-gcc -pthread -fno-strict-aliasing -DNDEBUG -g -fwrapv -O2 -Wall -Wstrict-prototypes -fPIC -I/usr/include/python2.7 -c _scandir.c -o build/temp.linux-x86_64-2.7/_scandir.o
_scandir.c:14:20: fatal error: Python.h: No such file or directory
#include <Python.h>
^
compilation terminated.
error: command 'x86_64-linux-gnu-gcc' failed with exit status 1
----------------------------------------
Command "/usr/bin/python -u -c "import setuptools, tokenize;__file__='/tmp/pip-build-En0PFz/scandir/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-OVVJzg-record/install-record.txt --single-version-externally-managed --compile" failed with error code 1 in /tmp/pip-build-En0PFz/scandir/
First:
$ sudo apt-get install python-dev
and then:
$ sudo pip install jupyter
Related
I have python 3.8 and I am trying to install pyodbc library to connect sql server but getting error. Please help me how to install it? Is there any other library to connect sql server?
I am using below command -
python3 -m pip install pyodbc
Error I am getting-
Collecting pyodbc
Using cached pyodbc-4.0.30.tar.gz (266 kB)
Building wheels for collected packages: pyodbc
Building wheel for pyodbc (setup.py) ... error
ERROR: Command errored out with exit status 1:
command: /usr/local/bin/python3 -u -c 'import sys, setuptools, tokenize; sys.argv[0] = '"'"'/tmp/pip-install-fnygoose/pyodbc_7db1b044e510447c8352fe2f54d4cbe0/setup.py'"'"'; __file__='"'"'/tmp/pip-install-fnygoose/pyodbc_7db1b044e510447c8352fe2f54d4cbe0/setup.py'"'"';f=getattr(tokenize, '"'"'open'"'"', open)(__file__);code=f.read().replace('"'"'\r\n'"'"', '"'"'\n'"'"');f.close();exec(compile(code, __file__, '"'"'exec'"'"'))' bdist_wheel -d /tmp/pip-wheel-67s6uwc7
cwd: /tmp/pip-install-fnygoose/pyodbc_7db1b044e510447c8352fe2f54d4cbe0/
Complete output (10 lines):
running bdist_wheel
running build
running build_ext
building 'pyodbc' extension
creating build
creating build/temp.linux-x86_64-3.7
creating build/temp.linux-x86_64-3.7/src
gcc -pthread -Wno-unused-result -Wsign-compare -DNDEBUG -g -fwrapv -O3 -Wall -fPIC -DPYODBC_VERSION=4.0.30 -I/app/python3.7.4/include/python3.7m -c src/buffer.cpp -o build/temp.linux-x86_64-3.7/src/buffer.o -Wno-write-strings
gcc: error trying to exec 'cc1plus': execvp: No such file or directory
error: command 'gcc' failed with exit status 1
----------------------------------------
ERROR: Failed building wheel for pyodbc
Running setup.py clean for pyodbc
Failed to build pyodbc
Installing collected packages: pyodbc
Running setup.py install for pyodbc ... error
ERROR: Command errored out with exit status 1:
command: /usr/local/bin/python3 -u -c 'import sys, setuptools, tokenize; sys.argv[0] = '"'"'/tmp/pip-install-fnygoose/pyodbc_7db1b044e510447c8352fe2f54d4cbe0/setup.py'"'"'; __file__='"'"'/tmp/pip-install-fnygoose/pyodbc_7db1b044e510447c8352fe2f54d4cbe0/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-w_eqzv_4/install-record.txt --single-version-externally-managed --compile --install-headers /app/python3.7.4/include/python3.7m/pyodbc
cwd: /tmp/pip-install-fnygoose/pyodbc_7db1b044e510447c8352fe2f54d4cbe0/
Complete output (10 lines):
running install
running build
running build_ext
building 'pyodbc' extension
creating build
creating build/temp.linux-x86_64-3.7
creating build/temp.linux-x86_64-3.7/src
gcc -pthread -Wno-unused-result -Wsign-compare -DNDEBUG -g -fwrapv -O3 -Wall -fPIC -DPYODBC_VERSION=4.0.30 -I/app/python3.7.4/include/python3.7m -c src/buffer.cpp -o build/temp.linux-x86_64-3.7/src/buffer.o -Wno-write-strings
gcc: error trying to exec 'cc1plus': execvp: No such file or directory
error: command 'gcc' failed with exit status 1
----------------------------------------
ERROR: Command errored out with exit status 1: /usr/local/bin/python3 -u -c 'import sys, setuptools, tokenize; sys.argv[0] = '"'"'/tmp/pip-install-fnygoose/pyodbc_7db1b044e510447c8352fe2f54d4cbe0/setup.py'"'"'; __file__='"'"'/tmp/pip-install-fnygoose/pyodbc_7db1b044e510447c8352fe2f54d4cbe0/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-w_eqzv_4/install-record.txt --single-version-externally-managed --compile --install-headers /app/python3.7.4/include/python3.7m/pyodbc Check the logs for full command output.
You need to install the first dependency.
!apt install unixodbc-dev --yes
!pip install pyodbc
I have errors almost everytime I use pip (the package installer of Python) and I really don't manage to figure out how to fix them.
Below are the errors while trying to install pyv8 :
$ pip3 install pyv8
Collecting pyv8
Downloading https://files.pythonhosted.org/packages/c6/fb/5c0512a373e3d0aad0b683f439e7bdd67f95a69e6473b76dc2cfdca2c43f/PyV8-0.5.zip
Building wheels for collected packages: pyv8
Running setup.py bdist_wheel for pyv8 ... error
Complete output from command /usr/bin/python3 -u -c "import setuptools, tokenize;__file__='/tmp/pip-install-wmzf4xop/pyv8/setup.py';f=getattr(tokenize, 'open', open)(__file__);code=f.read().replace('\r\n', '\n');f.close();exec(compile(code, __file__, 'exec'))" bdist_wheel -d /tmp/pip-wheel-h9c9ol37 --python-tag cp37:
running bdist_wheel
running build
running build_py
creating build
creating build/lib.linux-x86_64-3.7
copying PyV8.py -> build/lib.linux-x86_64-3.7
running build_ext
building '_PyV8' extension
creating build/temp.linux-x86_64-3.7
creating build/temp.linux-x86_64-3.7/src
x86_64-linux-gnu-gcc -pthread -DNDEBUG -g -fwrapv -O2 -Wall -g -fstack-protector-strong -Wformat -Werror=format-security -Wdate-time -D_FORTIFY_SOURCE=2 -fPIC -DBOOST_PYTHON_STATIC_LIB -Ilib/python/inc -Ilib/boost/inc -Ilib/v8/inc -I/usr/include/python3.7m -c src/Exception.cpp -o build/temp.linux-x86_64-3.7/src/Exception.o
In file included from src/Exception.cpp:1:
src/Exception.h:6:10: fatal error: v8.h: Aucun fichier ou dossier de ce type
#include <v8.h>
^~~~~~
compilation terminated.
error: command 'x86_64-linux-gnu-gcc' failed with exit status 1
----------------------------------------
Failed building wheel for pyv8
Running setup.py clean for pyv8
Failed to build pyv8
Installing collected packages: pyv8
Running setup.py install for pyv8 ... error
Complete output from command /usr/bin/python3 -u -c "import setuptools, tokenize;__file__='/tmp/pip-install-wmzf4xop/pyv8/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-wig6t3n9/install-record.txt --single-version-externally-managed --compile --user --prefix=:
running install
running build
running build_py
creating build
creating build/lib.linux-x86_64-3.7
copying PyV8.py -> build/lib.linux-x86_64-3.7
running build_ext
building '_PyV8' extension
creating build/temp.linux-x86_64-3.7
creating build/temp.linux-x86_64-3.7/src
x86_64-linux-gnu-gcc -pthread -DNDEBUG -g -fwrapv -O2 -Wall -g -fstack-protector-strong -Wformat -Werror=format-security -Wdate-time -D_FORTIFY_SOURCE=2 -fPIC -DBOOST_PYTHON_STATIC_LIB -Ilib/python/inc -Ilib/boost/inc -Ilib/v8/inc -I/usr/include/python3.7m -c src/Exception.cpp -o build/temp.linux-x86_64-3.7/src/Exception.o
In file included from src/Exception.cpp:1:
src/Exception.h:6:10: fatal error: v8.h: Aucun fichier ou dossier de ce type
#include <v8.h>
^~~~~~
compilation terminated.
error: command 'x86_64-linux-gnu-gcc' failed with exit status 1
----------------------------------------
Command "/usr/bin/python3 -u -c "import setuptools, tokenize;__file__='/tmp/pip-install-wmzf4xop/pyv8/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-wig6t3n9/install-record.txt --single-version-externally-managed --compile --user --prefix=" failed with error code 1 in /tmp/pip-install-wmzf4xop/pyv8/
Sorry if I can't give more precision
My PyCharm console suggested that ImportError: No module named sha3
So I've decided to install this module.
However, this error emerged when using the command of pip install sha3, the whole process and descriptions are below.
Collecting sha3
Using cached https://files.pythonhosted.org/packages/b3/b4/d23c8e8843226dcf54c6c533a6717d34d50358f74496cfa77e6e8c7e146a/sha3-0.2.1.tar.gz
Building wheels for collected packages: sha3
Running setup.py bdist_wheel for sha3 ... error
Complete output from command /Applications/anaconda3/bin/python -u -c "import setuptools, tokenize;__file__='/private/var/folders/fc/_2t60h750rl4svnh50tp3l7h0000gn/T/pip-install-mlrjkbkr/sha3/setup.py';f=getattr(tokenize, 'open', open)(__file__);code=f.read().replace('\r\n', '\n');f.close();exec(compile(code, __file__, 'exec'))" bdist_wheel -d /private/var/folders/fc/_2t60h750rl4svnh50tp3l7h0000gn/T/pip-wheel-rsy0_asx --python-tag cp37:
running bdist_wheel
running build
running build_py
creating build
creating build/lib.macosx-10.7-x86_64-3.7
creating build/lib.macosx-10.7-x86_64-3.7/sha3
copying sha3/__init__.py -> build/lib.macosx-10.7-x86_64-3.7/sha3
running build_ext
building '_sha3' extension
creating build/temp.macosx-10.7-x86_64-3.7
creating build/temp.macosx-10.7-x86_64-3.7/src
creating build/temp.macosx-10.7-x86_64-3.7/src/64
gcc -Wno-unused-result -Wsign-compare -Wunreachable-code -DNDEBUG -g -fwrapv -O3 -Wall -Wstrict-prototypes -I/Applications/anaconda3/include -arch x86_64 -I/Applications/anaconda3/include -arch x86_64 -Isrc/ -Isrc/64 -I/Applications/anaconda3/include/python3.7m -c sha3.c -o build/temp.macosx-10.7-x86_64-3.7/sha3.o
xcrun: error: invalid active developer path (/Library/Developer/CommandLineTools), missing xcrun at: /Library/Developer/CommandLineTools/usr/bin/xcrun
error: command 'gcc' failed with exit status 1
----------------------------------------
Failed building wheel for sha3
Running setup.py clean for sha3
Failed to build sha3
Installing collected packages: sha3
Running setup.py install for sha3 ... error
Complete output from command /Applications/anaconda3/bin/python -u -c "import setuptools, tokenize;__file__='/private/var/folders/fc/_2t60h750rl4svnh50tp3l7h0000gn/T/pip-install-mlrjkbkr/sha3/setup.py';f=getattr(tokenize, 'open', open)(__file__);code=f.read().replace('\r\n', '\n');f.close();exec(compile(code, __file__, 'exec'))" install --record /private/var/folders/fc/_2t60h750rl4svnh50tp3l7h0000gn/T/pip-record-15ac0elc/install-record.txt --single-version-externally-managed --compile:
running install
running build
running build_py
creating build
creating build/lib.macosx-10.7-x86_64-3.7
creating build/lib.macosx-10.7-x86_64-3.7/sha3
copying sha3/__init__.py -> build/lib.macosx-10.7-x86_64-3.7/sha3
running build_ext
building '_sha3' extension
creating build/temp.macosx-10.7-x86_64-3.7
creating build/temp.macosx-10.7-x86_64-3.7/src
creating build/temp.macosx-10.7-x86_64-3.7/src/64
gcc -Wno-unused-result -Wsign-compare -Wunreachable-code -DNDEBUG -g -fwrapv -O3 -Wall -Wstrict-prototypes -I/Applications/anaconda3/include -arch x86_64 -I/Applications/anaconda3/include -arch x86_64 -Isrc/ -Isrc/64 -I/Applications/anaconda3/include/python3.7m -c sha3.c -o build/temp.macosx-10.7-x86_64-3.7/sha3.o
xcrun: error: invalid active developer path (/Library/Developer/CommandLineTools), missing xcrun at: /Library/Developer/CommandLineTools/usr/bin/xcrun
error: command 'gcc' failed with exit status 1
----------------------------------------
Command "/Applications/anaconda3/bin/python -u -c "import setuptools, tokenize;__file__='/private/var/folders/fc/_2t60h750rl4svnh50tp3l7h0000gn/T/pip-install-mlrjkbkr/sha3/setup.py';f=getattr(tokenize, 'open', open)(__file__);code=f.read().replace('\r\n', '\n');f.close();exec(compile(code, __file__, 'exec'))" install --record /private/var/folders/fc/_2t60h750rl4svnh50tp3l7h0000gn/T/pip-record-15ac0elc/install-record.txt --single-version-externally-managed --compile" failed with error code 1 in /private/var/folders/fc/_2t60h750rl4svnh50tp3l7h0000gn/T/pip-install-mlrjkbkr/sha3/
I have no idea how to fix this.
I am trying to install big float on OS X but i am encountering multiple issues.
I have installed amp without any problem, but when I have tried to install mpfr I got this error:
Warning: mpfr-3.1.5 already installed, it's just not linked.
What does this mean? (I am using Homebrew).
Then, obviously, if I try to install bigfloat it doesn't work and i get this error:
Collecting bigfloat
Downloading bigfloat-0.3.0.tar.gz (216kB)
100% |████████████████████████████████| 225kB 1.6MB/s
Installing collected packages: bigfloat
Running setup.py install for bigfloat ... error
Complete output from command /Users/name/anaconda2/bin/python -u -c "import setuptools, tokenize;__file__='/private/tmp/pip-build-VCyOBn/bigfloat/setup.py';f=getattr(tokenize, 'open', open)(__file__);code=f.read().replace('\r\n', '\n');f.close();exec(compile(code, __file__, 'exec'))" build_ext -I/usr/local/include -L/usr/local/lib install --record /tmp/pip-K9AHsP-record/install-record.txt --single-version-externally-managed --compile:
running build_ext
building 'mpfr' extension
creating build
creating build/temp.macosx-10.7-x86_64-2.7
gcc -fno-strict-aliasing -I/Users/name/anaconda2/include -arch x86_64 -DNDEBUG -g -fwrapv -O3 -Wall -Wstrict-prototypes -I/usr/local/include -I/Users/name/anaconda2/include/python2.7 -c mpfr.c -o build/temp.macosx-10.7-x86_64-2.7/mpfr.o
In file included from /usr/local/lib/gcc/x86_64-apple-darwin15.6.0/6.2.0/include-fixed/syslimits.h:7:0,
from /usr/local/lib/gcc/x86_64-apple-darwin15.6.0/6.2.0/include-fixed/limits.h:34,
from /Users/name/anaconda2/include/python2.7/Python.h:19,
from mpfr.c:16:
/usr/local/lib/gcc/x86_64-apple-darwin15.6.0/6.2.0/include-fixed/limits.h:168:61: fatal error: limits.h: No such file or directory
#include_next <limits.h> /* recurse down to the real one */
^
compilation terminated.
error: command 'gcc' failed with exit status 1
----------------------------------------
Command "/Users//anaconda2/bin/python -u -c "import setuptools, tokenize;__file__='/private/tmp/pip-build-VCyOBn/bigfloat/setup.py';f=getattr(tokenize, 'open', open)(__file__);code=f.read().replace('\r\n', '\n');f.close();exec(compile(code, __file__, 'exec'))" build_ext -I/usr/local/include -L/usr/local/lib install --record /tmp/pip-K9AHsP-record/install-record.txt --single-version-externally-managed --compile" failed with error code 1 in /private/tmp/pip-build-VCyOBn/bigfloat/
You must install python-devel
In OS X try to uninstall and install again:
brew uninstall python
brew install python
Also according to this issue, Osx GCC (which is just a symlink to clang) doesn't ship with OpenMP support out of the box. You can install GCC with OpenMP.
brew install gcc --without-multilib
Iam trying to install a python package but I get an error that I could not find a solution. Can somebody help me?
Here is the error menssage:
tiago#tiago:~/Rscripts$ sudo pip install alignlib-lite
The directory '/home/tiago/.cache/pip/http' or its parent directory is not owned by the current user and the cache has been disabled. Please check the permissions and owner of that directory. If executing pip with sudo, you may want sudo's -H flag.
The directory '/home/tiago/.cache/pip' or its parent directory is not owned by the current user and caching wheels has been disabled. check the permissions and owner of that directory. If executing pip with sudo, you may want sudo's -H flag.
Collecting alignlib-lite
Downloading alignlib-lite-0.2.3.tar.gz (226kB)
100% |████████████████████████████████| 229kB 393kB/s
Installing collected packages: alignlib-lite
Running setup.py install for alignlib-lite ... error
Complete output from command /usr/bin/python -u -c "import setuptools, tokenize;__file__='/tmp/pip-build-3Y6mrr/alignlib-lite/setup.py';exec(compile(getattr(tokenize, 'open', open)(__file__).read().replace('\r\n', '\n'), __file__, 'exec'))" install --record /tmp/pip-b6OHJX-record/install-record.txt --single-version-externally-managed --compile:
/usr/lib/python2.7/distutils/extension.py:133: UserWarning: Unknown Extension options: 'cmdclass'
warnings.warn(msg)
running install
running build
running build_ext
cythoning alignlib_lite.pyx to alignlib_lite.cpp
building 'alignlib_lite' extension
creating build
creating build/temp.linux-x86_64-2.7
creating build/temp.linux-x86_64-2.7/alignlib_src
x86_64-linux-gnu-gcc -pthread -DNDEBUG -g -fwrapv -O2 -Wall -Wstrict-prototypes -fno-strict-aliasing -D_FORTIFY_SOURCE=2 -g -fstack-protector-strong -Wformat -Werror=format-security -fPIC -Ialignlib_src -I/usr/include/python2.7 -c alignlib_lite.cpp -o build/temp.linux-x86_64-2.7/alignlib_lite.o
cc1plus: warning: command line option ‘-Wstrict-prototypes’ is valid for C/ObjC but not for C++
alignlib_lite.cpp:256:32: fatal error: boost/shared_ptr.hpp: No such file or directory
compilation terminated.
error: command 'x86_64-linux-gnu-gcc' failed with exit status 1
----------------------------------------
Command "/usr/bin/python -u -c "import setuptools, tokenize;__file__='/tmp/pip-build-3Y6mrr/alignlib-lite/setup.py';exec(compile(getattr(tokenize, 'open', open)(__file__).read().replace('\r\n', '\n'), __file__, 'exec'))" install --record /tmp/pip-b6OHJX-record/install-record.txt --single-version-externally-managed --compile" failed with error code 1 in /tmp/pip-build-3Y6mrr/alignlib-lite