lint: Remove custom whitespace rules already enforced by Black.

Signed-off-by: Anders Kaseorg <anders@zulip.com>
This commit is contained in:
Anders Kaseorg 2021-02-17 15:39:00 -08:00 committed by Tim Abbott
parent 138d67e852
commit ca0b01033d
1 changed files with 0 additions and 21 deletions

View File

@ -283,14 +283,6 @@ python_rules = RuleList(
"good_lines": ["def foo (self):"],
"bad_lines": ["def foo(self: Any):"],
},
{
"pattern": r"^\s+#\w",
"strip": "\n",
"exclude": {"tools/droplets/create.py"},
"description": 'Missing whitespace after "#"',
"good_lines": ["a = b # some operation", "1+2 # 3 is the result"],
"bad_lines": [" #some operation", " #not valid!!!"],
},
{
"pattern": "assertEquals[(]",
"description": "Use assertEqual, not assertEquals (which is deprecated).",
@ -308,18 +300,6 @@ python_rules = RuleList(
"foo = bar # type: ignore # explanation",
],
},
{
"pattern": r"\b(if|else|while)[(]",
"description": "Put a space between statements like if, else, etc. and (.",
"good_lines": ["if (1 == 2):", "while (foo == bar):"],
"bad_lines": ["if(1 == 2):", "while(foo == bar):"],
},
{
"pattern": ", [)]",
"description": 'Unnecessary whitespace between "," and ")"',
"good_lines": ["foo = (1, 2, 3,)", "foo(bar, 42)"],
"bad_lines": ["foo = (1, 2, 3, )"],
},
{
"pattern": r"\bsudo\b",
"include_only": {"scripts/"},
@ -512,7 +492,6 @@ python_rules = RuleList(
"description": 'A mock function is missing a leading "assert_"',
},
*whitespace_rules,
*comma_whitespace_rule,
],
max_length=110,
shebang_rules=shebang_rules,