Terry J. Reedy added the comment:
I re-read turtledemo and it seems that is could exit without calling
root.destroy. The 'if main' block follows:
demo = DemoWindow()
RUN = True
while RUN:
try:
#print("ENTERING mainloop")
demo.root.mainloop()
except AttributeError: <swallow and continue, for debug?>
except TypeError: <swallow and continue, for debug?>
except:
print("BYE!")
RUN = False
If a non-Attribute/Type/Error occurs, it is swallowed and the process shuts
down without root.destroy, which depends on closing the root window. It seems
to me that for production use, everything after the first line should be
replaced by demo.root.mainloop(), as is standard for tkinter apps, so that if
*any* exception occurs, the process stops and a proper traceback gets printed
(before shutdown).
----------
_______________________________________
Python tracker <[email protected]>
<http://bugs.python.org/issue18141>
_______________________________________
_______________________________________________
Python-bugs-list mailing list
Unsubscribe:
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com