mirror of
https://chromium.googlesource.com/chromium/tools/depot_tools.git
synced 2026-01-11 10:41:31 +00:00
Change to slash separator to fix a bug on Windows in owners.py
Some of the owners.py code does not change file path to use the slash separator, causing owners check to crash on Windows. This CL fixes it. Change-Id: I6e06a235dbb563ea45691f19b03d826b23184b2b Reviewed-on: https://chromium-review.googlesource.com/c/chromium/tools/depot_tools/+/2626090 Reviewed-by: Dirk Pranke <dpranke@google.com> Commit-Queue: Mandy Chen <mandy.chen@microsoft.com>
This commit is contained in:
@@ -513,7 +513,12 @@ class Database(object):
|
||||
return owners
|
||||
|
||||
def _covering_set_of_owners_for(self, files, author):
|
||||
dirs_remaining = set(self.enclosing_dir_with_owners(f) for f in files)
|
||||
dirs_remaining = set()
|
||||
for f in files:
|
||||
dir_path = self.enclosing_dir_with_owners(f)
|
||||
# Always use slashes as separators.
|
||||
dirs_remaining.add(dir_path.replace(os.sep, '/'))
|
||||
|
||||
all_possible_owners = self.all_possible_owners(dirs_remaining, author)
|
||||
suggested_owners = set()
|
||||
while dirs_remaining and all_possible_owners:
|
||||
|
||||
Reference in New Issue
Block a user