[Distutils] environment replication

Robin Becker robin at reportlab.com
Thu May 4 05:12:14 EDT 2017


I have a bunch of virtual environments which need replicating from one machine 
to another. In the past rsync was OK, but now with slightly different 
environments I have been using pip freeze to get a list of the installed 
requirements and pip install to carry out changes to the remote environment.

Is there a way to resolve issues where pip reports a different package to the 
one installed eg


the original requirements say

git+http://github.com/django-cumulus/django-cumulus.git@master#egg=django-cumulus

but pip freeze will only say


django-cumulus===1.0.19-22-g506121d

ie we lost the actual installation notation. Given that the git location is 
actually unstable ie the revision can change it seems quite hard to get 
reproducibility in an automatic fashion.

g506121d is derived from the repo hash 
(https://github.com/django-cumulus/django-cumulus/commit/506121d8669e1cce8843d9f76f2767324f8b1e78), 
but I see no way to guess that from the version string unless there some 
standard decoding I can do of the revision.
-- 
Robin Becker


More information about the Distutils-SIG mailing list