Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Cython errors out with syntax error in Cython file #77

Open
jkempf42 opened this issue Jun 22, 2023 · 0 comments
Open

Cython errors out with syntax error in Cython file #77

jkempf42 opened this issue Jun 22, 2023 · 0 comments

Comments

@jkempf42
Copy link

Please see the below error. I was trying to build a Volttron docker image using the Dockerfile-dev file.

        jak

Step 29/40 : RUN pip install -e . --user
---> Running in 9bb45783b8fc
Obtaining file:///code/volttron
Collecting PyYAML==5.4.1 (from volttron==8.1.3)
Downloading https://files.pythonhosted.org/packages/7a/a5/393c087efdc78091afa2af9f1378762f9821c9c1d7a22c5753fb5ac5f97a/PyYAML-5.4.1-cp37-cp37m-manylinux1_x86_64.whl (636kB)
Collecting cryptography==2.3 (from volttron==8.1.3)
Downloading https://files.pythonhosted.org/packages/c2/fa/fa9a8933c285895935d1392922fe721e9cb1b2c1881d14f149213a227ee3/cryptography-2.3-cp34-abi3-manylinux1_x86_64.whl (2.1MB)
Collecting gevent==20.6.1 (from volttron==8.1.3)
Downloading https://files.pythonhosted.org/packages/9d/a0/42c50f1a021d2404fcad9ac0724fc72de5d084c23fa5447a62f898440802/gevent-20.6.1.tar.gz (5.8MB)
Installing build dependencies: started
Installing build dependencies: finished with status 'done'
Complete output from command python setup.py egg_info:
Compiling src/gevent/resolver/cares.pyx because it changed.
[1/1] Cythonizing src/gevent/resolver/cares.pyx
Compiling src/gevent/libev/corecext.pyx because it changed.
[1/1] Cythonizing src/gevent/libev/corecext.pyx
Compiling src/gevent/_greenlet_primitives.py because it changed.
[1/1] Cythonizing src/gevent/_greenlet_primitives.py
Compiling src/gevent/_hub_primitives.py because it changed.
[1/1] Cythonizing src/gevent/_hub_primitives.py
Compiling src/gevent/_hub_local.py because it changed.
[1/1] Cythonizing src/gevent/_hub_local.py
Compiling src/gevent/_waiter.py because it changed.
[1/1] Cythonizing src/gevent/_waiter.py
warning: src/gevent/resolver/cares.pyx:38:0: The 'DEF' statement is deprecated and will be removed in a future Cython version. Consider using global variables, constants, and in-place literals instead. See cython/cython#4310
warning: src/gevent/resolver/cares.pyx:40:0: The 'DEF' statement is deprecated and will be removed in a future Cython version. Consider using global variables, constants, and in-place literals instead. See cython/cython#4310
warning: src/gevent/resolver/cares.pyx:41:0: The 'DEF' statement is deprecated and will be removed in a future Cython version. Consider using global variables, constants, and in-place literals instead. See cython/cython#4310
warning: src/gevent/libev/corecext.pyx:325:0: The 'DEF' statement is deprecated and will be removed in a future Cython version. Consider using global variables, constants, and in-place literals instead. See cython/cython#4310
warning: src/gevent/libev/corecext.pyx:783:0: The 'DEF' statement is deprecated and will be removed in a future Cython version. Consider using global variables, constants, and in-place literals instead. See cython/cython#4310
warning: src/gevent/libev/corecext.pyx:785:0: The 'DEF' statement is deprecated and will be removed in a future Cython version. Consider using global variables, constants, and in-place literals instead. See cython/cython#4310
warning: src/gevent/libev/corecext.pyx:787:0: The 'DEF' statement is deprecated and will be removed in a future Cython version. Consider using global variables, constants, and in-place literals instead. See cython/cython#4310
warning: src/gevent/libev/corecext.pyx:791:0: The 'DEF' statement is deprecated and will be removed in a future Cython version. Consider using global variables, constants, and in-place literals instead. See cython/cython#4310
warning: src/gevent/_gevent_cgreenlet.pxd:112:33: Declarations should not be declared inline.

Error compiling Cython file:
------------------------------------------------------------
...
cdef load_traceback
cdef Waiter
cdef wait
cdef iwait
cdef reraise
cpdef GEVENT_CONFIG
      ^
------------------------------------------------------------

src/gevent/_gevent_cgreenlet.pxd:181:6: Variables cannot be declared with 'cpdef'. Use 'cdef' instead.
Traceback (most recent call last):
  File "<string>", line 1, in <module>
  File "/tmp/pip-install-ay3ebthy/gevent/setup.py", line 287, in <module>
    EXT_MODULES.append(cythonize1(mod))
  File "/tmp/pip-install-ay3ebthy/gevent/_setuputils.py", line 260, in cythonize1
    common_utility_include_dir=COMMON_UTILITY_INCLUDE_DIR,
  File "/tmp/pip-build-env-cxr67hol/lib/python3.7/site-packages/Cython/Build/Dependencies.py", line 1134, in cythonize
    cythonize_one(*args)
  File "/tmp/pip-build-env-cxr67hol/lib/python3.7/site-packages/Cython/Build/Dependencies.py", line 1301, in cythonize_one
    raise CompileError(None, pyx_file)
Cython.Compiler.Errors.CompileError: src/gevent/greenlet.py
Compiling src/gevent/greenlet.py because it changed.
[1/1] Cythonizing src/gevent/greenlet.py

----------------------------------------

Command "python setup.py egg_info" failed with error code 1 in /tmp/pip-install-ay3ebthy/gevent/
The command 'bash -c pip install -e . --user' returned a non-zero code: 1

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant