Styles of version checking code in plugins?

Jelmer Vernooij jelmer at vernstok.nl
Fri Sep 18 15:40:31 BST 2009


On Thu, Sep 17, 2009 at 07:00:16AM +0100, Russel Winder wrote:
> Is there an idiom for version checking code.  bzr-svn, bzr-git, rebase
> all do it using a file info.py, gtk puts the data directly in
> __init__.py in a different way.  The commonality of the first three is
> probably coincident with Jelmer being a primary author, but it raises
> the question of whether there is or should be a standard model followed
> by all plugins.
Actually, I'm responsible for the API version checking code in all three. I 
just haven't updated bzr-gtk to use a separate "info.py" file yet. The reason
for having a separate file is that it can be imported from both __init__.py and 
setup.py so that there's only one place to declare e.g. minimum API versions.

Jelmer

-- 



More information about the bazaar mailing list