From b0ca40337a3478a117920035d2e41a85a7546278 Mon Sep 17 00:00:00 2001 From: Jared Stevenson Date: Thu, 11 Apr 2019 09:52:07 -0400 Subject: [PATCH] Fix ConnectionError, as it does not contain the 'message' attribute --- purestorage/purestorage.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/purestorage/purestorage.py b/purestorage/purestorage.py index 5a06d66..6d3ccad 100644 --- a/purestorage/purestorage.py +++ b/purestorage/purestorage.py @@ -164,7 +164,7 @@ def _request(self, method, path, data=None, reestablish_session=True): except requests.exceptions.RequestException as err: # error outside scope of HTTP status codes # e.g. unable to resolve domain name - raise PureError(err.message) + raise PureError(err.args[0]) if response.status_code == 200: if "application/json" in response.headers.get("Content-Type", ""):