codenotify icon indicating copy to clipboard operation
codenotify copied to clipboard

Do not process notifications when there is a merge conflict

Open unknwon opened this issue 5 years ago • 1 comments

This was one of the major issue we had with CODEOWNERS where when the PR has merge conflict with the target branch, it tags unrelated people for the unrelated files to the PR (due to the nature that GitHub currently considers all files in question to be part of changed files).

unknwon avatar Nov 16 '20 06:11 unknwon

I generally agree, but there are more ways to create mass notifications even when there are no conflicts. Most of the time, this happens when wrong branches are selected for merging (for example when you change the target branch of a PR, a lot of commits get "added" that should not be part of it).

As an additional counter measure, I'd suggest checking for an excessive number of pinged people, commits or modified files. (Those numbers would probably need to be adjustable per repository.) The action should then comment with a warning asking for confirmation before pinging all those people.

piegamesde avatar Oct 30 '21 13:10 piegamesde