Installing Python and Pycharm

Basic set up notes for working with Python and Pycharm

Basic Behaviors for Coding

  1. DO NOT double click on a python file to open it, instead open the FOLDER with pycharm, (or if you have to use IDLE to open the file)
  2. DO NOT create a folder with a .py ending, folders should not have extensions
  3. DO enable seeing file extensions in your OS (Windows, Mac) (otherwise .py and .pyc files will confuse you greatly)
  4. DO NOT create a separate pycharm project for each python file
  5. DO NOT put a pycharm project folder inside an existing PyCharm project folder
  6. DO TRY THINGS OUT, and if they don't work and you can't figure out why:
    • Do not add a whole bunch of code (try to break ONE thing at a time ;)
    • Add print() statements to try to debug
    • Comment Out/remove code that you added when it broke
    • DO ASK ME FOR HELP!! (via email, lab hours, office hours, in class, smoke signals, whatever works)

Using a portable USB drive

Installing Python

Linux Users

Windows and Mac

Pycharm Community Edition

Download

Screen for Community

Pycharm Community Download Screen + Then a little option screen pops up, just click OK

Pycharm Import Config Pycharm EULA Pycharm Initial Config

Creating Your Project with Virtual Environment

Create a New Project Be careful where you create your project

Choose folder icon + Then either choose a folder (that should be empty) or choose the new folder icon and name it

Create new project folder Folder has been chose

Set Python Interpreter + You may need to add modules to it later, as we created a bare bones virtual environment + In the future you will use OPEN PROJECT and just point it to that directory, but you MAY have to reset the interpreter if you switched machines

Creating a new Python File to get to Work

Select Project Name Create new python file Choose File Name Type some code already!

Changing some of the Settings for Pycharm

Pycharm Settings Mouse Wheel Zoom

Adding Modules to your Project's Virtual Environment

Adding Modules Step 1 Adding Modules Step 2 Adding Modules Step 3 Adding Modules Step 4 Adding Modules Step 5

Page last updated on 20230911

HTML 5 Validation CSS 3 Validation Web Accessibility EValuator