After r219657 (bug #173559) we're getting a weird style checker error in some patches: * https://bugs.webkit.org/show_bug.cgi?id=174675#c5 * https://bugs.webkit.org/show_bug.cgi?id=174451#c29 Traceback (most recent call last): File "Tools/Scripts/check-webkit-style", line 48, in <module> sys.exit(CheckWebKitStyle().main()) File "/Volumes/Data/StyleQueue/WebKit/Tools/Scripts/webkitpy/style/main.py", line 155, in main patch_checker.check(patch) File "/Volumes/Data/StyleQueue/WebKit/Tools/Scripts/webkitpy/style/patchreader.py", line 71, in check self._text_file_reader.process_file(file_path=path, line_numbers=None) File "/Volumes/Data/StyleQueue/WebKit/Tools/Scripts/webkitpy/style/filereader.py", line 119, in process_file self._files[abs_file_path] = self._files[abs_file_path] + kwargs['line_numbers'] TypeError: can only concatenate list (not "NoneType") to list
Created attachment 316291 [details] Patch
A bit surprised we didn't have a unit test for this. It's a simple fix, added a test as well.
Comment on attachment 316291 [details] Patch View in context: https://bugs.webkit.org/attachment.cgi?id=316291&action=review > Tools/Scripts/webkitpy/style/filereader.py:115 > + if 'line_numbers' in kwargs and kwargs['line_numbers']: Please check if we can simplify this to if kwargs.get('line_numbers'): > Tools/Scripts/webkitpy/style/main_unittest.py:165 > + def test_linter_added_file(self): Nit: should this name be more descriptive?
Created attachment 316299 [details] Patch
Created attachment 316300 [details] Patch for landing
Comment on attachment 316300 [details] Patch for landing Clearing flags on attachment: 316300 Committed r219827: <http://trac.webkit.org/changeset/219827>
All reviewed patches have been landed. Closing bug.