`pip install` fails with Python 3.7
See original GitHub issueDescription
Unable to pip install
with Python 3.7: error: no member named 'exc_type' in 'struct _ts'
Installing from devel-branch at HEAD also fails.
It seems like this is an Cython related issue (cython/cython#1978). There have been similar issues with pyyaml (yaml/pyyaml#126), numpy (numpy/numpy#10500), pygame (pygame/pygame#382) and scikit-learn (scikit-learn/scikit-learn#11320)
Steps/Code to Reproduce
Install Python 3.7
pip install gpy
Expected Results
pip succeeds.
Actual Results
GPy/kern/src/stationary_cython.c:19389:21: error: no member named 'exc_type' in 'struct _ts'
*type = tstate->exc_type;
~~~~~~ ^
GPy/kern/src/stationary_cython.c:19390:22: error: no member named 'exc_value' in 'struct _ts'; did you mean 'curexc_value'?
*value = tstate->exc_value;
^~~~~~~~~
curexc_value
/usr/local/Cellar/python/3.7.0/Frameworks/Python.framework/Versions/3.7/include/python3.7m/pystate.h:237:15: note: 'curexc_value' declared here
PyObject *curexc_value;
^
GPy/kern/src/stationary_cython.c:19391:19: error: no member named 'exc_traceback' in 'struct _ts'; did you mean 'curexc_traceback'?
*tb = tstate->exc_traceback;
^~~~~~~~~~~~~
curexc_traceback
/usr/local/Cellar/python/3.7.0/Frameworks/Python.framework/Versions/3.7/include/python3.7m/pystate.h:238:15: note: 'curexc_traceback' declared here
PyObject *curexc_traceback;
^
GPy/kern/src/stationary_cython.c:19403:24: error: no member named 'exc_type' in 'struct _ts'
tmp_type = tstate->exc_type;
~~~~~~ ^
GPy/kern/src/stationary_cython.c:19404:25: error: no member named 'exc_value' in 'struct _ts'; did you mean 'curexc_value'?
tmp_value = tstate->exc_value;
^~~~~~~~~
curexc_value
/usr/local/Cellar/python/3.7.0/Frameworks/Python.framework/Versions/3.7/include/python3.7m/pystate.h:237:15: note: 'curexc_value' declared here
PyObject *curexc_value;
^
GPy/kern/src/stationary_cython.c:19405:22: error: no member named 'exc_traceback' in 'struct _ts'; did you mean 'curexc_traceback'?
tmp_tb = tstate->exc_traceback;
^~~~~~~~~~~~~
curexc_traceback
/usr/local/Cellar/python/3.7.0/Frameworks/Python.framework/Versions/3.7/include/python3.7m/pystate.h:238:15: note: 'curexc_traceback' declared here
PyObject *curexc_traceback;
^
GPy/kern/src/stationary_cython.c:19406:13: error: no member named 'exc_type' in 'struct _ts'
tstate->exc_type = type;
~~~~~~ ^
GPy/kern/src/stationary_cython.c:19407:13: error: no member named 'exc_value' in 'struct _ts'; did you mean 'curexc_value'?
tstate->exc_value = value;
^~~~~~~~~
curexc_value
/usr/local/Cellar/python/3.7.0/Frameworks/Python.framework/Versions/3.7/include/python3.7m/pystate.h:237:15: note: 'curexc_value' declared here
PyObject *curexc_value;
^
GPy/kern/src/stationary_cython.c:19408:13: error: no member named 'exc_traceback' in 'struct _ts'; did you mean 'curexc_traceback'?
tstate->exc_traceback = tb;
^~~~~~~~~~~~~
curexc_traceback
/usr/local/Cellar/python/3.7.0/Frameworks/Python.framework/Versions/3.7/include/python3.7m/pystate.h:238:15: note: 'curexc_traceback' declared here
PyObject *curexc_traceback;
^
GPy/kern/src/stationary_cython.c:19451:24: error: no member named 'exc_type' in 'struct _ts'
tmp_type = tstate->exc_type;
~~~~~~ ^
GPy/kern/src/stationary_cython.c:19452:25: error: no member named 'exc_value' in 'struct _ts'; did you mean 'curexc_value'?
tmp_value = tstate->exc_value;
^~~~~~~~~
curexc_value
/usr/local/Cellar/python/3.7.0/Frameworks/Python.framework/Versions/3.7/include/python3.7m/pystate.h:237:15: note: 'curexc_value' declared here
PyObject *curexc_value;
^
GPy/kern/src/stationary_cython.c:19453:22: error: no member named 'exc_traceback' in 'struct _ts'; did you mean 'curexc_traceback'?
tmp_tb = tstate->exc_traceback;
^~~~~~~~~~~~~
curexc_traceback
/usr/local/Cellar/python/3.7.0/Frameworks/Python.framework/Versions/3.7/include/python3.7m/pystate.h:238:15: note: 'curexc_traceback' declared here
PyObject *curexc_traceback;
^
GPy/kern/src/stationary_cython.c:19454:13: error: no member named 'exc_type' in 'struct _ts'
tstate->exc_type = local_type;
~~~~~~ ^
GPy/kern/src/stationary_cython.c:19455:13: error: no member named 'exc_value' in 'struct _ts'; did you mean 'curexc_value'?
tstate->exc_value = local_value;
^~~~~~~~~
curexc_value
/usr/local/Cellar/python/3.7.0/Frameworks/Python.framework/Versions/3.7/include/python3.7m/pystate.h:237:15: note: 'curexc_value' declared here
PyObject *curexc_value;
^
GPy/kern/src/stationary_cython.c:19456:13: error: no member named 'exc_traceback' in 'struct _ts'; did you mean 'curexc_traceback'?
tstate->exc_traceback = local_tb;
^~~~~~~~~~~~~
curexc_traceback
/usr/local/Cellar/python/3.7.0/Frameworks/Python.framework/Versions/3.7/include/python3.7m/pystate.h:238:15: note: 'curexc_traceback' declared here
PyObject *curexc_traceback;
^
GPy/kern/src/stationary_cython.c:19478:24: error: no member named 'exc_type' in 'struct _ts'
tmp_type = tstate->exc_type;
~~~~~~ ^
GPy/kern/src/stationary_cython.c:19479:25: error: no member named 'exc_value' in 'struct _ts'; did you mean 'curexc_value'?
tmp_value = tstate->exc_value;
^~~~~~~~~
curexc_value
/usr/local/Cellar/python/3.7.0/Frameworks/Python.framework/Versions/3.7/include/python3.7m/pystate.h:237:15: note: 'curexc_value' declared here
PyObject *curexc_value;
^
GPy/kern/src/stationary_cython.c:19480:22: error: no member named 'exc_traceback' in 'struct _ts'; did you mean 'curexc_traceback'?
tmp_tb = tstate->exc_traceback;
^~~~~~~~~~~~~
curexc_traceback
/usr/local/Cellar/python/3.7.0/Frameworks/Python.framework/Versions/3.7/include/python3.7m/pystate.h:238:15: note: 'curexc_traceback' declared here
PyObject *curexc_traceback;
^
GPy/kern/src/stationary_cython.c:19481:13: error: no member named 'exc_type' in 'struct _ts'
tstate->exc_type = *type;
~~~~~~ ^
fatal error: too many errors emitted, stopping now [-ferror-limit=]
10 warnings and 20 errors generated.
error: command 'clang' failed with exit status 1
----------------------------------------
Failed building wheel for GPy
Installed versions
python: 3.7.0.final.0 python-bits: 64 OS: Darwin OS-release: 17.6.0 machine: x86_64 processor: i386 byteorder: little LC_ALL: en_US.UTF-8 LANG: en_US.UTF-8 LOCALE: en_US.UTF-8
pip: 10.0.1 setuptools: 39.2.0 Cython: 0.28.3 numpy: 1.14.5 scipy: 1.1.0
Issue Analytics
- State:
- Created 5 years ago
- Reactions:15
- Comments:24 (4 by maintainers)
Top Results From Across the Web
Installation fails with pip and from source in Python 3.7 #76
I just tried to pip-install causalml in a conda environment on macOS Mojave without Cython and it went through without an error -...
Read more >Pip is not installed with python 3.7.3 even i did selected it on ...
Go to properties of my computer -> Advance system settings -> new -> give vairable name as Path and variable value as the...
Read more >Install Python, pip, and the EB CLI on Linux
Install Python, pip, and the EB CLI on Linux. ... If Python 2.7 or later isn't installed, install Python 3.7 using your distribution's...
Read more >Installing scikit-learn
Install the version of scikit-learn provided by your operating system or Python distribution. This is a quick option for those who have operating...
Read more >Pip install not to site-packages directory - Python Help
I have installed Python 3.7.5 on MacOS 10.14.6 from brew (brew install python). brew info python shows: You can install Python packages with ......
Read more >Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start FreeTop Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Top GitHub Comments
This is an issue with the package maintainers who include the precompiled
*.c
files instead of runningcython
over*.pyx
. Here is a workaround:Just a reminder to everyone that this issue still exists…