Closed bmayott closed 6 years ago
Traceback (most recent call last):
File "/usr/bin/pip", line 7, in <module>
from pip._internal import main
ImportError: No module named pip._internal
You cannot install pyq without a working pip. Please try python-list to get support.
We are using RHEL 7.5. I have tried several things. pip for other modules. [root@xbnj-kdb01 bin]# pip list Package Version
backports.ssl-match-hostname 3.5.0.1 chardet 2.2.1 configobj 4.7.2 configshell-fb 1.1.23 decorator 3.4.0 ethtool 0.8 iniparse 0.4 iotop 0.6 ipaddress 1.0.16 javapackages 1.0.0 kitchen 1.1.1 kmod 0.1 langtable 0.0.31 lxml 3.2.1 M2Crypto 0.21.1 Magic-file-extensions 0.2 pciutils 1.7.3 perf 0.1 pip 10.0.1 pycurl 7.19.0 pygobject 3.22.0 pygpgme 0.3 pyinotify 0.9.4 pyliblzma 0.5.3 pyOpenSSL 0.13.1 pyparsing 1.5.6 python-augeas 0.5.0 python-dateutil 1.5 python-dmidecode 3.10.13 python-linux-procfs 0.4.9 pyudev 0.21.0 pyxattr 0.5.1 PyYAML 3.10 rhnlib 2.5.65 rtslib-fb 2.1.63 schedutils 0.4 setuptools 39.2.0 six 1.9.0 slip 0.4.0 slip.dbus 0.4.0 subscription-manager 1.20.11 targetcli-fb 2.1.fb46 urlgrabber 3.10 urwid 1.1.1 wheel 0.31.1 yum-langpacks 0.4.2 yum-metadata-parser 1.1.4
current OS python is Python 2.7.5 and I get the following error when I try to install via pip.
[root@xbnj-kdb01 ogan]# pip install -i https://pypi.enlnt.com --no-binary pyq pyq Looking in indexes: https://pypi.enlnt.com Collecting pyq Downloading https://github.com/enlnt/pyq/archive/pyq-4.1.1.tar.gz / 942kB 14.3MB/s Skipping bdistwheel for pyq, due to binaries being disabled for it. Installing collected packages: pyq Running setup.py install for pyq ... error Complete output from command /usr/local/bin/python2.7 -u -c "import setuptools, tokenize;file='/tmp/pip-install-iY9nrT/pyq/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-KrSRE/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 creating build/lib.linux-x86_64-2.7/pyq copying src/pyq/init.py -> build/lib.linux-x86_64-2.7/pyq copying src/pyq/_n.py -> build/lib.linux-x86_64-2.7/pyq copying src/pyq/_pt_run.py -> build/lib.linux-x86_64-2.7/pyq copying src/pyq/cmd.py -> build/lib.linux-x86_64-2.7/pyq copying src/pyq/conftest.py -> build/lib.linux-x86_64-2.7/pyq copying src/pyq/magic.py -> build/lib.linux-x86_64-2.7/pyq copying src/pyq/ptk.py -> build/lib.linux-x86_64-2.7/pyq copying src/pyq/version.py -> build/lib.linux-x86_64-2.7/pyq creating build/lib.linux-x86_64-2.7/pyq/tests copying src/pyq/tests/init.py -> build/lib.linux-x86_64-2.7/pyq/tests copying src/pyq/tests/test_ci.py -> build/lib.linux-x86_64-2.7/pyq/tests copying src/pyq/tests/test_com.py -> build/lib.linux-x86_64-2.7/pyq/tests copying src/pyq/tests/test_k.py -> build/lib.linux-x86_64-2.7/pyq/tests copying src/pyq/tests/test_magic.py -> build/lib.linux-x86_64-2.7/pyq/tests copying src/pyq/tests/test_memoryview.py -> build/lib.linux-x86_64-2.7/pyq/tests copying src/pyq/tests/test_n.py -> build/lib.linux-x86_64-2.7/pyq/tests copying src/pyq/tests/test_no_numpy.py -> build/lib.linux-x86_64-2.7/pyq/tests copying src/pyq/tests/test_numpy.py -> build/lib.linux-x86_64-2.7/pyq/tests copying src/pyq/tests/test_p.py -> build/lib.linux-x86_64-2.7/pyq/tests copying src/pyq/tests/test_pathlib.py -> build/lib.linux-x86_64-2.7/pyq/tests copying src/pyq/tests/test_pypath.py -> build/lib.linux-x86_64-2.7/pyq/tests copying src/pyq/tests/test_pyq_executable.py -> build/lib.linux-x86_64-2.7/pyq/tests copying src/pyq/tests/test_python_q.py -> build/lib.linux-x86_64-2.7/pyq/tests copying src/pyq/tests/test_q.py -> build/lib.linux-x86_64-2.7/pyq/tests copying src/pyq/tests/test_sd.py -> build/lib.linux-x86_64-2.7/pyq/tests copying src/pyq/tests/test_threads.py -> build/lib.linux-x86_64-2.7/pyq/tests copying src/pyq/tests/test_version.py -> build/lib.linux-x86_64-2.7/pyq/tests running build_ext building 'pyq._k' extension creating build/temp.linux-x86_64-2.7 creating build/temp.linux-x86_64-2.7/src creating build/temp.linux-x86_64-2.7/src/pyq gcc -pthread -fno-strict-aliasing -O2 -g -pipe -Wall -Wp,-D_FORTIFY_SOURCE=2 -fexceptions -fstack-protector-strong --param=ssp-buffer-size=4 -grecord-gcc-switches -m64 -mtune=generic -D_GNU_SOURCE -fPIC -fwrapv -DNDEBUG -O2 -g -pipe -Wall -Wp,-D_FORTIFY_SOURCE=2 -fexceptions -fstack-protector-strong --param=ssp-buffer-size=4 -grecord-gcc-switches -m64 -mtune=generic -D_GNU_SOURCE -fPIC -fwrapv -fPIC -DKXVER=3 -DKXVER2=6 -I/usr/include/python2.7 -c src/pyq/_k.c -o build/temp.linux-x86_64-2.7/src/pyq/_k.o -Wpointer-arith -Werror -fno-strict-aliasing src/pyq/_k.c:49:20: fatal error: Python.h: No such file or directory
^
compilation terminated.
error: command 'gcc' failed with exit status 1
----------------------------------------
Command "/usr/local/bin/python2.7 -u -c "import setuptools, tokenize;file='/tmp/pip-install-iY9nrT/pyq/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-KrSRE_/install-record.txt --single-version-externally-managed --compile" failed with error code 1 in /tmp/pip-install-iY9nrT/pyq/
I have managed to install python.3.6.i686 under /opt and managed to install pyq under it, but we are getting errors.
Ideally, i would like to install via OS python and get it working.
Not using virtual environments nor corda. Not a requirement from our developers.
It looks like your system does not have Python header files. Try
yum install python-devel
thank you. that was it.
Questions
PyQ installation is not working ..
[ ] Which operating system are you using (if Linux, please provide flavour of it, i.e RedHat, CentOS or Ubuntu), is it 32-bit, or 64-bit?
[ ] Which version of PyQ are you running? Please provide output of
pyq --versions
, if PyQ isn't operational, please provide Python interpreter version and PyQ versionpython -V; python3 -V; pip list | grep pyq
:[ ] Which version of kdb+ are you using, is it 32-bit or 64-bit?
[ ] Did you use virtual environment to install PyQ? If not, why?
[ ] Where is your
QHOME
? Please provide outputenv | grep QHOME
on linux/macOS, orset|grep QHOME
on Windows.[ ] Do you use Conda? If so, what version?
Steps to reproduce the issue
Expected result
Actual result
Workaround
If you know workaround, please provide it here.