From d44a0af6594cfc0b3c3d0d7739e8eb9c8b71dc85 Mon Sep 17 00:00:00 2001 From: Stuart Taylor Date: Tue, 14 Oct 2025 12:59:42 -0500 Subject: [PATCH] Allow *.pyx files as source files *.pyx files are cython files so it makes sense for them to be included in the source files --- sacred/dependencies.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/sacred/dependencies.py b/sacred/dependencies.py index efd0afb3..8470c048 100644 --- a/sacred/dependencies.py +++ b/sacred/dependencies.py @@ -377,7 +377,7 @@ def get_py_file_if_possible(pyc_name): """Try to retrieve a X.py file for a given X.py[c] file.""" - if pyc_name.endswith((".py", ".so", ".pyd", ".ipynb")): + if pyc_name.endswith((".py", ".so", ".pyd", ".ipynb", ".pyx")): return pyc_name assert pyc_name.endswith(".pyc") non_compiled_file = pyc_name[:-1]