aasensio / hazel

Hazel: synthesis and inversion of Stokes profiles
MIT License
7 stars 5 forks source link

issues with the python wrapper #20

Closed mariaritamurabito closed 3 years ago

mariaritamurabito commented 3 years ago

Hi guys,

I'm installing the code, and when I run python setup.py build_ext --inplace

I obtain these errors:

pyhazel.c: In function ‘PyxExceptionSave’: pyhazel.c:6953:21: error: ‘PyThreadState’ {aka ‘struct _ts’} has no member named ‘exc_type’; did you mean ‘curexc_type’? 6953 | type = tstate->exc_type; | ^~~~ | curexc_type pyhazel.c:6954:22: error: ‘PyThreadState’ {aka ‘struct _ts’} has no member named ‘exc_value’; did you mean ‘curexc_value’? 6954 | value = tstate->exc_value; | ^~~~~ | curexc_value pyhazel.c:6955:19: error: ‘PyThreadState’ {aka ‘struct _ts’} has no member named ‘exc_traceback’; did you mean ‘curexc_traceback’? 6955 | *tb = tstate->exc_traceback; | ^~~~~ | curexc_traceback pyhazel.c: In function ‘PyxExceptionReset’: pyhazel.c:6962:24: error: ‘PyThreadState’ {aka ‘struct _ts’} has no member named ‘exc_type’; did you mean ‘curexc_type’? 6962 | tmp_type = tstate->exc_type; | ^~~~ | curexc_type pyhazel.c:6963:25: error: ‘PyThreadState’ {aka ‘struct _ts’} has no member named ‘exc_value’; did you mean ‘curexc_value’? 6963 | tmp_value = tstate->exc_value; | ^~~~~ | curexc_value pyhazel.c:6964:22: error: ‘PyThreadState’ {aka ‘struct _ts’} has no member named ‘exc_traceback’; did you mean ‘curexc_traceback’? 6964 | tmp_tb = tstate->exc_traceback; | ^~~~~ | curexc_traceback pyhazel.c:6965:13: error: ‘PyThreadState’ {aka ‘struct _ts’} has no member named ‘exc_type’; did you mean ‘curexc_type’? 6965 | tstate->exc_type = type; | ^~~~ | curexc_type pyhazel.c:6966:13: error: ‘PyThreadState’ {aka ‘struct _ts’} has no member named ‘exc_value’; did you mean ‘curexc_value’? 6966 | tstate->exc_value = value; | ^~~~~ | curexc_value pyhazel.c:6967:13: error: ‘PyThreadState’ {aka ‘struct _ts’} has no member named ‘exc_traceback’; did you mean ‘curexc_traceback’? 6967 | tstate->exc_traceback = tb; | ^~~~~ | curexc_traceback pyhazel.c: In function ‘PyxGetException’: pyhazel.c:7037:24: error: ‘PyThreadState’ {aka ‘struct _ts’} has no member named ‘exc_type’; did you mean ‘curexc_type’? 7037 | tmp_type = tstate->exc_type; | ^~~~ | curexc_type pyhazel.c:7038:25: error: ‘PyThreadState’ {aka ‘struct _ts’} has no member named ‘exc_value’; did you mean ‘curexc_value’? 7038 | tmp_value = tstate->exc_value; | ^~~~~ | curexc_value pyhazel.c:7039:22: error: ‘PyThreadState’ {aka ‘struct _ts’} has no member named ‘exc_traceback’; did you mean ‘curexc_traceback’? 7039 | tmp_tb = tstate->exc_traceback; | ^~~~~ | curexc_traceback pyhazel.c:7040:13: error: ‘PyThreadState’ {aka ‘struct _ts’} has no member named ‘exc_type’; did you mean ‘curexc_type’? 7040 | tstate->exc_type = local_type; | ^~~~ | curexc_type pyhazel.c:7041:13: error: ‘PyThreadState’ {aka ‘struct _ts’} has no member named ‘exc_value’; did you mean ‘curexc_value’? 7041 | tstate->exc_value = local_value; | ^~~~~ | curexc_value pyhazel.c:7042:13: error: ‘PyThreadState’ {aka ‘struct _ts’} has no member named ‘exc_traceback’; did you mean ‘curexc_traceback’? 7042 | tstate->exc_traceback = local_tb; | ^~~~~ | curexc_traceback error: command 'gcc' failed with exit status 1

Does someone have any idea on how to solve it? Googling, I saw that maybe this error could be linked to Cython modules. I had Cython 0.29 and I updated to a Cython version 3.0a6 with a 3.8.5 python version Thanks, Mariarita

aasensio commented 3 years ago

Hi Mariarita. This version of hazel is not maintained anymore. Please, go to https://github.com/aasensio/hazel2 and use that one. The docs explain how to have it installed but I can help in any issue you might have.