From d786989450ff35e91d30cc395bf4be5fc8cac1b1 Mon Sep 17 00:00:00 2001 From: lethosor Date: Mon, 14 Nov 2022 22:10:05 -0500 Subject: [PATCH] Revert "Allowing whitespace-only lines." This makes lint.py's behavior match pre-commit, which is useful because lint.py errors show up inline on GitHub PRs. This reverts commit ebb3dc48bf3cb3e460cd4eef1645425b8565f6b4 --- ci/lint.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/ci/lint.py b/ci/lint.py index b2fb8e647..f2c01cd9c 100755 --- a/ci/lint.py +++ b/ci/lint.py @@ -97,7 +97,7 @@ class TrailingWhitespaceLinter(Linter): msg = 'Contains trailing whitespace' def check_line(self, line): line = line.replace('\r', '').replace('\n', '') - return not line.strip() or line == line.rstrip('\t ') + return line == line.rstrip('\t ') def fix_line(self, line): return line.rstrip('\t ')