Skip to content

Conversation

@madhumuraliomm
Copy link

Description

Added new parser for IOSXE command: show wireless iot-coexistence summary

Motivation and Context

Enables automation of wireless IoT coexistence monitoring by extracting:

  • AP names and radio MAC addresses
  • Admin/Operational coexistence states (Enabled/Disabled/Not supported)
  • IoT counters: Tx/Rx packets, CRC errors, priority requests/denials/aborts

Impact (If any)

  • New Parser added.
  • Returns {} for empty output (valid empty state).

Screenshots:

image

Checklist:

  • I have updated the changelog.
  • I have updated the documentation (If applicable).
  • I have added tests to cover my changes (If applicable).
  • All new and existing tests passed.
  • All new code passed compilation.

Copy link
Collaborator

@ThomasJRyan ThomasJRyan left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Overall looks good, just needs a bit of maintenance

Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

You no longer need to include changes to github_parser.json (and honestly I thought we had added this file to the .gitignore)

Comment on lines +4 to +6

from .show_wireless import ShowWirelessIotCoexistenceSummary

Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This is unnecessary. Our library abstraction mechanism handles importing parsers. Please remove this

"""Schema for show wireless iot-coexistence summary"""

schema = {
Optional('ap_list'): {
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The top-level key in a schema shouldn't be Optional. You need at least one static key that will always be there if a match has been made

if not line:
continue

# Detect separator line
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

These comments should be examples of what's being matched. It's a lot easier to debug a parser when you can quickly reference the line it's matching

Comment on lines +5789 to +5790
if 'ap_list' not in show_wireless_iot_coexistence_summary_dict:
show_wireless_iot_coexistence_summary_dict['ap_list'] = {}
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Could just use setdefault here

}
continue

# Try matching AP without counters
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Same

Comment on lines +5816 to +5817
if 'ap_list' not in show_wireless_iot_coexistence_summary_dict:
show_wireless_iot_coexistence_summary_dict['ap_list'] = {}
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Same

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants