##### COMPONENT NAME
cnos_linkagg

https://docs.ansible.com/ansible/devel/modules/network_maintained.html#network-supported

Specifically:
https://docs.ansible.com/ansible/latest/modules/cnos_linkagg_module.html#cnos-linkagg-module

should be modified to be community supported (not fully supported).

Thanks!
from copy import deepcopy
from ansible.module_utils.basic import AnsibleModule
from ansible.module_utils.network.common.config import CustomNetworkConfig
from ansible.module_utils.network.common.utils import remove_default_spec
from ansible.module_utils.network.cnos.cnos import get_config, load_config
from ansible.module_utils.network.cnos.cnos import cnos_argument_spec
def search_obj_in_list(group, lst):
    for o in lst:
        if o['group'] == group:
            return o
def map_obj_to_commands(updates, module):
    commands = list()
    want, have = updates
    purge = module.params['purge']
    for w in want:
        group = w['group']
        mode = w['mode']
        members = w.get('members') or []
        state = w['state']
        del w['state']
        obj_in_have = search_obj_in_list(group, have)
        if state == 'absent':
            if obj_in_have:
                commands.append('no interface port-channel {0}'.format(group))
        elif state == 'present':
            cmd = ['interface port-channel {0}'.format(group),
                   'exit']
            if not obj_in_have:
                if not group:
                    module.fail_json(msg='group is a required option')