decimal.getcontext
crashes with --with-decimal-contextvar=no
and -X showrefcount
#123657
Labels
3.13
bugs and security fixes
3.14
bugs and security fixes
extension-modules
C modules in the Modules dir
type-crash
A hard crash of the interpreter, possibly with a core dump
Uh oh!
There was an error while loading. Please reload this page.
Crash report
What happened?
cc @godlygeek, who helped me find this
I was investigating a reference leak on the asyncio test suite, and I came across
decimal.getcontext
leaking some memory. Here's what I was doing:This is a problem in itself, since this is a leak, but after configuring with
--with-decimal-contextvar=no
, then the above code fails with a negative reference count:It seems both of these problems were caused by #123244
(@encukou, this needs
extension-modules
,3.14
and3.13
)CPython versions tested on:
CPython main branch
Operating systems tested on:
Linux
Output from running 'python -VV' on the command line:
No response
Linked PRs
decimal.getcontext()
#123703decimal.getcontext()
(GH-123703) #123774The text was updated successfully, but these errors were encountered: