commit | 4e9fd97554ca44333fcff9b1157191dc8919be44 | [log] [tgz] |
---|---|---|
author | Edwin Kempin <ekempin@google.com> | Wed Feb 03 12:24:37 2021 +0100 |
committer | Edwin Kempin <ekempin@google.com> | Thu Feb 04 10:49:33 2021 +0100 |
tree | 1bfd3fa3392fa8943ca69b1cf546e93c1970965d | |
parent | 44b26dde75fe203f12d456250ff6ad35aa5a27ef [diff] |
Fix validation of code-owner.config files The validation may be invoked for a commit which is not present in the repository yet and trying to load it via a new RevWalk fails with MissingObjectException. Such commits are only visible through the RevWalk that is creating the commit. This RevWalk is passed in together with the CommitReceivedEvent. We must use this RevWalk instance to load the commit from the event. For example the validation of code-owner.config files failed with MissingObjectException when a change for refs/meta/config was rebased. It failed regardless of whether the change actually touched a code-owners.config file (because we need to load the commit to know if the code-owners.config file was touched). Signed-off-by: Edwin Kempin <ekempin@google.com> Change-Id: I5fc34f0302fbf77908fba56da5d94924a0d05bd8
This plugin provides support for defining code owners for files in a repository.
If the code-owners plugin is enabled, changes can only be submitted if all touched files are covered by approvals from code owners.
Also see resources/Documentation/about.md
IMPORTANT: Before installing/enabling the plugin follow the instructions from the setup guide, see resources/Documentation/setup-guide.md