Django

Django Installation

Python 3.11+, venv, and Django 5.x

Django Installation

TaskBoard requires Python 3.11+ and Django 5.x (compatible with Django 6.x). Always use a virtual environment per project.

Check Python

python3 --version

Create venv and install Django

mkdir taskboard && cd taskboard
python3 -m venv .venv
source .venv/bin/activate   # Windows: .venv\Scripts\activate
pip install "Django>=5.0,<6" django-environ
pip freeze > requirements.txt

Verify

django-admin --version
python -c "import django; print(django.get_version())"

Pin versions in teams

Commit requirements.txt so CI and production use the same Django version. Avoid installing Django globally on your OS Python.

Best practice: Add .venv/ to .gitignore. Use django-environ or python-decouple for secrets in later lessons—not hard-coded keys in settings.