From 934ce86d35fe1881276512735dd86607fde2d05a Mon Sep 17 00:00:00 2001 From: Scott Cunningham Date: Tue, 4 Aug 2015 18:29:37 -0700 Subject: [PATCH] update credstash lookup plugin to use Python 2.4-compatible exception catching --- lib/ansible/plugins/lookup/credstash.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/lib/ansible/plugins/lookup/credstash.py b/lib/ansible/plugins/lookup/credstash.py index 5ff585f0e3..febccfa5c6 100644 --- a/lib/ansible/plugins/lookup/credstash.py +++ b/lib/ansible/plugins/lookup/credstash.py @@ -45,7 +45,7 @@ class LookupModule(LookupBase): val = credstash.getSecret(term, **kwargs) except credstash.ItemNotFound: raise AnsibleError('Key {} not found'.format(term)) - except Exception as e: + except Exception, e: raise AnsibleError('Encountered exception while fetching {}: {}'.format(term, e.message)) ret.append(val)