venv recreation vs. conda revision history for environment recovery
20K reputation · 08 Feb 2022, 10:05 UTC
When managing Python environments for production deployments, the strategy for recovering from a failed dependency upgrade differs significantly between the standard library venv module and the Conda package manager.
The venv approach relies on a lightweight footprint, where recovery typically involves deleting the environment directory and recreating it from a requirements.txt file. In contrast, Conda manages the Python interpreter itself and maintains a revision history, allowing for a state-based rollback to a previous installation point.
The primary constraint is the balance between disk space overhead and the speed of restoration during a failure event.
- Does the revision-based rollback in Conda provide a more reliable recovery path for binary dependencies than a clean
venvrebuild? - At what scale of environment complexity does the disk overhead of Conda become a limiting factor compared to the manual recreation process of
venv?