Reviewer roulette via Danger should take CODEOWNERS file into account
The following discussion from !24938 (merged) should be addressed:
question: Do we have an issue for that? If not we should probably create a follow-up issue.
We're introducing reviewer roulette - merge requests will have possible reviewers added as suggestions. However, we don't currently take the
CODEOWNERS file into account, and it would be nice to do so.
I'd probably make this an additive change, since
CODEOWNERS deals with individuals rather than groups, and a CODEOWNER may not be a reviewer or a maintainer.
We could try to group files that are touched by the right-hand-side of the
CODEOWNERS file. For instance, if the MR changes:
And we have a
app/* @foo @bar @baz app/gitlab/access.rb @foo @bar @baz public/* @qux
Then we could make just two selections: one from
%w[@foo @bar @baz] for the three changed code files, and one from
%w[qux] for the change to