Message363197
After some thought, I'm sure the diagnosis is correct: the weakref list must be made invisible to gc. That is, simply don't traverse it at all. The crash is exactly what's expected from traversing objects a container doesn't own references to.
I agree the tp_traverse docs should point out that weakref lists are special this way, but I think the problem is unique to them - can't think of another case where a container points to an object it doesn't own a reference to. |
|
Date |
User |
Action |
Args |
2020-03-02 19:04:46 | tim.peters | set | recipients:
+ tim.peters, rhettinger, pitrou, vstinner, eric.snow, leezu, pablogsal |
2020-03-02 19:04:46 | tim.peters | set | messageid: <1583175886.35.0.839534042022.issue39778@roundup.psfhosted.org> |
2020-03-02 19:04:46 | tim.peters | link | issue39778 messages |
2020-03-02 19:04:46 | tim.peters | create | |
|