Skip to content

Commit

Permalink
Include cythonize in pyximporter warning ignore block (since it attem…
Browse files Browse the repository at this point in the history
…pts a failed import for pythran).
  • Loading branch information
hodgestar committed Feb 24, 2022
1 parent 276385a commit 4404d65
Showing 1 changed file with 5 additions and 5 deletions.
10 changes: 5 additions & 5 deletions qutip/core/coefficient.py
Original file line number Diff line number Diff line change
Expand Up @@ -499,12 +499,12 @@ def compile_code(code, file_name, parsed, c_opt):
compile_time_env = {
"QUTIP_IDXINT_64": idxint_dtype is np.int64,
}
ext_modules = cythonize(
coeff_file,
compile_time_env=compile_time_env,
force=c_opt['recompile'],
)
with _ignore_import_warning_for_pyximporter():
ext_modules = cythonize(
coeff_file,
compile_time_env=compile_time_env,
force=c_opt['recompile'],
)
setup(ext_modules=ext_modules)
except Exception as e:
raise Exception("Could not compile") from e
Expand Down

0 comments on commit 4404d65

Please sign in to comment.