Victor Milovanov added the comment:
I think documentation should clarify that. Right now this line in the docs got
me thinking that anything with an external strong reference won't be
deallocated: "Memory tied up in circular references between objects is not
freed."
--
New submission from Victor Milovanov :
Trying to Py_DecRef owned reference to builtin "iter" crashes if the reference
was alive when runtime was reinitialized.
Py_Initialize();
PyObject* builtins = PyEval_GetBuiltins();
PyObject* iter = PyDict_GetItemString(builtins, "iter&quo
Victor Milovanov added the comment:
To put it differently, if you think in terms of MRO, my custom type's MRO is
my_type_clear (from my type), subtype_clear (from PyTypeObject), etc
And subtype_clear incorrectly assumes that it is the first entry in the
object's MRO list fo
New submission from Victor Milovanov :
I am trying to define a type in C, that derives from PyTypeObject.
I want to override tp_clear. To do so properly, I should call base type's
tp_clear and have it perform its cleanup steps. PyTypeObject has a tp_clear
implementation: subtype_
Victor Milovanov added the comment:
There's a patch attached to this bug. Why is its stage "needs patch"?
------
nosy: +Victor Milovanov
___
Python tracker
<https://bugs.pyt
Victor Milovanov added the comment:
A bit more information: pool->freeblock for the broken pool looks like this:
0xXYZ?
while pool itself looks like this:
0x??XYZ000
--
___
Python tracker
<https://bugs.python.org/issu
Victor Milovanov added the comment:
In my case it always happens in pymalloc_alloc when size == 5, e.g. when
accessing usedpools[10].
Specifically freeblock pointer in usedpools[10] is wy off (essentially,
seemingly random number looking like 0xX000) where it is supposed to be
(e.g
Victor Milovanov added the comment:
This reproduces stably for me when running unit tests in Python.NET project at
commit 5e276d9.
--
nosy: +Victor Milovanov
___
Python tracker
<https://bugs.python.org/issue35