Vai al contenuto principale
⚡
← Corsi
›
Python 2026: What's Actually New
›
Module 2 · Modern stack (2025-2026 edition)
›
uv-native workflows: pyproject.toml without venv activate
quiz
6 / 27
🇮🇹
IT
▼
↗
Condividi
⋯
Altro
+60 XP
📋
Compito
📖
Teoria
🤖
Aiuto IA
Compito
🌐 shown in RU
You cloned a repo with pyproject.toml + uv.lock. What is the ONE command that gets you to a running `pytest` in a reproducible env?
🎯 Quiz
Domanda
You cloned a repo with pyproject.toml + uv.lock. What is the ONE command that gets you to a running `pytest` in a reproducible env?
A
First `python -m venv .venv`, then `source .venv/bin/activate`, then `pip install -e .[dev]`, then finally `pytest`: the same four-step dance that pip-based projects have used for many years now
B
`uv run pytest`: uv reads pyproject.toml + uv.lock, materialises a hidden .venv if missing, syncs it to the lock, and executes pytest inside it, all in one command with no manual activation
C
`uv install && uv activate && uv exec pytest`: uv follows the classic virtualenv three-step contract because reproducibility depends on the activation state being explicit in the developer's shell session
D
`uvx pytest`: because uvx is uv's tool-runner shorthand, it is the recommended way to run any project-scoped command against the current directory's pyproject.toml regardless of dependencies
Rispondi
💬
Contatta il supporto