Project environments and packages
The single most important habit: one isolated environment per project.
Python options
venv+pip— built-in, simple, universaluv— fast, modern, recommended defaultpipenv— modern, handles both env and packagesconda/mamba— best when you need non-Python binaries (GDAL, CUDA, etc.)poetry,pdm— alternatives worth knowing
R
renvfor project-scoped package libraries- CRAN vs. Posit Package Manager vs. GitHub installs
Reproducibility checklist
- A lockfile is committed (
uv.lock,requirements.txt,renv.lock) - The README states the language version
- A new clone can run one command to get a working environment