Need help with ansible error using register and when condition

Ansible playbook with register and when condition getting error

This list is for awx questions; this is really more of an Ansible question and is probably better suited for another list, see: https://www.ansible.com/community.

However, to answer your question, the field sysinfo.stdout_lines is an array of arrays of text, not an object.
You could print out the specific line contains the model number with sysinfo.stdout_lines[0][2] but you can’t print just the model number without some more work.
If you specifically want the model you will need to do something to parse that text to get the data.
There are some parsers for Ansible for Networking but they depend on the being properly coupled with the model of the router, I personally have not used routeros modules so you’d have to do some research there.

On a side note, if you are just after the model number you may be overcomplicating your playbook.
You might be better suited to just run the routeros_facts module: https://docs.ansible.com/ansible/latest/modules/routeros_facts_module.html and let it collect the device information.
After running that module the variable ansible_net_model should contain the model number of the device.

-John

Unfortunately this module getting error as well:

This list is not for Ansible support. It is only for the AWX project.

You need to review the documentation for Ansible and the modules you are trying to use, and then, try reaching out to the Ansible community for help.