Skip to content

Instantly share code, notes, and snippets.

@ants
Created September 26, 2018 11:09
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save ants/3518bb67e2cf2e83a9a7fe5dd59e0df3 to your computer and use it in GitHub Desktop.
Save ants/3518bb67e2cf2e83a9a7fe5dd59e0df3 to your computer and use it in GitHub Desktop.
diff --git a/patroni/dcs/kubernetes.py b/patroni/dcs/kubernetes.py
index ade15ff..9fbd9e7 100644
--- a/patroni/dcs/kubernetes.py
+++ b/patroni/dcs/kubernetes.py
@@ -107,7 +107,8 @@ class Kubernetes(AbstractDCS):
try:
return func(*args, **kwargs)
except (RetryFailedError, k8s_client.rest.ApiException,
- HTTPException, HTTPError, socket.error, socket.timeout):
+ HTTPException, HTTPError, socket.error, socket.timeout) as e:
+ logger.error(e)
return False
return wrapper
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment