Commit Graph

39 Commits (e95696ff530d1ef5cc103a4c6f148f983f6a998d)

Author SHA1 Message Date
Gavin Mak df2f11113c Update code-owners documentation links
Bug: 1223715
Change-Id: Ia4cfaf6c421432f0b64662ab02bc4041f32173d9
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/tools/depot_tools/+/4585553
Auto-Submit: Gavin Mak <gavinmak@google.com>
Commit-Queue: Aravind Vasudevan <aravindvasudev@google.com>
Reviewed-by: Aravind Vasudevan <aravindvasudev@google.com>
2 years ago
Gavin Mak 0f1addcbe9 Reland "Remove old DepotToolsOwners implementation"
This is a reland of commit 10dbd7babd

Original change's description:
> Remove old DepotToolsOwners implementation
>
> code-owners should have been enabled for most hosts that depot_tools
> supports by now. Remove our own implementation and rely on code-owners.
>
> Change-Id: Iaf0d3db65b2e5063b67d42b92188c4ec51d2cd9a
> Reviewed-on: https://chromium-review.googlesource.com/c/chromium/tools/depot_tools/+/3783475
> Reviewed-by: Aravind Vasudevan <aravindvasudev@google.com>
> Reviewed-by: Joanna Wang <jojwang@chromium.org>
> Commit-Queue: Gavin Mak <gavinmak@google.com>

Change-Id: Ic87f34411bb38b91fcf49adb07601ae10244e828
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/tools/depot_tools/+/3881043
Reviewed-by: Josip Sokcevic <sokcevic@google.com>
Commit-Queue: Gavin Mak <gavinmak@google.com>
Reviewed-by: Joanna Wang <jojwang@chromium.org>
3 years ago
Gavin Mak e0fee9fa4b Add BatchListBestOwners and ListBestOwners to GerritClient
ListOwners returns all OWNERS for a file, which is undesirable in cases
when only direct OWNERS are needed.

Bug: 1351212, 1351519
Change-Id: I693b6645c780aa589e8ab24d0b58691f4aeb30f6
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/tools/depot_tools/+/3823299
Reviewed-by: Aravind Vasudevan <aravindvasudev@google.com>
Commit-Queue: Gavin Mak <gavinmak@google.com>
3 years ago
Gavin Mak a9677a5e9b Revert "Remove old DepotToolsOwners implementation"
This reverts commit 10dbd7babd.

Reason for revert: removal broke builders

Original change's description:
> Remove old DepotToolsOwners implementation
>
> code-owners should have been enabled for most hosts that depot_tools
> supports by now. Remove our own implementation and rely on code-owners.
>
> Change-Id: Iaf0d3db65b2e5063b67d42b92188c4ec51d2cd9a
> Reviewed-on: https://chromium-review.googlesource.com/c/chromium/tools/depot_tools/+/3783475
> Reviewed-by: Aravind Vasudevan <aravindvasudev@google.com>
> Reviewed-by: Joanna Wang <jojwang@chromium.org>
> Commit-Queue: Gavin Mak <gavinmak@google.com>

Change-Id: I781648f470e8f2c9d408ae7112cfc41060f5385d
No-Presubmit: true
No-Tree-Checks: true
No-Try: true
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/tools/depot_tools/+/3818251
Auto-Submit: Gavin Mak <gavinmak@google.com>
Reviewed-by: Aravind Vasudevan <aravindvasudev@google.com>
Commit-Queue: Aravind Vasudevan <aravindvasudev@google.com>
3 years ago
Gavin Mak 10dbd7babd Remove old DepotToolsOwners implementation
code-owners should have been enabled for most hosts that depot_tools
supports by now. Remove our own implementation and rely on code-owners.

Change-Id: Iaf0d3db65b2e5063b67d42b92188c4ec51d2cd9a
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/tools/depot_tools/+/3783475
Reviewed-by: Aravind Vasudevan <aravindvasudev@google.com>
Reviewed-by: Joanna Wang <jojwang@chromium.org>
Commit-Queue: Gavin Mak <gavinmak@google.com>
3 years ago
Edward Lesmes 8170c29fd1 Reland "presubmit: Skip owners checks if code-owners plugin is enabled."
This is a reland of 2cf835a9ba

