How to mute emails generated by Herald activity on Differential Revisions?

We’ve created a Herald rule which automatically adds a blocking reviewer on new/updated diffs. Our CI system removes the reviewer if/when CI completes successfully.

This generates multiple additional emails, as the Herald activity seems to behave like a comment. Long-lived diffs with multiple updates and associated CI runs lead to a lot of emails.

There is a ‘Mute Notifications’ option on the Herald rule itself, but trying to use it generates a PhabricatorApplicationTransactionStructureException; something about a core:edge transaction not being supported by the Herald rule editor.

Is there a good way to mute or otherwise minimize the emails generated by this rule? In all other respects this rule is doing what we want, but some of our developers are unhappy with the increase in mail.

Is there a particular reason that the builtin CI behavior isn’t a good fit? What would need to change so you could just use Harbormaster for this, instead of adding and removing a dummy reviewer?

To answer your question directly: there’s currently no way to make Herald act silently, but the expectation is that using Harbormaster to coordinate builds has a large amount of much better behavior than using Herald + blocking reviewers + comments, so you might be solving a problem caused by using the wrong tool.

I am unlikely to make changes to the upstream that make it easier to integrate CI via Herald + Reviewers + Comments, since this integration can never be very good, and many of the problems are already solved well by using Harbormaster.

I like Harbormaster a lot for this, and agree it’s a better solution. In short, we have an existing CI integration which we feel would need to change to accommodate Harbormaster, and we don’t want to invest the time right now. The Herald rule took about an hour to create and test, and gave us what we needed. We might look at Harbormaster again in the future because again, I agree, it’s the better/correct tool for this.

I wasn’t intending to ask for a new feature with this post, I was hoping there was an existing feature that would help mute the emails. I do think it’s weird to offer a ‘Mute Notifications’ button on the Rule Editor screen if muting notifications is not supported for the rule, though.

The error you mention should have been fixed earlier this year by, but note that it mutes notifications about edits to the Herald rule, not notifications generated by the Herald rule. “Mute” is a global action and always means “mute notifications about edits applied to this object”.

OK, that makes sense. Thanks for following up.