want configuration items to disable/enable plugins

Bug #411413 reported by Martin Pool on 2009-08-10
22
This bug affects 3 people
Affects Status Importance Assigned to Milestone
Bazaar
Medium
Vincent Ladeuil

Bug Description

In thread "Windows packaging/installers" Alexander suggests

    2009/8/10 Alexander Belchenko <email address hidden>:

        I'd like to have more fine grained control on what plugins are
        installed/enabled. Today bzr has no way to disable plugin other than remove
        it from plugins folder. It has its own pros and cons, but it's definitely
        (little) problem if you want to keep your plugins base lean to avoid longer
        startup time of bzr.

    I was thinking about this too, in testing things in 2a. How about
    just a crude configuration option to block out named plugins?

INMHO, plugins section in bazaar.conf will be nice:

[PLUGINS]
bzrtools = enable
svn = disable

If plugin is not mentioned in this section assume it's enabled as it works now.

Related branches

Vincent Ladeuil (vila) wrote :

Please consider making it based on the directory name instead of the plugin name so that it can also be used to allow testing various branches of the same plugin.

Of course a single directory can be allowed for a given plugin and there may be some trickery involved when mapping the directory to the python namespace (I'm not familiar with the plugin loading code so I may be wrong).

-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

Vincent Ladeuil wrote:
> Please consider making it based on the directory name instead of
> the plugin name so that it can also be used to allow testing
> various branches of the same plugin.
>
> Of course a single directory can be allowed for a given plugin and
> there may be some trickery involved when mapping the directory to
> the python namespace (I'm not familiar with the plugin loading code
> so I may be wrong).
I submitted a merge request for this earlier attempting to work
towards this but it was rejected:

https://code.edge.launchpad.net/~jelmer/bzr/plugin-refactor/+merge/9005

Cheers,

Jelmer
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.9 (GNU/Linux)
Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org

iQIcBAEBAgAGBQJKgsA5AAoJEACAbyvXKaRXrHkQAKlQZK9CYqVfo8OojXiiNwKQ
CScfc+tYJrtcbJ+G0P96YXUbASTY8LAq4YbesSugSvl8ZE+V59t1n+6aAAC3SiKf
mBG1Lp2MugyRm9Q+IV+kqYry3OSzWpkVqbWIs2/vEn1YFhwGotwn57Zk8u6ARGzU
LIx63RYE7aNPyIZEuZ3LEqckjLc7dbeovCqLB1+AMeLuaoSvnjj/kt1VBZrudGmB
JgFmhyxSzOh5g73tcSHtl/yjZXO3LZ/VZb0VnnYHKUBo9LZP/4/hb4RFoEcylrYi
IErGgA4wJ7xFW90jmzrl55K8SQrPe3A0eb17Oy9SSTPbA7YclkK16hyOct06OjVH
J34Y/mWuuLlemWb9HIgCdnLEsuXxeZuMVJe2SHmQHbcVRAVgboiGae8T1ajLDLcr
cxE4QrucpeTb1pwYyh5PzCgTJk0Qu8xmV4FPYsJbjgKwtmjD3q61Hut1eNsY1W7i
9SWYZo7gMYSnzEyB4sn6ahrBax+ID3RospGxpBovQ+Fvz3alel4R4ZTwvFZVnik4
z1MBf3ilxgI8OrFEVR6beKeT59BcgN9PH/v7KbjnD3S2jcgb/tewZTnivZelteMS
7+Za1zIDS/7wqweMneuxkUoZEqwI5O2sbmWj1L98f25C2Ndnz8VRVRSyx4xvVRwZ
XBMMYwhFAghf87X1aqpq
=4/Tf
-----END PGP SIGNATURE-----

2009/8/12 Jelmer Vernooij <email address hidden>:
> -----BEGIN PGP SIGNED MESSAGE-----
> Hash: SHA1
>
> Vincent Ladeuil wrote:
>> Please consider making it based on the directory name instead of
>> the plugin name so that it can also be used to allow testing
>> various branches of the same plugin.
>>
>> Of course a single directory can be allowed for a given plugin and
>> there may be some trickery involved when mapping the directory to
>> the python namespace (I'm not familiar with the plugin loading code
>> so I may be wrong).
> I submitted a merge request for this earlier attempting to work
> towards this but it was rejected:
>
> https://code.edge.launchpad.net/~jelmer/bzr/plugin-refactor/+merge/9005

We should talk about that more then, but probably not in this bug.
Aside from some detailed comments by Robert he just says "it doesn't
seem like a good conceptual idea", but I'm not sure it's a bad idea.

--
Martin <http://launchpad.net/~mbp/>

Martin Pool (mbp) wrote :

bug 534320 could also be solved by doing this in a way that allows it to be given on the command line.

Vincent Ladeuil (vila) wrote :

https://code.edge.launchpad.net/~vila/bzr/411413-disable-plugin/+merge/21435 provides a fix using:
BZR_PLUGIN_PATH=-svn:-bzrtools:+user to disable svn and bzrtools while retaining the others.

Changed in bzr:
assignee: nobody → Vincent Ladeuil (vila)
status: Confirmed → In Progress
Vincent Ladeuil (vila) wrote :

https://code.edge.launchpad.net/~vila/bzr/411413-disable-plugin/+merge/21435 updated to use:
BZR_DISABLE_PLUGINS=svn:bzrtools to disable svn and bzrtools.

Vincent Ladeuil (vila) on 2010-03-19
Changed in bzr:
milestone: none → 2.2b1
status: In Progress → Fix Released
To post a comment you must log in.
This report contains Public information  Edit
Everyone can see this information.

Duplicates of this bug

Other bug subscribers