URL-encoded repo path, so chromium/src becomes chromium%2Fsrc
as Gerrit expects

Original change's description:
> presubmit: Skip owners checks if code-owners plugin is enabled.
>
> If code-owners plugin is enable for the repo, skip owners check on
> commit, and skip checking owners format, as that will be done by
> the plugin.
>
> Change-Id: I1663baef4f0f27b00423071343fe740f6da50ce7
> Reviewed-on: https://chromium-review.googlesource.com/c/chromium/tools/depot_tools/+/2727131
> Auto-Submit: Edward Lesmes <ehmaldonado@chromium.org>
> Reviewed-by: Gavin Mak <gavinmak@google.com>
> Commit-Queue: Edward Lesmes <ehmaldonado@chromium.org>

Change-Id: I3038590f3a92cbf7b6dc0ba6eb47f72593a2ccf7
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/tools/depot_tools/+/2775840
Auto-Submit: Edward Lesmes <ehmaldonado@chromium.org>
Commit-Queue: Edward Lesmes <ehmaldonado@chromium.org>
Reviewed-by: Gavin Mak <gavinmak@google.com>
4 years ago
Edward Lesmes 88f712e012 code-owners: Use Gerrit code-owners if available
Problems interpreting OWNERS files have been fixed upstream.

Bug: 1183447
Change-Id: Ifd065d87b4244fc3ce2f27291b603acfedbb5d39
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/tools/depot_tools/+/2753447
Auto-Submit: Edward Lesmes <ehmaldonado@chromium.org>
Reviewed-by: Edwin Kempin <ekempin@google.com>
Reviewed-by: Gavin Mak <gavinmak@google.com>
Reviewed-by: Josip Sokcevic <sokcevic@google.com>
Commit-Queue: Edward Lesmes <ehmaldonado@chromium.org>
4 years ago
Edward Lesmes 23c3bdc950 owners: Simplify logic to score and suggest owners.
Keep adding owners in the order suggested by Gerrit until coverage is
achieved instead of finding a minimal set of owners, as that takes too
long

Bug: 1186420
Change-Id: Id2ab172db0b2e83ab950191958813163099181be
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/tools/depot_tools/+/2751343
Reviewed-by: Josip Sokcevic <sokcevic@google.com>
Reviewed-by: Gavin Mak <gavinmak@google.com>
Commit-Queue: Edward Lesmes <ehmaldonado@chromium.org>
Auto-Submit: Edward Lesmes <ehmaldonado@chromium.org>
4 years ago
Edward Lesmes 1eaaab5c1f Add upstream parameter when building an owners client.
code-owners plugins wants a git ref in Gerrit (e.g. refs/heads/master)
while Depot Tools wants a local git ref (e.g. refs/remotes/origin/main,
or a git hash).

Add an upstream parameters to be used by Depot Tools, separate from
a Gerrit ref expected by owners_client.

Change-Id: Ieed97a186e3140b3f82830efa189dbe3e4d8c806
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/tools/depot_tools/+/2730049
Commit-Queue: Edward Lesmes <ehmaldonado@chromium.org>
Commit-Queue: Josip Sokcevic <sokcevic@google.com>
Auto-Submit: Edward Lesmes <ehmaldonado@chromium.org>
Reviewed-by: Josip Sokcevic <sokcevic@google.com>
4 years ago
Edward Lesmes 3bbd43d85f owners: Set correct branch to compute diff.
We have to use refs/remotes/origin/foo instead of refs/heads/foo,
as refs/heads/foo might not be defined.

https://logs.chromium.org/logs/infra-internal/buildbucket/cr-buildbucket.appspot.com/8853851694141987488/+/u/build/git_cl_upload/stdout

Change-Id: Ic729510d7beca63c25ea84394758cb62f76c572f
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/tools/depot_tools/+/2729615
Auto-Submit: Edward Lesmes <ehmaldonado@chromium.org>
Commit-Queue: Josip Sokcevic <sokcevic@google.com>
Reviewed-by: Josip Sokcevic <sokcevic@google.com>
4 years ago
Edward Lesmes b87cca8444 owners: Use DepotToolsClient while code-owners plugin is fixed.
Bug: 1183447
Change-Id: I11c67b13ace08eb5bafb90756bd45af6ff39f12f
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/tools/depot_tools/+/2727569
Auto-Submit: Edward Lesmes <ehmaldonado@chromium.org>
Reviewed-by: Gavin Mak <gavinmak@google.com>
Commit-Queue: Edward Lesmes <ehmaldonado@chromium.org>
4 years ago
Gavin Mak 7d690053cb owners_client: Handle missing email in AccountInfo
Bug: 1180316
Change-Id: I8390f72d8a6cd1044ce10b7cbd4573a004a9730c
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/tools/depot_tools/+/2705614
Reviewed-by: Edward Lesmes <ehmaldonado@chromium.org>
Commit-Queue: Gavin Mak <gavinmak@google.com>
4 years ago
Stephen Martinis fb09de29ea Revert "Use GetCodeOwnersClient in presubmit_support"
This reverts commit 7a67bca65a.

Reason for revert: Probably broke chromium presubmit, see https://ci.chromium.org/ui/p/chromium/builders/try/chromium_presubmit/1152280/overview

Original change's description:
> Use GetCodeOwnersClient in presubmit_support
>
> This change also adds a target_ref flag to presubmit_support.py.
>
> Recipe-Nontrivial-Roll: build
> Change-Id: I6de6bb87fc1482b88d9fbebe5e4ad1dbd8ce9748
> Reviewed-on: https://chromium-review.googlesource.com/c/chromium/tools/depot_tools/+/2702792
> Commit-Queue: Gavin Mak <gavinmak@google.com>
> Reviewed-by: Edward Lesmes <ehmaldonado@chromium.org>
> Reviewed-by: Josip Sokcevic <sokcevic@google.com>

Change-Id: I2cca469f14194f65306baab7928ddddd48033a3b
No-Presubmit: true
No-Tree-Checks: true
No-Try: true
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/tools/depot_tools/+/2718691
Auto-Submit: Stephen Martinis <martiniss@chromium.org>
Commit-Queue: Rubber Stamper <rubber-stamper@appspot.gserviceaccount.com>
Bot-Commit: Rubber Stamper <rubber-stamper@appspot.gserviceaccount.com>
4 years ago
Gavin Mak 7a67bca65a Use GetCodeOwnersClient in presubmit_support
This change also adds a target_ref flag to presubmit_support.py.

Recipe-Nontrivial-Roll: build
Change-Id: I6de6bb87fc1482b88d9fbebe5e4ad1dbd8ce9748
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/tools/depot_tools/+/2702792
Commit-Queue: Gavin Mak <gavinmak@google.com>
Reviewed-by: Edward Lesmes <ehmaldonado@chromium.org>
Reviewed-by: Josip Sokcevic <sokcevic@google.com>
4 years ago
Edward Lesmes 5e37f6ded4 owners_client: Always use slashes as separators.
Change-Id: I6a74971878e5a1abaf6d8f5db20d0387c1abf308
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/tools/depot_tools/+/2701392
Auto-Submit: Edward Lesmes <ehmaldonado@chromium.org>
Reviewed-by: Josip Sokcevic <sokcevic@google.com>
Reviewed-by: Gavin Mak <gavinmak@google.com>
Commit-Queue: Edward Lesmes <ehmaldonado@chromium.org>
4 years ago
Edward Lesmes 0d1bdb23c1 owners: Cache code-owners result.
Cache result of ListOwners to avoid making duplicate REST API calls.

Change-Id: Ie97fd7b605b73e1baed74302615f9df44fb622d2
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/tools/depot_tools/+/2693914
Auto-Submit: Edward Lesmes <ehmaldonado@chromium.org>
Reviewed-by: Gavin Mak <gavinmak@google.com>
Commit-Queue: Edward Lesmes <ehmaldonado@chromium.org>
4 years ago
Edward Lesmes 110823ba4d Add a GetCodeOwnersClient method.
GetCodeOwnersClient will return a GerritClient instance
if code-owners is enabled for the host, and will fall
back to DepotToolsClient otherwise.

Change-Id: I303147f36cb28ae3a40649fee020e6ea459b2c73
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/tools/depot_tools/+/2676989
Reviewed-by: Gavin Mak <gavinmak@google.com>
Reviewed-by: Josip Sokcevic <sokcevic@google.com>
Commit-Queue: Edward Lesmes <ehmaldonado@chromium.org>
4 years ago
Edward Lesmes 0e2aee7e97 owners-client: Add support for excluding owners.
It is useful to exclude the change author when suggesting owners.

