ankh6 commented on issue #11851:
URL: https://github.com/apache/airflow/issues/11851#issuecomment-815175635
@kaxil
I ran pre-commit hooks before submitting a PR. Hooks exited with status code
1.
It seems to be linked to the compiler. Can you confirm ? How can I resolve
it ?
Here's the stack trace:
n unexpected error has occurred: CalledProcessError: command:
('/home/andy/.cache/pre-commit/repoqtbnjhpl/py_env-python3/bin/python',
'-mpip', 'install', '.')
return code: 1
expected return code: 0
stdout:
Processing /home/andy/.cache/pre-commit/repoqtbnjhpl
Collecting fuzzywuzzy
Using cached fuzzywuzzy-0.18.0-py2.py3-none-any.whl (18 kB)
Collecting python-Levenshtein
Using cached python-Levenshtein-0.12.2.tar.gz (50 kB)
Requirement already satisfied: setuptools in
./py_env-python3/lib/python3.8/site-packages (from
python-Levenshtein->pre-commit-hooks==1.1.9) (54.1.2)
Building wheels for collected packages: pre-commit-hooks,
python-Levenshtein
Building wheel for pre-commit-hooks (setup.py): started
Building wheel for pre-commit-hooks (setup.py): finished with status
'done'
Created wheel for pre-commit-hooks:
filename=pre_commit_hooks-1.1.9-py3-none-any.whl size=12894
sha256=fc2c42332d478b74b77a4012ed86a8c51ef31f8fd5028c38c0cc06c668cf7523
Stored in directory:
/tmp/pip-ephem-wheel-cache-4d5cnbpe/wheels/54/fb/96/b8ec4580389bc404d8c82207404a585471fc382178fa9ccef0
Building wheel for python-Levenshtein (setup.py): started
Building wheel for python-Levenshtein (setup.py): finished with status
'error'
Running setup.py clean for python-Levenshtein
Successfully built pre-commit-hooks
Failed to build python-Levenshtein
Installing collected packages: python-Levenshtein, fuzzywuzzy,
pre-commit-hooks
Running setup.py install for python-Levenshtein: started
Running setup.py install for python-Levenshtein: finished with
status 'error'
stderr:
ERROR: Command errored out with exit status 1:
command:
/home/andy/.cache/pre-commit/repoqtbnjhpl/py_env-python3/bin/python -u -c
'import sys, setuptools, tokenize; sys.argv[0] =
'"'"'/tmp/pip-install-47wy09t9/python-levenshtein_830405ef8926471bbcc145f1daaa2797/setup.py'"'"';
__file__='"'"'/tmp/pip-install-47wy09t9/python-levenshtein_830405ef8926471bbcc145f1daaa2797/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-sz80c6t4
cwd:
/tmp/pip-install-47wy09t9/python-levenshtein_830405ef8926471bbcc145f1daaa2797/
Complete output (34 lines):
running bdist_wheel
running build
running build_py
creating build
creating build/lib.linux-x86_64-3.8
creating build/lib.linux-x86_64-3.8/Levenshtein
copying Levenshtein/StringMatcher.py ->
build/lib.linux-x86_64-3.8/Levenshtein
copying Levenshtein/__init__.py ->
build/lib.linux-x86_64-3.8/Levenshtein
running egg_info
writing python_Levenshtein.egg-info/PKG-INFO
writing dependency_links to
python_Levenshtein.egg-info/dependency_links.txt
writing entry points to python_Levenshtein.egg-info/entry_points.txt
writing namespace_packages to
python_Levenshtein.egg-info/namespace_packages.txt
writing requirements to python_Levenshtein.egg-info/requires.txt
writing top-level names to python_Levenshtein.egg-info/top_level.txt
reading manifest file 'python_Levenshtein.egg-info/SOURCES.txt'
reading manifest template 'MANIFEST.in'
warning: no previously-included files matching '*pyc' found anywhere
in distribution
warning: no previously-included files matching '*so' found anywhere in
distribution
warning: no previously-included files matching '.project' found
anywhere in distribution
warning: no previously-included files matching '.pydevproject' found
anywhere in distribution
writing manifest file 'python_Levenshtein.egg-info/SOURCES.txt'
copying Levenshtein/_levenshtein.c ->
build/lib.linux-x86_64-3.8/Levenshtein
copying Levenshtein/_levenshtein.h ->
build/lib.linux-x86_64-3.8/Levenshtein
running build_ext
building 'Levenshtein._levenshtein' extension
creating build/temp.linux-x86_64-3.8
creating build/temp.linux-x86_64-3.8/Levenshtein
x86_64-linux-gnu-gcc -pthread -Wno-unused-result -Wsign-compare
-DNDEBUG -g -fwrapv -O2 -Wall -g -fstack-protector-strong -Wformat
-Werror=format-security -g -fwrapv -O2 -g -fstack-protector-strong -Wformat
-Werror=format-security -Wdate-time -D_FORTIFY_SOURCE=2 -fPIC
-I/home/andy/.cache/pre-commit/repoqtbnjhpl/py_env-python3/include
-I/usr/include/python3.8 -c Levenshtein/_levenshtein.c -o
build/temp.linux-x86_64-3.8/Levenshtein/_levenshtein.o
Levenshtein/_levenshtein.c:99:10: fatal error: Python.h: No such file
or directory
99 | #include <Python.h>
| ^~~~~~~~~~
compilation terminated.
error: command 'x86_64-linux-gnu-gcc' failed with exit status 1
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
For queries about this service, please contact Infrastructure at:
[email protected]