From 1f1564dcf0b2ea54b61120a8f10d712dab62597f Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Marek=20Marczykowski-G=C3=B3recki?= Date: Sat, 21 Sep 2019 03:20:43 +0200 Subject: [PATCH] backup/restore: make pylint happy --- qubesadmin/backup/restore.py | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/qubesadmin/backup/restore.py b/qubesadmin/backup/restore.py index 0a33c31..49d6eb0 100644 --- a/qubesadmin/backup/restore.py +++ b/qubesadmin/backup/restore.py @@ -86,6 +86,10 @@ class BackupCanceledError(QubesException): self.tmpdir = tmpdir def init_supported_hmac_and_crypto(): + """Collect supported hmac and crypto algorithms. + + This calls openssl to list actual supported algos. + """ if not KNOWN_HMAC_ALGORITHMS: KNOWN_HMAC_ALGORITHMS.extend(get_supported_hmac_algo()) @@ -101,7 +105,7 @@ class BackupHeader(object): known_headers = { 'version': Header(field='version', t=int, - validator=lambda x: x >= 1 and x <= 4), + validator=lambda x: 1 <= x <= 4), 'encrypted': Header(field='encrypted', t=bool, validator=lambda x: True), 'compressed': Header(field='compressed', t=bool,