Change-Id: I3321c013271f6cea1098abba59b509800818917e
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/tools/depot_tools/+/2669680
Commit-Queue: Edward Lesmes <ehmaldonado@chromium.org>
Auto-Submit: Edward Lesmes <ehmaldonado@chromium.org>
Reviewed-by: Josip Sokcevic <sokcevic@google.com>
4 years ago
Gavin Mak 0f790421b2 Update ListOwners for GerritClient in owners_client
The REST endpoint used by GerritClient.ListOwners needs to be updated as
of https://gerrit-review.googlesource.com/c/plugins/code-owners/+/293806

Change-Id: I5c142f16443b157c9d8edfa5bcf418cbedd2b193
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/tools/depot_tools/+/2658609
Reviewed-by: Edward Lesmes <ehmaldonado@chromium.org>
Commit-Queue: Gavin Mak <gavinmak@google.com>
4 years ago
Gavin Mak d36dbbd730 [owners] Use owners_client in owners_finder.py
This change also adds a ScoreOwners function in owners_client
that replaces user scoring functionality in owners_finder.

Change-Id: Ifd8841c6d320d9bb644907b6eca0a02d4ef35640
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/tools/depot_tools/+/2641532
Reviewed-by: Edward Lesmes <ehmaldonado@chromium.org>
Commit-Queue: Gavin Mak <gavinmak@google.com>
4 years ago
Edward Lesmes 071c3b1b31 owners: Support '*' when checking approval status.
Bug: 1166467
Change-Id: Ib6c32b11ca2892841cad477cee61edef38a0ed62
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/tools/depot_tools/+/2628702
Auto-Submit: Edward Lesmes <ehmaldonado@chromium.org>
Commit-Queue: Gavin Mak <gavinmak@google.com>
Reviewed-by: Gavin Mak <gavinmak@google.com>
4 years ago
Edward Lesmes c40b2406de owners: Move constants inside OwnersClient.
When used as part of presubmit's input_api, we only
expose OwnersClient and not global constants, so
move constants inside OwnersClient.

Change-Id: I8983c5edadafeebff62838d9cd4a19fdce908159
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/tools/depot_tools/+/2621744
Commit-Queue: Edward Lesmes <ehmaldonado@chromium.org>
Auto-Submit: Edward Lesmes <ehmaldonado@chromium.org>
Reviewed-by: Gavin Mak <gavinmak@google.com>
Reviewed-by: Josip Sokcevic <sokcevic@google.com>
4 years ago
Edward Lesmes 82b992a165 owners: Initialize db lazily.
This makes it easier to test, e.g. we can mock
DepotToolsClient.BatchListOwners without having to
mock DepotToolsClient first (to avoid initialization).

Change-Id: I9c24ef28ba7a82cd1498e863cc1b4bc825a579d1
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/tools/depot_tools/+/2616900
Reviewed-by: Gavin Mak <gavinmak@google.com>
Commit-Queue: Edward Lesmes <ehmaldonado@chromium.org>
Auto-Submit: Edward Lesmes <ehmaldonado@chromium.org>
4 years ago
Edward Lesmes 0e4e5ae594 Reland "[owners] Refactor OwnersClient."
Reland of [1].
Original CL contained some changes to --[tb]r-owners
which are not included in this CL because those changes
were reverted on [2].

- Remove GetChangeApprovalStatus and GetFilesApprovalStatus.
- Make host, project and branch part of GerritClient.
- Rename ListOwnersForFile to ListOwners.

[1] https://chromium-review.googlesource.com/c/chromium/tools/depot_tools/+/2587268
[2] https://chromium-review.googlesource.com/c/chromium/tools/depot_tools/+/2611219

Change-Id: Ife2051b8be0460d1c6bc4fbe4e3b0a571d12dafb
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/tools/depot_tools/+/2616130
Auto-Submit: Edward Lesmes <ehmaldonado@chromium.org>
Commit-Queue: Edward Lesmes <ehmaldonado@chromium.org>
Reviewed-by: Josip Sokcevic <sokcevic@google.com>
4 years ago
Edward Lesmes b34cd6d8fa Revert "[owners] Refactor OwnersClient."
This reverts commit 9c7f6c25c0.

