[RFC] Spec for having plugins bundle their dependencies into installer

Jelmer Vernooij jelmer at vernstok.nl
Sat Feb 14 02:26:54 GMT 2009


Hi John, Mark,

I think it's a good idea to put this sort of dependency information in
the plugin rather than in bzr's setup.py.

On Sat, Feb 14, 2009 at 10:10:58AM +1100, Mark Hammond wrote:
> On 14/02/2009 3:55 AM, John Arbash Meinel wrote:
>> 2) plugin/setup.py is not a good place for this, because setup.py is
>> doing all sorts of things running as an interactive script.
> I'm not so sure about that for the specific requirements being discussed  
> here.  Most setup.py files of interest are already doing nothing other  
> than setting themselves up as a plugin for bzr in some form.  Asking  
> such scripts to add an if __name__=='__main__' block is no less burden  
> than asking them to add another file.

> Further, the existing setup.py probably *already* does other stuff  
> critical for making the plugin work - eg, building docs, creating  
> localizations, etc.  So in the general case you would need to invoke  
> setup.py *and* this new script which seems to create complexity.

> So I'd vote for asking plugin authors to make slight adjustments to  
> their setup.py, and arrange so that when this new entry point is  
> invoked, *everything* is automatically built - ie, remove the  
> requirement to run their external setup.py manually separately.
This would have my preference as well. The requirement to be able to
load setup.py as non-interactive script is there anyway, as documented
by doc/developers/plugin-api.txt. Perhaps it would be an idea to just
extend that spec?

Cheers,

Jelmer




More information about the bazaar mailing list