Remove pylint
This commit is contained in:
@ -396,9 +396,6 @@ class Application:
|
||||
|
||||
return response(status, headers, answer)
|
||||
|
||||
# All these functions must have the same parameters, some are useless
|
||||
# pylint: disable=W0612,W0613,R0201
|
||||
|
||||
def do_DELETE(self, environ, read_collections, write_collections, content,
|
||||
user):
|
||||
"""Manage DELETE request."""
|
||||
@ -635,5 +632,3 @@ class Application:
|
||||
|
||||
answer = xmlutils.report(environ["PATH_INFO"], content, collection)
|
||||
return client.MULTI_STATUS, headers, answer
|
||||
|
||||
# pylint: enable=W0612,W0613,R0201
|
||||
|
@ -37,9 +37,6 @@ from . import (
|
||||
ThreadedHTTPSServer, config, log)
|
||||
|
||||
|
||||
# This is a script, many branches and variables
|
||||
# pylint: disable=R0912,R0914
|
||||
|
||||
def run():
|
||||
"""Run Radicale as a standalone server."""
|
||||
# Get command-line options
|
||||
@ -242,8 +239,6 @@ def serve(configuration, logger):
|
||||
if server:
|
||||
server.handle_request()
|
||||
|
||||
# pylint: enable=R0912,R0914
|
||||
|
||||
|
||||
if __name__ == "__main__":
|
||||
run()
|
||||
|
@ -147,7 +147,7 @@ class Auth(BaseAuth):
|
||||
"""Check if ``hash_value`` and ``password`` match, sha1 method."""
|
||||
hash_value = hash_value.replace("{SHA}", "").encode("ascii")
|
||||
password = password.encode(self.configuration.get("encoding", "stock"))
|
||||
sha1 = hashlib.sha1() # pylint: disable=E1101
|
||||
sha1 = hashlib.sha1()
|
||||
sha1.update(password)
|
||||
return sha1.digest() == base64.b64decode(hash_value)
|
||||
|
||||
@ -163,7 +163,7 @@ class Auth(BaseAuth):
|
||||
password = password.encode(self.configuration.get("encoding", "stock"))
|
||||
hash_value = hash_value[:20]
|
||||
salt_value = hash_value[20:]
|
||||
sha1 = hashlib.sha1() # pylint: disable=E1101
|
||||
sha1 = hashlib.sha1()
|
||||
sha1.update(password)
|
||||
sha1.update(salt_value)
|
||||
return sha1.digest() == hash_value
|
||||
|
@ -71,11 +71,8 @@ def _pretty_xml(element, level=0):
|
||||
element.tail = i
|
||||
for sub_element in element:
|
||||
_pretty_xml(sub_element, level + 1)
|
||||
# ``sub_element`` is always defined as len(element) > 0
|
||||
# pylint: disable=W0631
|
||||
if not sub_element.tail or not sub_element.tail.strip():
|
||||
sub_element.tail = i
|
||||
# pylint: enable=W0631
|
||||
else:
|
||||
if level and (not element.tail or not element.tail.strip()):
|
||||
element.tail = i
|
||||
@ -604,8 +601,6 @@ def _propfind_response(path, item, props, user, write=False):
|
||||
tag.text = _href(collection, path)
|
||||
element.append(tag)
|
||||
elif tag == _tag("C", "supported-calendar-component-set"):
|
||||
# This is not a Todo
|
||||
# pylint: disable=W0511
|
||||
human_tag = _tag_from_clark(tag)
|
||||
if is_collection and is_leaf:
|
||||
meta = item.get_meta(human_tag)
|
||||
@ -619,7 +614,6 @@ def _propfind_response(path, item, props, user, write=False):
|
||||
element.append(comp)
|
||||
else:
|
||||
is404 = True
|
||||
# pylint: enable=W0511
|
||||
elif tag == _tag("D", "current-user-principal") and user:
|
||||
tag = ET.Element(_tag("D", "href"))
|
||||
tag.text = _href(collection, "/%s/" % user)
|
||||
|
Reference in New Issue
Block a user