Reason for revert:
Not working
https://logs.chromium.org/logs/infra-internal/buildbucket/cr-buildbucket.appspot.com/8858807889610091152/+/steps/franky/0/steps/git_cl_upload/0/stdout

Original change's description:
> [owners] Refactor OwnersClient.
>
> - Remove GetChangeApprovalStatus and GetFilesApprovalStatus.
> - Make host, project and branch part of GerritClient.
> - Rename ListOwnersForFile to ListOwners.
>
> Change-Id: I1f610a64f0217ce54e5ce4a210026535adc1c2e5
> Reviewed-on: https://chromium-review.googlesource.com/c/chromium/tools/depot_tools/+/2587268
> Commit-Queue: Edward Lesmes <ehmaldonado@chromium.org>
> Reviewed-by: Gavin Mak <gavinmak@google.com>

TBR=ehmaldonado@chromium.org,gavinmak@google.com,infra-scoped@luci-project-accounts.iam.gserviceaccount.com,sokcevic@google.com

# Not skipping CQ checks because original CL landed > 1 day ago.

Change-Id: I4928df90856526210a4fd4d104e6cc96aa005bc2
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/tools/depot_tools/+/2613925
Commit-Queue: Edward Lesmes <ehmaldonado@chromium.org>
Reviewed-by: Stephen Martinis <martiniss@chromium.org>
Reviewed-by: Edward Lesmes <ehmaldonado@chromium.org>
4 years ago
Edward Lesmes 9c7f6c25c0 [owners] Refactor OwnersClient.
- Remove GetChangeApprovalStatus and GetFilesApprovalStatus.
- Make host, project and branch part of GerritClient.
- Rename ListOwnersForFile to ListOwners.

Change-Id: I1f610a64f0217ce54e5ce4a210026535adc1c2e5
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/tools/depot_tools/+/2587268
Commit-Queue: Edward Lesmes <ehmaldonado@chromium.org>
Reviewed-by: Gavin Mak <gavinmak@google.com>
4 years ago
Gavin Mak 99399caeac [owners] Add BatchListOwners
BatchListOwners uses git_common's ScopedPool method to run
ListOwnersForFile in parallel for multiple paths.

Change-Id: I545072e16181407665c8b009f87fccfb7355d7d8
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/tools/depot_tools/+/2585657
Reviewed-by: Edward Lesmes <ehmaldonado@chromium.org>
Commit-Queue: Gavin Mak <gavinmak@google.com>
4 years ago
Gavin Mak c94b21d60c [owners] Use new API to list owners for file
This change implements ListOwnersForFile using gerrit's REST API in owners_client.py
Change-Id: Ic454dcd89a8f00f6b9e913e6b8ee9e1169581b38
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/tools/depot_tools/+/2583327
Reviewed-by: Edward Lesmes <ehmaldonado@chromium.org>
Commit-Queue: Gavin Mak <gavinmak@google.com>
4 years ago
Edward Lesmes ca45aff391 [owners] Fix SuggestOwners when there is only one owner.
If there are less than two owners for the given paths,
current implementation will get stuck in infinite loop.

Change it to return any possible owner.

Change-Id: I75f18e0a00057c58d227dac23dc8572f1fba23f5
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/tools/depot_tools/+/2572802
Auto-Submit: Edward Lesmes <ehmaldonado@chromium.org>
Commit-Queue: Josip Sokcevic <sokcevic@google.com>
Reviewed-by: Josip Sokcevic <sokcevic@google.com>
4 years ago
Edward Lesmes 8a791e7cf7 [git-cl][owners] Use new API to suggest batch owners.
Change-Id: I2e2b0aff583e6d9b36261acbef87221e29fe7923
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/tools/depot_tools/+/2565145
Reviewed-by: Josip Sokcevic <sokcevic@google.com>
Commit-Queue: Edward Lesmes <ehmaldonado@chromium.org>
4 years ago
Edward Lesmes 295dd1879f [owners] Add SuggestOwners to OwnersClient.
Gerrit API doesn't provide the score for
an owner of a path, so we can't use the
same algorithm when suggesting owners.

