Skip to content
Advertisement

Python – Command “python setup.py egg_info” failed with error code 1 in /tmp/pip-build-21ft0H/pandas

I’m using Centos 7 and Python 2.7.5. The problem is when I install Pandas, i got this error message

SystemError: Cannot compile 'Python.h'. Perhaps you need to install python-dev|python-devel.

    ----------------------------------------
Command "python setup.py egg_info" failed with error code 1 in /tmp/pip-build-21ft0H/pandas

I already tried a lot of solutions but no success even yum -y update.

Advertisement

Answer

I already found the answer. I need to install python via RPM.

rpm -i ftp://195.220.108.108/linux/centos/7.1.1503/updates/x86_64/Packages/python-2.7.5-18.el7_1.1.x86_64.rpm

Reference: http://blog.revivalx.com/2015/11/14/python-command-python-setup-py-egg_info-failed-with-error-code-1-tmppip-build-21ft0hpandas/

User contributions licensed under: CC BY-SA
7 People found this is helpful
Advertisement