From 97de7c133e5dafcd5e4711cca746c5278f055cfc Mon Sep 17 00:00:00 2001 From: Matt Clay Date: Wed, 19 Dec 2018 00:16:38 -0800 Subject: [PATCH] Fix no metadata traceback in validate-modules. --- test/sanity/validate-modules/main.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/test/sanity/validate-modules/main.py b/test/sanity/validate-modules/main.py index 56d0e827fd3..a0dfab902a7 100755 --- a/test/sanity/validate-modules/main.py +++ b/test/sanity/validate-modules/main.py @@ -1459,7 +1459,7 @@ class ModuleValidator(Validator): doc_info, docs = self._validate_docs() # See if current version => deprecated.removed_in, ie, should be docs only - if 'removed' in ast.literal_eval(doc_info['ANSIBLE_METADATA']['value'])['status']: + if isinstance(doc_info['ANSIBLE_METADATA']['value'], ast.Dict) and 'removed' in ast.literal_eval(doc_info['ANSIBLE_METADATA']['value'])['status']: end_of_deprecation_should_be_removed_only = True elif docs and 'deprecated' in docs and docs['deprecated'] is not None: try: