1
0
Fork 0
mirror of https://github.com/ansible-collections/community.general.git synced 2024-09-14 20:13:21 +02:00

better error catching for doc build

This commit is contained in:
Brian Coca 2015-10-12 10:19:48 -04:00
parent 76c8318351
commit 3a0bf55ae3

View file

@ -308,7 +308,11 @@ def process_module(module, options, env, template, outputname, module_map, alias
doc['ansible_version'] = options.ansible_version
doc['plainexamples'] = examples #plain text
if returndocs:
doc['returndocs'] = yaml.safe_load(returndocs)
try:
doc['returndocs'] = yaml.safe_load(returndocs)
except:
print("could not load yaml: %s" % returndocs)
raise
else:
doc['returndocs'] = None