lint: Enforce whitespace between : and value in dicts.

This commit is contained in:
Tim Abbott 2016-04-27 22:20:58 -07:00
parent aebe7334a4
commit 302da832fa

View File

@ -147,6 +147,10 @@ python_rules = [
# This rule is constructed with + to avoid triggering on itself
{'pattern': " =" + '[^ =>~"]',
'description': 'Missing whitespace after "="'},
{'pattern': '":\w[^"]*$',
'description': 'Missing whitespace after ":"'},
{'pattern': "':\w[^']*$",
'description': 'Missing whitespace after ":"'},
# This next check could have false positives, but it seems pretty
# rare; if we find any, they can be added to the exclude list for
# this rule.