[New-bugs-announce] [issue18141] tkinter.Image.__del__ can throw an exception if module globals are destroyed in the wrong order

Jan Kanis report at bugs.python.org
Wed Jun 5 14:09:36 CEST 2013


New submission from Jan Kanis:

While fixing #18132 I noticed that when closing the turtledemo window an exception is thrown (and ignored) because the __del__ tries to catch a TclError exception, but the TclError global has already been deleted and set to None. 

I could only reproduce this in my self built pydebug build, at least on revision dfcb64f51f7b, but not on the v3.3.2 tag. (compiled with --with-pydebug on linux x86-64)


traceback:

me at mymachine ~/d/cpython> ./python -m turtledemo
BYE!
Exception ignored in: <bound method PhotoImage.__del__ of <tkinter.PhotoImage object at 0x7fbddb4f0a18>>
Traceback (most recent call last):
  File "~/devel/cpython/Lib/tkinter/__init__.py", line 3330, in __del__
TypeError: catching classes that do not inherit from BaseException is not allowed

----------
components: Tkinter
messages: 190654
nosy: JanKanis
priority: normal
severity: normal
status: open
title: tkinter.Image.__del__ can throw an exception if module globals are destroyed in the wrong order
versions: Python 3.4

_______________________________________
Python tracker <report at bugs.python.org>
<http://bugs.python.org/issue18141>
_______________________________________


More information about the New-bugs-announce mailing list