commit emails from a central server with bzr 2.6
Robert Collins
robertc at robertcollins.net
Wed Jun 5 09:31:47 UTC 2013
On 5 June 2013 19:38, Glenn Morris <rgm at gnu.org> wrote:
>
> Hello,
>
> Having given up on bzr-hookless-email [1] for sending commit
> notifications from savannah.gnu.org with bzr 2.6, I tried the bzr-email
> plugin. Installing this on the server seems to do nothing. Instead when
> I make a commit from my remote client machine, it is the _client
> machine_ that tries to send out the commit email. This fails because my
> machine is not configured to send external mail. I was not expecting it
> to work this way, I was expecting the email to come from the central
> server machine.
If the plugin is installed on the server either globally or in the
users .bazaar directory, *and* the client is using a smart protocol to
push - bzr:// or bzr+ssh://, then the email hook code will execute on
the server.
If it ran locally for you, you had the plugin installed locally -
there is no code remoting facility within bzr, since that is very hard
to do securely, though we had talked about doing that for optimising
graph searches.
> That is what
> https://bugs.launchpad.net/bzr-email/+bug/307988
> ask for, and it was said "bzr-email supports this just fine".
>
> Buried in
> http://doc.bazaar.canonical.com/beta/en/admin-guide/hooks-plugins.html
> I find:
>
> The email plugin sends email from each individual developer's
> computer. This can be useful for situations that want to track what
> each individual developer is working on. On the downside, it
> requires that every developer's branches be configured individually
> to use the same plugin.
>
> which seems to say that it does _not_ "support this just fine".
That guide is narrative documentation maintained separately from the
plugins. It is great that it exists, but one of the tradeoffs made
when assembling it was to make it updatable independently of either
bzr or the plugins, but this makes it (IMO) rather more subject to
skew as a) plugin authors aren't intrinsically connected to edits
being made to the guide, and b) doc updates need to be done as
separate commits to a separate project. [This pattern of doc
maintenance is quite common in open source, and I find the failure
modes occur nearly universally...]
While I'm not very active in bzr anymore, I'd be happy to help you
debug why bzr-email isn't sending mail from the server side. To start
with, check in ~/.bzr.log on the server and ensure the email plugin
reports as loading. Secondly set post_commit_push_pull in the config
on the server: last I looked bzr doesn't have a /etc/bazaar.conf, but
Vincent had a significant overhaul of the config system underway which
may have rectified that.
If there is support for /etc/bazaar.conf,set it there. If there isn't,
edit the plugin to default that on, rather than off. We should perhaps
consider it a bug that when invoked via a bzr server process it
doesn't default to on (the email plugin predates the smart server, so
there is room for polish).
-Rob
--
Robert Collins <rbtcollins at hp.com>
Distinguished Technologist
HP Cloud Services
More information about the bazaar
mailing list