This change introduces a new algorithm to
select the smallest set of at least 2
owners that can approve the change.

Change-Id: If620073bdf63633f171c1480e345dbaf75e9f575
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/tools/depot_tools/+/2556479
Reviewed-by: Josip Sokcevic <sokcevic@google.com>
Commit-Queue: Edward Lesmes <ehmaldonado@chromium.org>
4 years ago
Edward Lesmes 64e80769c4 [owners] Sort owners by distance
Change-Id: Id10af7bb2fa821c369952402853fae5c847b2f5d
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/tools/depot_tools/+/2556478
Commit-Queue: Edward Lesmes <ehmaldonado@chromium.org>
Auto-Submit: Edward Lesmes <ehmaldonado@chromium.org>
Reviewed-by: Josip Sokcevic <sokcevic@google.com>
4 years ago
Edward Lesmes eeca9c6ee7 [owners][git-cl] Use owners client to show all owners for a file.
Change-Id: I04949d95ca466452a58ea91cf2db86852c0621bd
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/tools/depot_tools/+/2551378
Commit-Queue: Edward Lesmes <ehmaldonado@chromium.org>
Auto-Submit: Edward Lesmes <ehmaldonado@chromium.org>
Reviewed-by: Anthony Polito <apolito@google.com>
4 years ago
Edward Lesmes e7d1862b15 [owners] Implement GetFilesApprovalStatus for OwnersClient.
Add a utility method to check approval status for files
when no change has been created yet.

Change-Id: I4cc47e2f598cedc7b7aab68bed356bd3ae566cc0
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/tools/depot_tools/+/2551373
Commit-Queue: Edward Lesmes <ehmaldonado@chromium.org>
Auto-Submit: Edward Lesmes <ehmaldonado@chromium.org>
Reviewed-by: Anthony Polito <apolito@google.com>
4 years ago
Edward Lesmes b472168267 [owners] Validate owners config in Depot Tools client.
Change-Id: Ia9cb19d2b1f776c41ef7e96e6a0ebfb0fcd41344
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/tools/depot_tools/+/2548029
Auto-Submit: Edward Lesmes <ehmaldonado@chromium.org>
Commit-Queue: Anthony Polito <apolito@google.com>
Reviewed-by: Anthony Polito <apolito@google.com>
4 years ago
Edward Lesmes 829ce021d5 [owners] Add tests for Depot Tools owners client.
Change-Id: I988f5b866560d5839a1121c7129099ffe125fdce
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/tools/depot_tools/+/2545108
Reviewed-by: Josip Sokcevic <sokcevic@google.com>
Commit-Queue: Edward Lesmes <ehmaldonado@chromium.org>
4 years ago
Edward Lesmes d4e6fb6573 [owners] Implement GetChangeApprovalStatus for Depot Tools
Change-Id: I2d24e4e02e099381e10b29c7e9a09d530cde4a40
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/tools/depot_tools/+/2536817
Reviewed-by: Anthony Polito <apolito@google.com>
Commit-Queue: Edward Lesmes <ehmaldonado@chromium.org>
4 years ago
Edward Lesmes b4f4226d15 [owners] Implement ListOwnersForFile for Depot Tools
Add DepotToolsClient to implement the OwnersClient API
for Depot Tools, and implement the ListOwnersForFile method.

Change-Id: I933a262898439d879c919d695aa62d7702b4c9a4
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/tools/depot_tools/+/2530509
Auto-Submit: Edward Lesmes <ehmaldonado@chromium.org>
Reviewed-by: Anthony Polito <apolito@google.com>
Commit-Queue: Edward Lesmes <ehmaldonado@chromium.org>
4 years ago
Edward Lesmes 91bb7506bd [depot_tools][owners] Add owners client to depot_tools.
Add an owners API that will be used by Depot Tools to
interact with OWNERS files.

The API will be implemented using both owners.py and the
Gerrit Code-Owners plugin REST API. All Depot Tools code
will be modified to use this API.

Change-Id: I7cf059a0895dbae105a2f0b26568fd7b47068f43
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/tools/depot_tools/+/2517985
Reviewed-by: Anthony Polito <apolito@google.com>
Commit-Queue: Anthony Polito <apolito@google.com>
4 years ago