Join GitHub today
GitHub is home to over 31 million developers working together to host and review code, manage projects, and build software together.Sign up
Reliable detecting the Zope version #411
Add-ons interacting with the ZMI need to provide different templates for Zope 2 (old style ZMI) and Zope 4 (bootstrap based ZMI). Therefore, there is a need to reliable distinguish those versions -- potentially via a mechanism analogous to Python's
In fact, Zope2's
There is another disadvantage with your proposed solution for my current use case, i.e. making extensions working fine in both "Zope2" and "Zope 4+". For "Zope2", I must look at the distribution "Zope2"; for "Zope 4+" at the distribution "Zope". In a typical "Zope 4" setup, there is also a "Zope2" distribution but apparently there is no strict relationship between the versions of "Zope" and "Zope2" (at the moment "4.0b7" and "4.0b1", respectively). This lets it seem doubtful to always look at the "Zope2" distribution version to determine the version of "Zope 4+".
In short: determining the version via