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
{{ message }}
Repository navigation
Commit 72165f3
Browse filesBrowse the repository at this point in the historyBrowse files
gh-159879: Do not limit the C stack below what the interpreter assumes
On AIX, NetBSD and non-glibc Linux, hardware_stack_limits() cannot query
the stack of the running thread and the interpreter assumes
Py_C_STACK_SIZE instead. A test thread created with less than that
overflows its stack before the recursion guard notices, so the test
crashes instead of getting RecursionError.
run_with_limited_c_stack() now probes once whether the real size is
visible -- two threads of different sizes report the same headroom only
if the fixed estimate is in use -- and raises a too-small *size* to
C_STACK_SIZE when it is not.
Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
0 commit comments