This issue tracker has been migrated to GitHub, and is currently read-only.
For more information, see the GitHub FAQs in the Python's Developer Guide.

Author ned.deily
Recipients ned.deily, remi_bertholet, xtreak
Date 2018-11-10.17:15:29
SpamBayes Score -1.0
Marked as misclassified Yes
Message-id <1541870129.53.0.788709270274.issue35209@psf.upfronthosting.co.za>
In-reply-to
Content
Thanks for the report and for the investigation. The Tk crash described in Issue32481 (and many other earlier issues) is due to a very old bug in Tk 8.5.x for macOS.  While this bug has been fixed in more recent versions of 8.5.x and in 8.6.x, the version of Tk shipped by Apple with macOS has not been updated since Mac OS X 10.7 (!) and so apps that use it will see this crash.  Which Tk a particular instance of Python tkinter will link with depends on how that Python was built.  In general, there are ways to check which one is in use.  The easiest is, when the app is running, go to the macOS menu bar, select the app name (the second menu row which, for standalone Python scripts will likely be labeled "Python"), then choose the first menu item under it, the "About <app name>" item.  Unless the app itself has defined its own About menu (like IDLE.app does) that should bring up a Tk app window that says what version of Tk is running.  (The IDLE.app About window also says what version of Tk is in use.)  If the version is 8.5.9, the app is most likely using the buggy system Tk.  It's also possible for the Python program to get the Tk version in-use at runtime; see tkVersionWarning in IDLE for an example:

https://github.com/python/cpython/blob/v3.7.1/Lib/idlelib/macosx.py#L69

An even more definite confirmation is to examine the macOS crash report produced (either on screen or saved at ~/Library/Logs/DiagnosticReports and browsable with Console.app).  Search the Binary Images section for the specific Tk file name in use.  If the line found has Tk (8.5.9 - 8.5.9) and /System/Library/Frameworks/Tk.framework/Versions/8.5/Tk in it, you know that the culprit is the Apple-supplied Tk.  If the file name is something else, like /Library/Frameworks/Tk.framework/Versions/8.5/Tk, then the system Tk is not to blame.


There is more info here:
https://www.python.org/download/mac/tcltk/
History
Date User Action Args
2018-11-10 17:15:29ned.deilysetrecipients: + ned.deily, xtreak, remi_bertholet
2018-11-10 17:15:29ned.deilysetmessageid: <1541870129.53.0.788709270274.issue35209@psf.upfronthosting.co.za>
2018-11-10 17:15:29ned.deilylinkissue35209 messages
2018-11-10 17:15:29ned.deilycreate