Hi Gomathi. I've finally got back to this! when I run cli_rm_builder against the existing vyos.firewall_rules module (or my modified version), it fails with an error. The problem is when 'convert_doc_to_ansible_module_kwargs' calls 'extract_argspec(doc_obj, argpsec)', 'extract_argspec' tries to access the 'options' key, which doesn't exist. 'doc_obj' contains a dictionary which has the 'DOCUMENTATION' key at its top level. The value of the 'DOCUMENTATION' key is a string containing the doc yaml. If I replace the 'extract_argspec' function with a version starting with the following (ie. decoding the 'DOCUMENTATION' string), and modify 'convert_doc_to_ansible_module_kwargs' to call this version, it seems to work:
def extract_argspecX(doc_obj, argpsec):
d_obj = yaml.load(doc_obj['DOCUMENTATION'], SafeLoader)
options_obj = d_obj.get("options")
...
So my question is, is this a bug in CLI_RM_BUILDER, or could it be something in the way that I'm calling it that is causing it to fail?
Thanks for your time...