Skip to main content

The Basics: Python

What is it?​

Python is a high-level general-purpose programming language that is easy to learn and fast to write. It's great for prototyping but is used for everything from Backend, Web Development (using Django), DevOps & Security Automation scripts, Data Science and Analysis, Machine Learning & more.

Setup​

1. Install PyEnv​

Pyenv is an environment managment tool and the recommended way to install one or more versions of Python.

2. Install the latest stable Python version via PyEnv​

3. Set Global Python version to latest​

In a terminal, run pyenv global 3.10.4

4. Install some helpful development dependencies​

black is a formatter, flake8 is a linter.

pip install black flake8 flake8-bugbear

4. Install this repo's Python dependencies​

Python dependencies (3rd-party code we use in our programs) are typically installed via a tool called pip, which is automatically included with Python.

Our repo's dependencies are stored in the ./python/requirements.txt file

cd python
pip install -r requirements.txt