From 31126034b04327448826affdb8bbe2be8aadd0ae Mon Sep 17 00:00:00 2001 From: Michael Scherer Date: Tue, 17 May 2016 19:17:24 +0200 Subject: [PATCH] Port htpasswd to python3 compatible syntax (#3672) --- lib/ansible/modules/web_infrastructure/htpasswd.py | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/lib/ansible/modules/web_infrastructure/htpasswd.py b/lib/ansible/modules/web_infrastructure/htpasswd.py index 83a6445374..d4d950e924 100644 --- a/lib/ansible/modules/web_infrastructure/htpasswd.py +++ b/lib/ansible/modules/web_infrastructure/htpasswd.py @@ -251,7 +251,8 @@ def main(): check_file_attrs(module, changed, msg) module.exit_json(msg=msg, changed=changed) - except Exception, e: + except Exception: + e = get_exception() module.fail_json(msg=str(e))