-
-
Notifications
You must be signed in to change notification settings - Fork 32.5k
Closed
Labels
3.11only security fixesonly security fixes3.12only security fixesonly security fixes3.13bugs and security fixesbugs and security fixesinterpreter-core(Objects, Python, Grammar, and Parser dirs)(Objects, Python, Grammar, and Parser dirs)triagedThe issue has been accepted as valid by a triager.The issue has been accepted as valid by a triager.type-crashA hard crash of the interpreter, possibly with a core dumpA hard crash of the interpreter, possibly with a core dump
Description
When specializing some Python calls, we assert that we don't have more defaults than we have arguments. This isn't always true, though:
>>> def f():
... pass
...
>>> f.__defaults__ = (None,)
>>> for _ in range(2):
... f()
...
python: Python/specialize.c:1650: specialize_py_call: Assertion `defcount <= argcount' failed.
Aborted
Linked PRs
- GH-105840: Fix assertion failures when specializing calls with too many
__defaults__
#105847 - [3.12] GH-105840: Fix assertion failures when specializing calls with too many __defaults__ (GH-105847) #105863
- [3.11] GH-105840: Fix assertion failures when specializing calls with too many __defaults__ (GH-105847) #105864
Metadata
Metadata
Assignees
Labels
3.11only security fixesonly security fixes3.12only security fixesonly security fixes3.13bugs and security fixesbugs and security fixesinterpreter-core(Objects, Python, Grammar, and Parser dirs)(Objects, Python, Grammar, and Parser dirs)triagedThe issue has been accepted as valid by a triager.The issue has been accepted as valid by a triager.type-crashA hard crash of the interpreter, possibly with a core dumpA hard crash of the interpreter, possibly with a core dump