[PATCH 09/13] email: add support for X-Aiaiai-Cancel-Email-Test-Patchset

Keller, Jacob E jacob.e.keller at intel.com
Tue Mar 25 13:44:00 PDT 2014


On Mon, 2014-03-24 at 10:40 +0200, Artem Bityutskiy wrote:
> On Fri, 2014-03-21 at 20:57 +0000, Keller, Jacob E wrote:
> > > -----Original Message-----
> > > From: Artem Bityutskiy [mailto:dedekind1 at gmail.com]
> > > Sent: Friday, March 21, 2014 10:32 AM
> > > To: Keller, Jacob E
> > > Cc: aiaiai at lists.infradead.org
> > > Subject: Re: [PATCH 09/13] email: add support for X-Aiaiai-Cancel-Email-
> > > Test-Patchset
> > > 
> > > On Thu, 2014-03-20 at 16:37 -0700, Jacob Keller wrote:
> > > > +
> > > > +# Check whether a hook has indicated to cancel the testing this patch
> > > > set
> > > > +cancel="$(fetch_header "X-Aiaiai-Cancel-Email-Test-Patchset")"
> > > > +if [ -n "$cancel" ] && [ "$cancel" = "1" ]; then
> > > > +       verbose "Canceling $PROG without testing."
> > > > +       exit 0
> > > > +fi
> > > 
> > > So which e-mail will the sender receive if the patch-set testing was
> > > canceled?
> > 
> > In my example it's expected that the hook is the one that notifies the user, and this flag was the cleanest way to stop the email-test-patchset from running at all essentially...
> > 
> > That could be changed, but I expected the hook to have the most information about why the patch was cancelled.
> 
> OK. I do not know what is the better design, but would be nice to have
> less code duplication.
> 
> What do you think if the hooks are invoked by
> 'aiaia-email-testpatchset', rather than the dispatcher?
> 
> So, tespatchet would check the project config, see which hooks should be
> invoked, and run them.
> 
> testpatches would probably know the specifics of the hooks too. E.g.,
> what they return.
> 
> I guess, generally, if hook returns failure exit code, then the stdout
> of the hook is considered to be the reply to the user, and testpatchet
> sends it out.
> 
> If hook returns success, then testpatched proceeds. The stdout of the
> hook is interpeted differently, depending on the hook.
> 
> Testpatchset would also add various notes to the e-mail reply. For
> example, if the base commit was changed, testpatchset could tell about
> this in the e-mail reply.
> 
> The e-mail tags would not be used, then, I guess.
> 
> What do you think? I do not insist on any of the two, just asking. You
> gave this some thought, so you may see the pros and cons of both.
> 
> Thanks!
> 

Nevermind about the based from master, since we have not merged to
master in a while, so there are huge changes missing. I will instead
create an initial revert that undoes only stuff which is hook related.

Thanks,
Jake


More information about the aiaiai mailing list