Skip to content

cannot build spacy from source: cythonize failed #455

@slonik-az

Description

@slonik-az

I am trying to build spacy 0.101.0 (or git master) using latest stable cython-0.24
$ python setup.py build_ext -i -f

It results in cython error during the "cythonizing" stage of file spacy/gold.cyx:

Error compiling Cython file:

...
cdef dict __Pyx_globals = globals()
if PY_VERSION_HEX >= 0x03040000:

^

EnumType:51:18: undeclared name not builtin: PY_VERSION_HEX
Traceback (most recent call last):
File "/opt/anaconda2/bin/cython", line 6, in
sys.exit(Cython.Compiler.Main.setuptools_main())
File "/opt/anaconda2/lib/python2.7/site-packages/Cython/Compiler/Main.py", line 692, in setuptools_main
return main(command_line = 1)
File "/opt/anaconda2/lib/python2.7/site-packages/Cython/Compiler/Main.py", line 709, in main
result = compile(sources, options)
.................
Exception: Cython failed
Cythonizing sources
Traceback (most recent call last):
File "setup.py", line 225, in
setup_package()
File "setup.py", line 178, in setup_package
generate_cython(root, 'spacy')
File "setup.py", line 120, in generate_cython
raise RuntimeError('Running cythonize failed')
RuntimeError: Running cythonize failed

Thanks,
--Leo

P.S. complete traceback is attached below.
setup_build_ext-log.txt

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions