diff --git a/gluon/contrib/login_methods/saml2_auth.py b/gluon/contrib/login_methods/saml2_auth.py index a791f0d3..0e454992 100644 --- a/gluon/contrib/login_methods/saml2_auth.py +++ b/gluon/contrib/login_methods/saml2_auth.py @@ -150,14 +150,14 @@ class Saml2Auth(object): self.config_file = config_file self.maps = maps - # URL for redirecting users to when they sign out + # URL for redirecting users to when they sign out self.saml_logout_url = logout_url # URL to let users change their password in the IDP system self.saml_change_password_url = change_password_url - # URL to specify an IDP if using federation metadata or an MDQ - self.entityid = entityid + # URL to specify an IDP if using federation metadata or an MDQ + self.entityid = entityid def login_url(self, next="/"): d = saml2_handler(current.session, current.request, entityid=self.entityid) diff --git a/gluon/contrib/redis_cache.py b/gluon/contrib/redis_cache.py index 3b92eef0..87437af7 100644 --- a/gluon/contrib/redis_cache.py +++ b/gluon/contrib/redis_cache.py @@ -208,12 +208,12 @@ class RedisClient(object): def retry_call(self, key, f, time_expire, with_lock): self.RETRIES += 1 - if self.RETRIES <= self.MAX_RETRIES: - logger.error("sleeping %s seconds before reconnecting" % (2 * self.RETRIES)) - time.sleep(2 * self.RETRIES) + if self.RETRIES <= self.MAX_RETRIES: if self.fail_gracefully: self.RETRIES = 0 return f() + logger.error("sleeping %s seconds before reconnecting" % (2 * self.RETRIES)) + time.sleep(2 * self.RETRIES) return self.__call__(key, f, time_expire, with_lock) else: self.RETRIES = 0