You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
To reproduce, create a venv on python3.12 with the current requirements in build_requirements and test_requirements, then:
spin build --clean -- -Dbuildtype=debug
spin test
On ubuntu 24.04, x86_64, I get a segfault in test_dict_recursion, which is meant to fail with a RecursionError. The other similar tests for recursion properly raise the RecursionError. Setting sys.setrecursionlimit(100) (where it usually is 1000) does not cause the RecursionError to be raised. Is the recursion detection somehow different for dtype-from-dict than for dtype-from-list or dtype-from-tuple?
This is the only test that fails for me when using a debug build.
The text was updated successfully, but these errors were encountered:
Probably missing a Py_EnterRecursiveCall, Py_LeaveRecursiveCall pair somewhere in the dtype-from-dict path, where the others call out to a python API that will check the stack depth without an explicit Py_EnterRecursiveCall
There are calls to Py_EnterRecursiveCall/Py_LeaveRecursiveCall. It seems the function _convert_from_dict is particularly stack-heavy. On my machine, the default stack size in bash is 8192. Setting it larger with ulimit -s 10240 cleared the segfault. If others see this too, maybe it is worth documenting in spin build --help? Closing for now.
To reproduce, create a venv on python3.12 with the current requirements in build_requirements and test_requirements, then:
On ubuntu 24.04, x86_64, I get a segfault in test_dict_recursion, which is meant to fail with a
RecursionError
. The other similar tests for recursion properly raise theRecursionError
. Settingsys.setrecursionlimit(100)
(where it usually is 1000) does not cause theRecursionError
to be raised. Is the recursion detection somehow different for dtype-from-dict than for dtype-from-list or dtype-from-tuple?This is the only test that fails for me when using a debug build.
The text was updated successfully, but these errors were encountered: