PyCharm¶
This document aims to explain why we recommend using PyCharm to develop Song Match.
If you haven’t already, download and install PyCharm Community Edition here.
Finding Usages¶
The first reason we recommend you use PyCharm is the ability to find usages. Often when developing you need to find all the places where a function is called. PyCharm makes this easy.
For example, here’s a function that checks for whether the game is over in song_match.py
.
If you hover over the name of the function while holding Ctrl, and click the name of the function you can find usages.
PyCharm also has other keyboard shortcuts and ways to find usages that are helpful to learn.
The tooltip window shows the function is called in two places:
- Line
98
insong_match.py
- and line
117
insong_match.py
You can select either usage and PyCharm will automatically navigate there for you.
Note
Finding usages works for functions, methods, variables, and anything else you could care about.
Enforcing PEP 8¶
PyCharm also helps developers follow Python’s official style guide PEP 8.
For example, PEP 8 states variables should use snake case instead of camel case.
PyCharm underlines the camelcase variable with a yellow squiggly line
and suggests renaming it from numPlayers
to num_players
.
So Much More¶
PyCharm offers many other great features that are outside the scope of this document like:
- Integration with
requirements.txt
files - Powerful refactoring abilities
- Creating and Optimizing imports
- Reformatting source code
- and so much more.
You can find more information on JetBrain’s website.