Commit 71c6d079 authored by Weilun Shi's avatar Weilun Shi Committed by Commit Bot

Normalize histogram paths before comparing them

We should normalize histogram paths in the validate_histograms_index.py
before checking whether they are the same.

This is to fix the issue that the path separator is different between
Windows and Linux.

Change-Id: I5806886a192b3a15512f76631e324d9f1cc9bc46
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/2381092
Auto-Submit: Weilun Shi <sweilun@chromium.org>
Commit-Queue: Alexei Svitkine <asvitkine@chromium.org>
Reviewed-by: default avatarAlexei Svitkine <asvitkine@chromium.org>
Cr-Commit-Position: refs/heads/master@{#802794}
parent a9be7457
......@@ -17,7 +17,7 @@ import path_util
def main():
exit_code = 0
with open(histogram_paths.HISTOGRAMS_INDEX, 'r') as f:
histograms_paths = [line.strip() for line in f]
histograms_paths = [os.path.normpath(line.strip()) for line in f]
if histograms_paths != histogram_paths.HISTOGRAMS_XMLS_RELATIVE:
exit_code = 1
logging.error(
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment