CS 231: Algorithmic Problem Solving

Setting up Python and Wing 101 at Local

Instructions for Mac Users

If you are using a Windows operating systerm, click: here.

If you are using a Linux operating systerm, click: here.

0 Click on the apple logo on the top left corner, then About This Mac to check the version of your operating system. The current version is only compatible with OS X / macOS 10.13+. Please update your mac if you are using a system older than 10.13, to make sure you can use Wing 101 IDE.

About this mac steps About this mac
1 Go to the Python Download page, which is located at Python 3.12.9 Download Page.You should see the following on the bottom of the page.

Python Website

Click on the links that for your operating system. It should immediately start a download of Python. If you are redirected to another page, scroll all the way to the bottom and choose the download option that matches your Mac version.

2 Double click the file you have downloaded to install Python 3.12.9. It should open up an installation window like this one:.

Python Installer

You can follow the default settings for the installation.

3 You will now be guided through the Wing 101 installtion process. Wing 101 is an Integrated Development Environment (IDE) like Dr. Racket. It allows you to write and run code in one program. Go to the Wing IDE download page, which is located at Wing 101 Download. Make sure that the top of the page says Wing 101 as this is the free version of Wing.

Wing Website
4 On the right-hand side of the page, there will be green buttons. Press on the platform that you used to download the installer.

Wing Download>
5 Once the installer is downloaded, double-click on it to open it. Drag the Wing IDE to the Applications folder.

Wing Installer
6 Once the installation is finished, you might need to lookup Wing 101 in your applications to be able to open it.
Open up Wing 101, mac OS will ask you if you want to open the application.

Wing License
After open it the "License Agreement" window will show up (first time only). Press "Accept" to enable access to the IDE.

Wing License

Click Accept to open the application and this warning will not show up again.
You may also choose Keep in Dock for future convenience.
7 You will now be guided through the process of configuring Python 3.12.9 on Wing 101. It is possible that Python has already been linked to Wing 101. To check, see what is the message on the bottom right-hand box. If it has a message like the one below, Python is already configured. You can skip ahead to step 12 to test your configuration.

Wing Python Shell
8 If you have a different message, Python 3.12.9 is not configured properly. To configure Python 3.12.9, go to Edit -> Configure Python.

Wing Config

It will open up a window like this:

Wing Config
9 Select the Command Line shown below. Do not click on any other button as you are about to find the location of the Python Executable.

Wing Config Command Line
10 You will now be guided to find the location of the Python Executable.

Open up Terminal on your mac.

There are two ways to open Terminal:
(1) The location of Terminal is usually: Applications/Utilities/Terminal. You may find the exact location and open it.
(2) Using Spotlight Search (the magnifying glass icon on the top-right corner of the menu bar) to search for Terminal on your Mac and then open it.

After opening Terminal, type which python3.12 on the command line (as following) and then press Enter.
The location of Python Executable will be shown on a separate line after pressing Enter, as highlighted in the following image:

Terminal output

Copy the output.

Note: that you may or may not have a different address than the one in the demo image.
11 Go back to Wing101 and paste the address under Custom option, as circled in red in the following image. Then, click Apply.

Paste Python executable path

The following warning will show up, then click Restart.

Apply changes
12 To double-check your Python set-up, open a new file and type print("Hello World") in the top window. Then, save your file somewhere on your computer! Then press on the green arrow button in the tool bar at the top to run the program. If you don't save your file, the green arrow button will be gray and you will not be able to press it!!!

Wing Program

Hello World should show up in the Python Shell at the bottom.

Python Shell Output

If you have any questions or if your installation doesn't work correctly, please go to ISA office hours or email us at cs231@uwaterloo.ca.