From 5f60258a8523ba9312bf31257e74cc9fb2dc6698 Mon Sep 17 00:00:00 2001 From: Vamshi Balanaga Date: Tue, 29 Nov 2016 21:11:29 -0500 Subject: [PATCH] pep8: Fix E211 violations. --- tools/lint-all | 2 +- tools/minify-js | 2 +- zerver/lib/actions.py | 2 +- zerver/tests/test_subs.py | 2 +- 4 files changed, 4 insertions(+), 4 deletions(-) diff --git a/tools/lint-all b/tools/lint-all index 4ded579473..9b7fbb239b 100755 --- a/tools/lint-all +++ b/tools/lint-all @@ -85,7 +85,7 @@ def check_pep8(files): 'E402', 'E501', 'W503', 'E711', 'E201', 'E203', 'E202', 'E128', 'E226', 'E124', 'E126', 'E127', 'E121', 'E122', 'E123', 'E266', 'E265', 'E261', 'E221', 'E303', 'E241', 'E712', 'E702', 'E401', 'E115', 'E114', 'E111', 'E731', 'E302', 'E129', - 'E741', 'E714', 'W391', 'E211', 'E713', 'E502', 'E131', 'E305', 'E251', 'E306', + 'E741', 'E714', 'W391', 'E713', 'E502', 'E131', 'E305', 'E251', 'E306', ] pep8 = subprocess.Popen( ['pycodestyle'] + files + ['--ignore={rules}'.format(rules=','.join(ignored_rules))], diff --git a/tools/minify-js b/tools/minify-js index df85920ae9..88f365d155 100755 --- a/tools/minify-js +++ b/tools/minify-js @@ -54,7 +54,7 @@ def get_changed_source_files(other_checkout): # If git returned an error, assume we can't reuse any files, and # regenerate everything. print("Warning: git returned an error when comparing to the previous") - print ("deploy in %s. Will re-minify JavaScript instead of reusing" + print("deploy in %s. Will re-minify JavaScript instead of reusing" % (other_checkout,)) return None diff --git a/zerver/lib/actions.py b/zerver/lib/actions.py index ec76d4ad66..3d988e4e10 100644 --- a/zerver/lib/actions.py +++ b/zerver/lib/actions.py @@ -691,7 +691,7 @@ def compute_mit_user_fullname(email): except DNS.Base.ServerError: pass except: - print ("Error getting fullname for %s:" % (email,)) + print("Error getting fullname for %s:" % (email,)) traceback.print_exc() return email.lower() diff --git a/zerver/tests/test_subs.py b/zerver/tests/test_subs.py index 9b18fae2e2..ff148ebdef 100644 --- a/zerver/tests/test_subs.py +++ b/zerver/tests/test_subs.py @@ -1032,7 +1032,7 @@ class SubscriptionRestApiTest(ZulipTestCase): user_profile.full_name = 'Hamlet' user_profile.save() - def method1 (req, user_profile): + def method1(req, user_profile): # type: (HttpRequest, UserProfile) -> HttpResponse user_profile.full_name = 'Should not be committed' user_profile.save()