Overriding site-wide plugins with user-installed plugins
Jonathan Lange
jml at mumak.net
Fri Feb 23 01:52:43 GMT 2007
On 2/23/07, Martin Pool <mbp at sourcefrog.net> wrote:
> Jonathan Lange wrote:
> > It turns out that Bazaar won't let me do that.
> > bzrlib.plugin.set_plugins_path() explicitly ensures that
> > site-installed plugins trump user-installed plugins. To work around,
> > I've had to abuse my root privileges and move the plugin from
> > site-packages.
> >
> >> From my perspective, this is clearly a bug. However, it has been
> > suggested that the world may be more complex than I might first think.
>
> It's not intentional as far as I know. You could file a bug or send a
> patch.
>
Will do.
But it sure _looks_ intentional:
def set_plugins_path():
"""Set the path for plugins to be loaded from."""
path = os.environ.get('BZR_PLUGIN_PATH',
get_default_plugin_path()).split(os.pathsep)
# search the bzrlib installed dir before anything else.
path.insert(0, os.path.dirname(plugins.__file__))
plugins.__path__ = path
return path
cheers,
jml
More information about the bazaar
mailing list