Programming Foundations with Python
Writes tested, modular, idiomatic Python for data and AI workloads.
Tech stack
Modules
7 modules · 48 hours
M1 · Interpreter, environments and project setup
6 h- Interpreter and runtime model
- Virtual environments (venv/uv)
- Package management and pinning
- Project layout
- PEP 8
- Editors and debuggers
Lab: Provision a reproducible project skeleton with pinned dependencies
Course material for this module is in production.
M2 · Types and collections
8 h- Numeric and string types
- f-strings
- list/tuple/dict/set
- Comprehensions
- Slicing
- Mutability semantics
Lab: Data-transformation kata set (12 problems)
Course material for this module is in production.
M3 · Functions and control flow
8 h- Control flow
- Functions, arguments and defaults
- Scope and closures
- Decorators
- Generators and iterators
- Context managers
Lab: Build a retry decorator and a streaming file reader
Course material for this module is in production.
M4 · Object-oriented design
8 h- Classes and inheritance
- Composition over inheritance
- Dunder methods
- Dataclasses
- Protocols
- Module and package design
Lab: Design a plug-in class hierarchy for data loaders
Course material for this module is in production.
M5 · Errors, logging and typing
6 h- Exceptions and custom exceptions
- Structured logging
- Defensive programming
- Type hints
- Static checking with mypy
Lab: Add typing and structured logging to an existing script
Course material for this module is in production.
M6 · File and network I/O
6 h- CSV, JSON, JSONL, Parquet, YAML
- HTTP with requests
- Pagination
- Retries and backoff
- Rate limits
Lab: Build a resilient API-ingest client with backoff
Course material for this module is in production.
M7 · Testing and code quality
6 h- pytest fundamentals
- Fixtures and parametrisation
- Mocking
- Coverage measurement
- Linting with ruff
Lab: Achieve ≥80% coverage on the ingest client
Course material for this module is in production.