Thanks to visit codestin.com
Credit goes to github.com

Skip to content

Unrecoverable stack overflow with infinite recursion on macOS #131543

Open
@tomMoral

Description

@tomMoral

Crash report

What happened?

Hello,

In the CI of cloudpickle, we encountered a crash of the python interpreter due to a stack overflow with python3.14.0a6.
Reverting to python3.14.0a5 fixes the error.

This might be related to GH-130398, with a bad detection of the limit of the stack?
I could not test it locally as I don't own a mac.

class A:
    def __getattribute__(self, name):
        return getattr(self, name)


a = A()
print("Testing Recursion Limit")
try:
    a.test
except RecursionError:
    print("Recursion Limit ok")

Output with python3.14.0a5:

Testing Recursion Limit
Recursion Limit ok

Output with python3.14.0a6:

Fatal Python error: _Py_CheckRecursiveCall: Unrecoverable stack overflow (used 3923 kB)
Python runtime state: initialized

Current thread 0x00000001f839cf80 (most recent call first):
  File "/Users/runner/work/cloudpickle/cloudpickle/test_recursion_error.py", line 3 in __getattribute__
  File "/Users/runner/work/cloudpickle/cloudpickle/test_recursion_error.py", line 3 in __getattribute__
  File "/Users/runner/work/cloudpickle/cloudpickle/test_recursion_error.py", line 3 in __getattribute__
....

CPython versions tested on:

3.14

Operating systems tested on:

macOS

Output from running 'python -VV' on the command line:

No response

Metadata

Metadata

Assignees

No one assigned

    Labels

    OS-macinterpreter-core(Objects, Python, Grammar, and Parser dirs)type-crashA hard crash of the interpreter, possibly with a core dump

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions