mirror of https://github.com/zulip/zulip.git
lint: clean up PEP-8 W391 rule.
This commit is contained in:
parent
f4d3cc6545
commit
bde2da7dfd
|
@ -91,4 +91,3 @@ def run_message_handler_for_bot(lib_module, quiet, config_file):
|
|||
|
||||
logging.info('starting message handling...')
|
||||
client.call_on_each_message(handle_message)
|
||||
|
||||
|
|
|
@ -128,4 +128,3 @@ class JohnHandler(object):
|
|||
))
|
||||
|
||||
handler_class = JohnHandler
|
||||
|
||||
|
|
|
@ -49,5 +49,3 @@ if __name__ == "__main__":
|
|||
|
||||
print(result)
|
||||
exit(ret)
|
||||
|
||||
|
||||
|
|
|
@ -181,5 +181,3 @@ def test_the_api(client):
|
|||
test_messages(client)
|
||||
|
||||
# print(dir(client))
|
||||
|
||||
|
||||
|
|
|
@ -87,8 +87,7 @@ def check_pep8(files):
|
|||
# ignored. It either doesn't fit with the style of the project or should
|
||||
# actually be cleaned up.
|
||||
#
|
||||
'W391', 'W503',
|
||||
|
||||
'W503',
|
||||
'E114', 'E115', 'E121', 'E123', 'E126', 'E226', 'E241', 'E261', 'E302',
|
||||
'E305', 'E306', 'E401', 'E501', 'E702', 'E711', 'E712', 'E713', 'E714',
|
||||
'E741',
|
||||
|
|
|
@ -25,4 +25,3 @@ def user_avatar_hash(email):
|
|||
# replacement.
|
||||
user_key = email.lower() + settings.AVATAR_SALT
|
||||
return make_safe_digest(user_key, hashlib.sha1)
|
||||
|
||||
|
|
|
@ -27,4 +27,3 @@ def check_valid_emoji_name(emoji_name):
|
|||
if re.match('^[0-9a-zA-Z.\-_]+(?<![.\-_])$', emoji_name):
|
||||
return
|
||||
raise JsonableError(_("Invalid characters in emoji name"))
|
||||
|
||||
|
|
|
@ -85,5 +85,3 @@ class Command(BaseCommand):
|
|||
send_mail(subject, body, from_email, [to_email], html_message=html_email)
|
||||
else:
|
||||
send_mail(subject, body, from_email, [to_email])
|
||||
|
||||
|
||||
|
|
|
@ -19,4 +19,3 @@ def set_descriptor_by_handler_id(handler_id, client_descriptor):
|
|||
def clear_descriptor_by_handler_id(handler_id, client_descriptor):
|
||||
# type: (int, Optional[zerver.tornado.event_queue.ClientDescriptor]) -> None
|
||||
del descriptors_by_handler_id[handler_id]
|
||||
|
||||
|
|
|
@ -48,4 +48,3 @@ def events_register_backend(request, user_profile, apply_markdown=True,
|
|||
event_types, queue_lifespan_secs, all_public_streams,
|
||||
narrow=narrow)
|
||||
return json_success(ret)
|
||||
|
||||
|
|
|
@ -339,4 +339,3 @@ def is_buggy_ua(agent):
|
|||
"""
|
||||
return ("Humbug Desktop/" in agent or "Zulip Desktop/" in agent or "ZulipDesktop/" in agent) and \
|
||||
"Mac" not in agent
|
||||
|
||||
|
|
|
@ -95,4 +95,3 @@ def json_refer_friend(request, user_profile, email=REQ()):
|
|||
do_refer_friend(user_profile, email)
|
||||
|
||||
return json_success()
|
||||
|
||||
|
|
|
@ -18,4 +18,3 @@ def json_set_muted_topics(request, user_profile,
|
|||
# type: (HttpRequest, UserProfile, List[List[Text]]) -> HttpResponse
|
||||
do_set_muted_topics(user_profile, muted_topics)
|
||||
return json_success()
|
||||
|
||||
|
|
Loading…
Reference in New Issue