Setting Up Your Local Development Environment

Setting Up Your Local Development Environment
While we suggest using Nuvolos for our coding exercises in DS105W, some students may want to set up their own local development environment. This guide will help you install and configure the necessary tools on your personal computer.
⚠️ IMPORTANT
Setting up a local environment is entirely optional for this course. Nuvolos provides all the tools you need, and using it ensures everyone has the same environment, making it easier for us to help you troubleshoot issues.
If you decide to set up your local environment:
- This will require additional time and effort on your part
- You may encounter platform-specific issues that the teaching team cannot fully support
- You will still need to use Nuvolos for certain activities
Why Set Up a Local Environment?
There are several benefits to setting up your own development environment:
- Work offline without an internet connection
- Customize your development tools to your preferences
- Gain experience with tools and workflows used in industry
- Continue using these tools after the course ends
🎯 ACTION POINTS
1️⃣ Install Python
Python is the primary programming language we’ll use in this course. We recommend installing Python 3.10 or newer.
For Windows Users
Download the installer from the official Python website.
Run the installer and make sure to check the box that says “Add Python to PATH” before clicking “Install Now”.
When asked, remember to add Python to PATH
Verify the installation by opening Command Prompt and typing:
python --version
For macOS Users
macOS comes with Python pre-installed, but it’s usually an older version. We recommend using Homebrew to install a newer version:
Install Homebrew (if you don’t have it already).
Go to the Homebrew website and follow the instructions to install it.
Install Python using Homebrew:
brew install python
Verify the installation by opening Terminal and typing:
python3 --version
For Linux Users
Most Linux distributions come with Python pre-installed but to install the latest version:
Update your package list:
sudo apt update # For Ubuntu/Debian # OR sudo dnf update # For Fedora
Install Python:
sudo apt install python3 python3-pip # For Ubuntu/Debian # OR sudo dnf install python3 python3-pip # For Fedora
Verify the installation:
python3 --version
2️⃣ Installing Packages
Once Python is installed, you might need to install the packages we have been using in the course.
pip install numpy pandas lets-plot ipykernel ipywidgets requests pycountry tqdm
💡 TIP: It’s a good practice to create a requirements.txt
file that lists all the packages your project needs:
pip freeze > requirements.txt
This allows others (or you on a different computer) to install all the required packages with:
pip install -r requirements.txt
3️⃣ Install VS Code
Visual Studio Code (VS Code) is a powerful, lightweight code editor that works well with Python and many other languages.
- Download VS Code from the official website.
- Run the installer and follow the prompts.
- Launch VS Code after installation.
Install Python Extensions for VS Code
To make VS Code work better with Python:
Open VS Code
Open the Extensions view by clicking on the Extensions icon in the Activity Bar on the side of the window or pressing
Ctrl+Shift+X
(Windows/Linux) orCmd+Shift+X
(macOS).Search for “Python” and install the official Python extension by Microsoft.
🤖 AI Tool Recommended: Instead of ChatGPT, GitHub Copilot provides a much more contextual and helpful experience. Install the GitHub Copilot extension. If you sign up for the GitHub Education Pack, you will get a free unlimited license to use it.
4️⃣ Install Git & GitHub CLI
Git is essential for version control and working with GitHub. If you haven’t already set up Git, follow these steps:
For Windows:
Download the installer from git-scm.com.
Run the installer and use the default settings (unless you have specific preferences).
Verify the installation by opening Command Prompt and typing:
git --version
Install the GitHub CLI by following the official instructions.
For macOS:
If you’ve installed Homebrew as mentioned earlier:
brew install git
Alternatively, you can download the installer from git-scm.com.
Install the GitHub CLI by following the official instructions.
After installing Git, follow the instructions in our Git & GitHub guide to set up authentication and configure your Git identity.
For Linux:
Install Git:
sudo apt install git # For Ubuntu/Debian # OR sudo dnf install git # For Fedora
Install the GitHub CLI by following the official instructions.
After installing Git, follow the instructions in our Git & GitHub guide to set up authentication and configure your Git identity.
Troubleshooting Common Issues
Python Not Found in PATH
If you get a “command not found” error when trying to run Python:
Windows: Make sure you checked “Add Python to PATH” during installation. If not, you may need to reinstall or add Python to PATH manually.
macOS/Linux: Try using
python3
instead ofpython
.
Package Installation Errors
If you encounter errors when installing packages:
Update pip:
# Windows python -m pip install --upgrade pip # macOS/Linux python3 -m pip install --upgrade pip
Check for compatibility issues between packages.
Look for platform-specific installation instructions for packages that include compiled components.
Getting Help
If you encounter issues setting up your local environment:
- Search online for the specific error message you’re seeing.
- Check Stack Overflow for solutions to common problems.
- Post in the course Slack channel
#help
, but be aware that local environment issues may be harder for us to troubleshoot remotely.
Remember, using Nuvolos is always an option if your local setup becomes too challenging!