<DKIM> Re: <DKIM> [PATCH] Pass relevant maildir filenames to newmail_hook

Nicolas Sebrecht nicolas.s-dev at laposte.net
Fri Jul 19 00:35:00 BST 2019

On Thu, Jul 18, 2019 at 07:36:21PM +0300, gwn wrote:

> Hi Nicolas, thanks for the reply.
> > This patch changes the purpose of the newmail_hook so I don't think we
> > should apply it to the mainline.
> What's the purpose of the newmail_hook :) In my opinion hooks are
> generic mechanisms and everyone can have different purposes for
> them. In any case I don't feel passing new mails into a new mail
> hook is an unreasonable change. But I'm just a new user, please
> feel free to enlighten me further..

The initial purpose of this hook is only to "inform new emails arrived",
not more.
I'm fine with changing the purpose to something more rich, though.

BTW, it might worth to avoid further breaking changes in this area.  We
could add *args to the lambda in the doc and make it clear this intends
possible further changes. IOW, change the doc from

  lambda: something


  lambda list_filenames, *args: something

> I'm completely fine with this not going into the mainline. It
> can't go in this form anyway as it's a breaking change.
> But as far as I understand, you don't have any other suggestions
> to help me accomplish what I'm trying to accomplish, do you? I'm
> even fine with parsing the output of offlineimap if I can build
> the relevant maildir filenames somehow..

My suggestions are in my other email. I thought this patch was not
intended for the mainline because of how this was introduced, sorry.

The machineui... I don't know any user actually using this feature but I
don't know all the usages. Anyway, I'm not surprised the machineui is
lacking relevant information for what you intend. Fixing the machinui
could impact all the other UIs so I'm fine with the current approach.

Nicolas Sebrecht

More information about the OfflineIMAP-project mailing list