From 744b1c083ebe412e92daa1de459d807db226f6fc Mon Sep 17 00:00:00 2001 From: "Kali Kaneko (leap communications)" Date: Fri, 7 Oct 2016 10:21:50 -0400 Subject: [style] pep8 --- src/leap/bitmask/core/dispatcher.py | 2 +- src/leap/bitmask/core/mail_services.py | 17 ++++++++++++----- 2 files changed, 13 insertions(+), 6 deletions(-) (limited to 'src/leap/bitmask/core') diff --git a/src/leap/bitmask/core/dispatcher.py b/src/leap/bitmask/core/dispatcher.py index 783094a..2d22b57 100644 --- a/src/leap/bitmask/core/dispatcher.py +++ b/src/leap/bitmask/core/dispatcher.py @@ -472,7 +472,7 @@ def _format_error(failure): # If a exception declares the 'expected' attribute as True, # we will not print a full traceback - expected = getattr(failure.value, 'expected', False) + expected = getattr(failure.value, 'expected', False) if not expected: logger.failure('[DISPATCHER] Unexpected error:') diff --git a/src/leap/bitmask/core/mail_services.py b/src/leap/bitmask/core/mail_services.py index 564f432..a82659a 100644 --- a/src/leap/bitmask/core/mail_services.py +++ b/src/leap/bitmask/core/mail_services.py @@ -184,7 +184,8 @@ class SoledadService(HookableService): password = kw.get('password') uuid = kw.get('uuid') container = self._container - logger.debug("on_passphrase_entry: New Soledad Instance: %s" % userid) + logger.debug("on_passphrase_entry: " + "New Soledad Instance: %s" % userid) if not container.get_instance(userid): container.add_instance(userid, password, uuid=uuid, token=None) else: @@ -271,7 +272,9 @@ class KeymanagerContainer(Container): logger.info("key generated for %s" % userid) if not keymanager.token: - logger.debug("token not available, scheduling new send attempt...") + logger.debug( + "token not available, scheduling " + "a new key sending attempt...") return task.deferLater(reactor, 5, _send_key, None) logger.info("sending public key to server") @@ -384,7 +387,9 @@ class KeymanagerService(HookableService): container = self._container if container.get_instance(userid): - logger.debug('Passing a new SRP Token to Keymanager: %s' % userid) + logger.debug( + 'passing a new SRP Token ' + 'to Keymanager: %s' % userid) container.set_remote_auth_token(userid, token) else: logger.debug('storing the keymanager token... %s ' % token) @@ -533,7 +538,9 @@ class StandardMailService(service.MultiService, HookableService): username = kw['username'] multiservice = self.getServiceNamed('incoming_mail') incoming = multiservice.getServiceNamed(username) - logger.debug('looking for incoming mail service for logout: %s' % username) + logger.debug( + 'looking for incoming mail service ' + 'for logout: %s' % username) if incoming: incoming.stopService() @@ -565,7 +572,7 @@ class StandardMailService(service.MultiService, HookableService): shutil.rmtree(tokens_folder) except OSError as e: logger.warning("Can't remove tokens folder %s: %s" - % (tokens_folder, e)) + % (tokens_folder, e)) return os.mkdir(tokens_folder, 0700) -- cgit v1.2.3