[issue5437] Singleton MemoryError can hold traceback data and locals indefinitely

2010-10-28 Thread Antoine Pitrou
Antoine Pitrou added the comment: Patch with improved tests committed in r85896 (3.2) and r85898 (3.1). -- resolution: -> fixed stage: patch review -> committed/rejected status: open -> closed ___ Python tracker _

[issue5437] Singleton MemoryError can hold traceback data and locals indefinitely

2010-10-28 Thread Antoine Pitrou
Antoine Pitrou added the comment: I can't manage to reproduce the issue with PyExc_RecursionErrorInst. It seems this instance is only used in a very select condition, that is, when the recursion limit is hit when trying to "normalize" an exception. Therefore, I will add a test without "fixing

[issue5437] Singleton MemoryError can hold traceback data and locals indefinitely

2010-10-28 Thread Antoine Pitrou
Antoine Pitrou added the comment: Updated patch against py3k. -- Added file: http://bugs.python.org/file19403/memerror.patch ___ Python tracker ___ __

[issue5437] Singleton MemoryError can hold traceback data and locals indefinitely

2010-07-29 Thread Mark Lawrence
Mark Lawrence added the comment: Changing priority as nobody appears to have lost any sleep over this issue. -- priority: high -> normal ___ Python tracker ___ __

[issue5437] Singleton MemoryError can hold traceback data and locals indefinitely

2010-07-14 Thread Mark Lawrence
Mark Lawrence added the comment: Would someone please check out thie patch, it's mostly changes to C code that I'm not qualified to comment on. -- nosy: +BreamoreBoy ___ Python tracker

[issue5437] Singleton MemoryError can hold traceback data and locals indefinitely

2009-10-29 Thread Antoine Pitrou
Changes by Antoine Pitrou : -- stage: needs patch -> patch review ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe:

[issue5437] Singleton MemoryError can hold traceback data and locals indefinitely

2009-10-29 Thread Antoine Pitrou
Changes by Antoine Pitrou : Removed file: http://bugs.python.org/file13262/issue5437.patch ___ Python tracker ___ ___ Python-bugs-list mailing

[issue5437] Singleton MemoryError can hold traceback data and locals indefinitely

2009-10-29 Thread Antoine Pitrou
Antoine Pitrou added the comment: Here is a patch preallocating a freelist of MemoryErrors. To Alexandre: yes, PyExc_RecursionErrorInst probably has the same problem. -- versions: +Python 3.2 -Python 3.0 Added file: http://bugs.python.org/file15230/memerror.patch _

[issue5437] Singleton MemoryError can hold traceback data and locals indefinitely

2009-06-09 Thread Alexandre Vassalotti
Alexandre Vassalotti added the comment: Honestly, I don't think it is a big issue. MemoryErrors are rare and typically cause the interpreter to shutdown. By the way, do you think the static PyExc_RecursionErrorInst object is affected by this bug? -- nosy: +alexandre.vassalotti ___

[issue5437] Singleton MemoryError can hold traceback data and locals indefinitely

2009-03-07 Thread Antoine Pitrou
Antoine Pitrou added the comment: A proper fix would probably be to maintain a bunch of preallocated instances in a freelist rather than relying on an explicit singleton. It would enforce proper dereferencing and garbage collection semantics. ___ Python track

[issue5437] Singleton MemoryError can hold traceback data and locals indefinitely

2009-03-07 Thread Antoine Pitrou
Antoine Pitrou added the comment: The following patch fixes the case when the exception is discarded in Python, but not when e.g. PyErr_Clear() is used from C code. -- keywords: +patch Added file: http://bugs.python.org/file13262/issue5437.patch ___

[issue5437] Singleton MemoryError can hold traceback data and locals indefinitely

2009-03-07 Thread Antoine Pitrou
New submission from Antoine Pitrou : The PyExc_MemoryErrorInst object is persistent and its members never get cleared. This means any local variable which gets caught in the traceback isn't deallocated until the next MemoryError (!). Sample script demonstrates this. (this doesn't seem to affect