httptools: Failed building wheel for httptools
Any idea on possible workaround:
After pip3 install httptools
:
Collecting httptools
Using cached https://files.pythonhosted.org/packages/1b/03/215969db11abe8741e9c266a4cbe803a372bd86dd35fa0084c4df6d4bd00/httptools-0.0.13.tar.gz
Building wheels for collected packages: httptools
Building wheel for httptools (setup.py) ... error
Complete output from command /usr/bin/python3.6 -u -c "import setuptools, tokenize;__file__='/tmp/pip-install-ffzualnz/httptools/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-lq_cgux2 --python-tag cp36:
running bdist_wheel
running build
running build_py
creating build
creating build/lib.linux-x86_64-3.6
creating build/lib.linux-x86_64-3.6/httptools
copying httptools/__init__.py -> build/lib.linux-x86_64-3.6/httptools
creating build/lib.linux-x86_64-3.6/httptools/parser
copying httptools/parser/__init__.py -> build/lib.linux-x86_64-3.6/httptools/parser
copying httptools/parser/errors.py -> build/lib.linux-x86_64-3.6/httptools/parser
running egg_info
writing httptools.egg-info/PKG-INFO
writing dependency_links to httptools.egg-info/dependency_links.txt
writing top-level names to httptools.egg-info/top_level.txt
reading manifest file 'httptools.egg-info/SOURCES.txt'
reading manifest template 'MANIFEST.in'
writing manifest file 'httptools.egg-info/SOURCES.txt'
copying httptools/parser/parser.c -> build/lib.linux-x86_64-3.6/httptools/parser
running build_ext
building 'httptools.parser.parser' extension
creating build/temp.linux-x86_64-3.6
creating build/temp.linux-x86_64-3.6/httptools
creating build/temp.linux-x86_64-3.6/httptools/parser
creating build/temp.linux-x86_64-3.6/vendor
creating build/temp.linux-x86_64-3.6/vendor/http-parser
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 -I/usr/include/python3.6m -c httptools/parser/parser.c -o build/temp.linux-x86_64-3.6/httptools/parser/parser.o -O2
httptools/parser/parser.c:4:20: fatal error: Python.h: No such file or directory
compilation terminated.
error: command 'x86_64-linux-gnu-gcc' failed with exit status 1
----------------------------------------
Failed building wheel for httptools
Running setup.py clean for httptools
Failed to build httptools
Installing collected packages: httptools
Running setup.py install for httptools ... error
Complete output from command /usr/bin/python3.6 -u -c "import setuptools, tokenize;__file__='/tmp/pip-install-ffzualnz/httptools/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-xaxh1zu8/install-record.txt --single-version-externally-managed --compile:
running install
running build
running build_py
creating build
creating build/lib.linux-x86_64-3.6
creating build/lib.linux-x86_64-3.6/httptools
copying httptools/__init__.py -> build/lib.linux-x86_64-3.6/httptools
creating build/lib.linux-x86_64-3.6/httptools/parser
copying httptools/parser/__init__.py -> build/lib.linux-x86_64-3.6/httptools/parser
copying httptools/parser/errors.py -> build/lib.linux-x86_64-3.6/httptools/parser
running egg_info
writing httptools.egg-info/PKG-INFO
writing dependency_links to httptools.egg-info/dependency_links.txt
writing top-level names to httptools.egg-info/top_level.txt
reading manifest file 'httptools.egg-info/SOURCES.txt'
reading manifest template 'MANIFEST.in'
writing manifest file 'httptools.egg-info/SOURCES.txt'
copying httptools/parser/parser.c -> build/lib.linux-x86_64-3.6/httptools/parser
running build_ext
building 'httptools.parser.parser' extension
creating build/temp.linux-x86_64-3.6
creating build/temp.linux-x86_64-3.6/httptools
creating build/temp.linux-x86_64-3.6/httptools/parser
creating build/temp.linux-x86_64-3.6/vendor
creating build/temp.linux-x86_64-3.6/vendor/http-parser
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 -I/usr/include/python3.6m -c httptools/parser/parser.c -o build/temp.linux-x86_64-3.6/httptools/parser/parser.o -O2
httptools/parser/parser.c:4:20: fatal error: Python.h: No such file or directory
compilation terminated.
error: command 'x86_64-linux-gnu-gcc' failed with exit status 1
----------------------------------------
Command "/usr/bin/python3.6 -u -c "import setuptools, tokenize;__file__='/tmp/pip-install-ffzualnz/httptools/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-xaxh1zu8/install-record.txt --single-version-externally-managed --compile" failed with error code 1 in /tmp/pip-install-ffzualnz/httptools/
Ubuntu 16.04 LTS
About this issue
- Original URL
- State: closed
- Created 5 years ago
- Reactions: 11
- Comments: 21 (2 by maintainers)
Mark this as resolved.
sudo apt install python3.6-dev
did the job. Thanks!!! I had couple Python versions and 3.6 was simlink topython3
.conda install -c conda-forge httptools ?
sudo apt-get install python3-dev
?This has already been made a new issue #59
I ran into a similar issue, where
pip install httptools
works in a python3.8 environment, but not in python3.9. I noticed that pip uses…httptools-0.1.1-cp38-cp38-manylinux1_x86_64.whl
in 3.8httptools-0.1.1.tar.gz
in 3.9So I’m guessing there are no wheels available for 3.9? I’m on shared hosting so I’m unable to install
python-devel
.I’m on Ubuntu 19.10 and
apt install python3.7-dev
helping build httptools successfully. Thanks.Wheels are now available.
I encountered a similar error in the
python:3.7-slim-stretch
docker image, and I resolved it by switching topython:3.7-stretch
. I suspect the resolution was thatgcc
was present in3.7-stretch
and not3.7-slim-stretch
.the error message I got
@Proteusiq I was having this issue too on a similar environment.
I don’t remember all the changes I made but I know I installed zlib, libffi, and built 3.7.4 from source and I’m not having issues building httptools anymore.
Something about doing that fixed the issue but I’m not entirely sure what.