Thonny+Python bundle is supported on macOS 10.11 and later (it may also work on 10.9 and 10.10, but this is not tested). On older systems you can install Python and Thonny separately.
(Version 2.1.21 can be used on macOS 10.6 and later)
Download the latest pkg-file on https://thonny.org/, launch it and follow the instructions.
Just Ctrl-click (or right-click) the Thonny icon on your Desktop or Applications folder and select "Move to Trash".
- Right-click on a file with the
.py
extension. - Choose
Get Info
. - Under
Open with:
selectThonny
in the drop-down. - Click the
Change All...
button. - Click the
Continue
button when it asksAre you sure you want to change all similar documents to open with the application “Thonny”?
macOS 10.15 Catalina changed how apps are given permissions for accessing certain folders. If you used Thonny in a previous macOS version and upgraded to Catalina, Thonny may stop working with following message in the shell:
shell-init: error retrieving current directory: getcwd: cannot access parent directories: Operation not permitted Backend terminated or disconnected. Use 'Stop/Restart' to restart ...
If this happens, then you may be able to fix it by reinstalling Thonny using a .pkg. NB! When Thonny starts up it may ask for permissions to your Desktop, Documents or other special folders you have stored your scripts in -- make sure you grant the permission!
Another solution is making Thonny save a new Python file to (or open a file from) the directory you were using last time before upgrading to Catalina -- usually this is the first directory shown when you open the file selection dialog with "File => Open" or "File => Save as". Restart Thonny after this. Now Thonny should have gained proper permissions for corresponding directory.
If this doesn't help, then you can try opening Thonny from Terminal or deleting its configuration file ~/Library/Thonny/configuration.ini
(close Thonny first).