[Grok-dev] Grok-dev Digest, Vol 70, Issue 7
sylvain at infrae.com
Wed Jul 18 07:46:07 UTC 2012
Op 17 jul 2012, om 18:24 heeft Paul Sephton het volgende geschreven:
> That's cool; I think it's a pity that those distros clash with setuptools, and it's understandable that creating an independent installation is preferable to hacking one's way through the version difference problems. It will always be a problem where some python apps insist on newer egg versions than other python apps.
> The way system libraries handle the version difference problems is interesting by comparison. By incrementing major library version only when the API interface changes, and incrementing the minor version whenever anything else changes, and naming the module to include major & minor numbers, it is possible to maintain binary compatibility after linking and yet allow for incremental library upgrades. Effectively, older libraries may live alongside newer libraries ad-infinitum. Python, on the other hand, expects libraries to have potential incompatibility only between interpreter versions, and actual library names remain the same between updates regardless of incompatible changes. I'm sure there is something one could do, thinking about it.
Well, setuptools does that, meaning it can have multiple version of a package installed in your site-package, because basically it is not able to uninstall anything. However by default you will always have the latest version injected in sys.path (or the one you specified during the installation). You can support it, but you have to disable the site-package (with a site.py for example), and inject the specific version of the egg you use yourself into sys.path, not to rely on any modification done in the site-packages.
Of course buildout is not able to do that (and buildout doesn't install anything in the site-package).
PS: Monteur is able to do it.
Sylvain Viollon -- Infrae
t +31 10 243 7051 -- http://infrae.com
Hoevestraat 10 3033GC Rotterdam -- The Netherlands
More information about the Grok-dev