[webkit-changes] [WebKit/WebKit] 3cd22d: check-webkit-style: file path based skip rules don...

Fujii Hironori noreply at github.com
Tue Oct 1 14:14:22 PDT 2024


  Branch: refs/heads/main
  Home:   https://github.com/WebKit/WebKit
  Commit: 3cd22d8b906980450a3d3082e4aaaf93a729955b
      https://github.com/WebKit/WebKit/commit/3cd22d8b906980450a3d3082e4aaaf93a729955b
  Author: Fujii Hironori <Hironori.Fujii at sony.com>
  Date:   2024-10-01 (Tue, 01 Oct 2024)

  Changed paths:
    M Tools/Scripts/webkitpy/style/patchreader.py
    M Tools/Scripts/webkitpy/style/patchreader_unittest.py

  Log Message:
  -----------
  check-webkit-style: file path based skip rules don't work as expected in the diff mode with Windows Python
https://bugs.webkit.org/show_bug.cgi?id=280662

Reviewed by Jonathan Bedard.

check-webkit-style has two modes, the diff mode and the file mode. The
diff mode checks only the content inside specified diff files. The
file mode checks the entire content of specified files.

check-webkit-style has a lot of file path based skip rules.
<https://github.com/WebKit/WebKit/blob/524c5c896dca0d3f5363b0d9cb95558ab3678f06/Tools/Scripts/webkitpy/style/checker.py#L466-L531>
<https://commits.webkit.org/167707@main> started to use os.path.join
and os.path.sep for them to use OS-specific path separators.

The file path based skip rules didn't work as expected in the diff
mode on Windows Python because file paths retrived from diff files
were Unix paths.

Convert the Unix path separators to OS-specific path separators.

* Tools/Scripts/webkitpy/style/patchreader.py:
(PatchReader.check):
* Tools/Scripts/webkitpy/style/patchreader_unittest.py:
(PatchReaderTest.test_check_patch):

Canonical link: https://commits.webkit.org/284512@main



To unsubscribe from these emails, change your notification settings at https://github.com/WebKit/WebKit/settings/notifications


More information about the webkit-changes mailing list