Normalize input mojom paths for presubmit check
The presubmit input API provides local path names in the OS's native format. The mojom compatibility checking script effectively assumes POSIX format. This leads to various wonderful forms of failure whenever paths are used to represent module identity in scripts. In this case, mismatches between changed input file paths and mojom import paths can result in the stability checking tool using the newer (i.e. post-change) version of an input file when processing the older (pre-change) contents of other files. This can obviously lead to very surprising behavior like missing type information. In the limit we should be using pathlib to manipulate paths consistently across platforms. For now, this change settles on rewriting the tool's input paths to be in POSIX form consistently. Fixed: 1096841 Change-Id: I4beff9a49d573df3815160e2320097886d94d692 Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/2254709 Auto-Submit: Ken Rockot <rockot@google.com> Reviewed-by:Oksana Zhuravlova <oksamyt@chromium.org> Commit-Queue: Ken Rockot <rockot@google.com> Cr-Commit-Position: refs/heads/master@{#780406}
Showing
Please register or sign in to comment