Fast Python Development with uv
by Dr. Mike Müller
Friday, 17 April 8:00 - 12:00 incl. breaks · 3.5 hours
Description
Learn how to use uv for fast, reliable Python development. Created by Astral (the makers of Ruff), uv is a modern Python package and project manager written in Rust that can replace pip, pip-tools, virtualenv, poetry, pyenv, and more—with dramatic speed improvements.
This hands-on tutorial teaches you how to use uv for managing Python projects, dependencies, and tools. uv is designed to be a drop-in replacement for pip while offering a complete development workflow: project management, dependency resolution, virtual environments, Python version management, and tool installation.
Key advantages of uv:
- Speed: 10-100x faster than pip for most operations
- Compatibility: Works with existing pip workflows and requirements.txt files
- Complete workflow: Replaces multiple tools with a single, unified interface
- Reliability: Deterministic dependency resolution with lock files
You will learn:
- How to replace pip with uv for faster package installation
- How to manage Python projects with
pyproject.tomlanduv.lock - How to handle multiple Python versions without external tools
- How to manage workspaces for multi-package projects
- How to use
uvxfor running Python tools without installation - How to run single-file scripts with inline dependencies
- How to build and publish Python packages
- Best practices for using uv in real-world projects
A brief comparison with Pixi and other dependency management tools is included.
Please install uv before the tutorial.
Audience
This tutorial is designed for participants who:
- Have solid Python knowledge
- Are familiar with basic use of
pipor similar tools - Want to speed up their development workflow
- Would like to learn what uv brings to Python development
Prerequisites:
- Comfortable writing Python code
- Basic familiarity with package installation (using
pip) - Understanding of virtual environments (helpful but not required)
- Basic command-line usage
No prior experience with uv is required. Familiarity with poetry, conda, or other dependency management tools is helpful but not
necessary.
Your trainer: Dr. Mike Müller
Dr. Mike Müller has been teaching Python professionally since 2004 — with over 580 courses and 1,500 teaching days under his belt. A fixture at Python conferences worldwide, he has delivered 75+ tutorials at events including PyCon US (29 tutorials since 2007), EuroPython, and PyData. As a senior trainer at Python Academy, Mike combines deep technical expertise with a hands-on teaching style: live coding from scratch, progressive complexity, and real-world examples that participants can apply immediately.
Details
Format
This tutorial is highly interactive and hands-on:
- Live Demonstrations (approximately 60%): I develop examples step-by-step, starting from blank notebooks or terminal sessions. Participants are encouraged to type along. The supplied PDF contains all code to help participants get back on track if needed.
- Exercises (approximately 35%): Three exercise sessions where participants apply concepts to their own projects or work through structured examples. Solutions are reviewed together.
- Discussion and Q\&A (approximately 5%): Questions are encouraged at any time. I explicitly ask for feedback on pacing and clarity throughout.
Teaching approach:
- No pre-filled notebooks—everything is built live to show the thought process
- Typing speed is deliberately moderate to allow participants to follow
- More complex examples are also provided as Python source code files
- Comprehensive PDF handout with all content for reference
- Solutions PDF distributed after the tutorial
Participants will be active throughout the entire tutorial, working with uv on their own machines to build real-world skills.
Outline
Introduction (5 min)
- Instructor introduction
- Participant background survey (raise hands to answer questions about Python and dependency management experience)
Problem Analysis (10 min)
Explain what dependency management is needed for.
Two basic tasks:
- Installing packages
- Building packages
Questions to set the stage:
- Why is dependency management complex?
- What approaches exist?
- Why is speed important?
Overview of the Ecosystem (15 min)
Look at available tools and explain key terms.
- Traditional pip-based approaches
- pip and pip-tools
- virtualenv and venv
- pyenv for Python version management
- poetry
- pdm
- hatch/hatchling
- setuptools
- conda-based approaches (brief overview)
- conda/mamba
- Pixi (hybrid approach with conda-forge + PyPI)
- Modern unified approach
- uv: one tool to replace them all
The uv Approach (30 min)
- Command-line interface (CLI) and pip compatibility
pyproject.tomlconfiguration fileuv.lockfor reproducibility- Virtual environments (automatic management)
- Python version management with
uv python - Global tool installation with
uv toolanduvx - Single-file scripts with inline dependencies
- Exercise (10 min): Getting started with uv
Example - A Small Python Data Project (40 min)
- Define an example: a small program to analyze data for internal use
- Start with
pandas - Add more dependencies progressively:
openpyxlfor Excel file supportmatplotlibfor visualizationpyarrowfor Parquet files
- Use
pyproject.tomlanduv.lockto manage dependencies - Compare installation speed with pip
- Address potential problems and conflicts
- Exercise (15 min): Apply uv to your own program
Example - Building a Python Package (40 min)
- Turn the example into a distributable package
- Use
pyproject.tomlfor package metadata - Use editable installs for development
- Configure multiple environments for:
- Testing with pytest
- Different Python versions
- Documentation building
- Workspaces for multi-package projects
- Building and publishing packages
- Exercise (15 min): Package your own project
Advanced Features and Best Practices (30 min)
- Using
uvxfor running tools without installation - Single-file scripts with inline dependency metadata
- Migrating from pip, poetry, or other tools
- Working with requirements.txt files
- Special cases:
- Handling platform-specific dependencies
- Integrating with CI/CD pipelines
- Performance tips and troubleshooting
- Brief comparison: uv vs. Pixi vs. other tools
Wrap-Up and Q&A (10 min)
- When to use uv (and when to consider alternatives like Pixi)
- Migration strategies from other tools
- Resources for continued learning
- Open questions and discussion
Internet Requirements (Prep for Tutorial)
Participants will receive detailed setup instructions a few days before the tutorial, including:
- uv installation instructions for Windows, macOS, and Linux
- Verification steps to ensure uv is working correctly
- PDF handout with tutorial content
- Code examples and exercises
- Pre-downloading instructions for common packages (optional but recommended)
Critical: Participants MUST have uv installed before the tutorial.
Internet Requirements (During Tutorial)
Internet connection required: This tutorial requires internet connectivity during the session because:
- Package downloads are a core part of the tutorial (installing packages with uv)
- Participants will download packages from PyPI
- Live demonstrations show real-world package installation scenarios
- Speed comparisons require actual downloads
Bandwidth considerations: To minimize bandwidth usage:
- Because uv caches packages, participants can reduce bandwidth usage during the tutorial by installing packages a day before the tutorial
- I will provide instructions how to do this
- uv's efficient caching means repeated installs use minimal bandwidth
Fallback plan: If internet becomes unavailable:
- I can still show how my pre-installed environments work
- The tutorial can pivot to focus on uv configuration and workflow management