Skip to content

Point 'device does not support' errors to platform support tables - #4204

Open
ipspace wants to merge 1 commit into
devfrom
error-doc-url-3
Open

ipspace wants to merge 1 commit into
devfrom
error-doc-url-3

Conversation

@ipspace

@ipspace ipspace commented Nov 26, 2026

Copy link
Copy Markdown
Owner

Add 'doc_url' parameter to log.error/log.warning calls reporting
features not supported by a device. The URLs point to the platform
support tables in platforms.md, module documentation, or plugin
documentation.

  • Route import errors use the '-platform' anchor of the
    routing protocol documentation
  • BGP attribute checks shared by bgp.session and bgp.policy plugins
    use a plugin-to-URL map in utils/routing.py

Add anchors to platform support tables that did not have them (BGP
session types and local AS, EVPN, VLAN, VXLAN, MPLS, RIPv2, EIGRP,
routing policies, BGP community lists, bgp.policy plugin)

Update the expected error test outputs

Co-Authored-By: Claude Opus 5.5 noreply@anthropic.com

Add 'doc_url' parameter to log.error/log.warning calls reporting
features not supported by a device. The URLs point to the platform
support tables in platforms.md, module documentation, or plugin
documentation.

* Route import errors use the '<proto>-platform' anchor of the
  routing protocol documentation
* BGP attribute checks shared by bgp.session and bgp.policy plugins
  use a plugin-to-URL map in utils/routing.py

Add anchors to platform support tables that did not have them (BGP
session types and local AS, EVPN, VLAN, VXLAN, MPLS, RIPv2, EIGRP,
routing policies, BGP community lists, bgp.policy plugin)

Update the expected error test outputs

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

🟡 Changes recommended

Three active nit findings remain because related platform-support error branches still omit the new documentation URL, leaving some unsupported configurations without the promised guidance.

3 open issues
What changed in this PR

This pull request makes unsupported-device diagnostics more actionable by linking them to relevant platform, module, or plugin documentation, adding missing support-table anchors, and updating expected error outputs.

Changes:

  • Added doc_url references across modules, plugins, shared routing helpers, and topology validation.
  • Added documentation anchors for platform-support sections.
  • Updated error and coverage fixtures to include the new documentation links.
File Description
tests/​errors/​unnumbered-capability.log Updates expected unnumbered-interface errors with the platform support link.
tests/​errors/​rt-vlan-native-routed.log Updates expected routed-VLAN errors with the VLAN support link.
tests/​errors/​rp-static-nonsense.log Updates expected static-routing errors with the routing support link.
tests/​errors/​rp-set-unsupported.log Updates expected routing-policy errors with relevant support links.
tests/​errors/​ospf-unnumbered.log Updates expected OSPF unnumbered-interface errors with the OSPF support link.
tests/​errors/​mtu.log Updates expected MTU errors with the initial-interface support link.
tests/​errors/​module-device-provider.log Updates expected module and provider errors with the platform support link.
tests/​errors/​lag-no-mside.log Updates expected MLAG errors with the LAG support link.
tests/​errors/​lag-esi-only-peerlink.log Updates expected ESI peerlink errors with the LAG support link.
tests/​errors/​isis-capability.log Updates expected IS-IS capability errors with the IS-IS support link.
tests/​errors/​bgp-remove-private-as.log Updates expected BGP session errors with the BGP support link.
tests/​errors/​bgp-policy-autobw.log Updates expected BGP policy errors with the plugin support link.
tests/​errors/​bgp-confed.log Updates expected BGP confederation errors with the BGP support link.
tests/​coverage/​errors/​vrf-leaking.log Updates expected VRF leaking errors with the VRF support link.
tests/​coverage/​errors/​vrf-bgp-unsupported.log Updates expected VRF BGP errors with the routing support link.
tests/​coverage/​errors/​sr-af.log Updates expected SR-MPLS errors with the SR-MPLS support link.
tests/​coverage/​errors/​ripv2-unnumbered.log Updates expected RIPv2 errors with the RIPv2 support link.
tests/​coverage/​errors/​provider-module-false.log Updates expected provider and module errors with the platform support link.
tests/​coverage/​errors/​node-no-ipv6.log Updates expected IPv6 capability errors with the initial-address support link.
tests/​coverage/​errors/​mpls-optional-attr.log Updates expected MPLS attribute errors with the MPLS support link.
tests/​coverage/​errors/​lag-no-static.log Updates expected static-LAG errors with the LAG support link.
tests/​coverage/​errors/​isis-no-mt.log Updates expected IS-IS multi-topology errors with the IS-IS support link.
tests/​coverage/​errors/​clist-type-unsupported.log Updates expected community-list errors with the community-list support link.
tests/​coverage/​errors/​clist-match-type-mismatch.log Updates expected community-list validation errors with the community-list support link.
netsim/​utils/​routing.py Maps BGP plugins to support documentation for shared attribute checks.
netsim/​modules/​vxlan.py Links unsupported IPv6 VXLAN errors to VXLAN support documentation.
netsim/​modules/​vrf.py Links VRF capability errors to VRF support tables.
netsim/​modules/​vlan.py Links VLAN capability errors to the VLAN support table.
netsim/​modules/​stp.py Links unsupported STP capability errors to the STP support table.
netsim/​modules/​srv6.py Links SRv6 capability errors to SRv6 support documentation.
netsim/​modules/​sr.py Links SR-MPLS capability errors to SR-MPLS support documentation.
netsim/​modules/​routing/​policy.py Links routing-policy capability errors to relevant support tables.
netsim/​modules/​routing/​normalize.py Links unsupported routing-object errors to generic routing support.
netsim/​modules/​routing/​clist.py Links BGP community-list errors to the community-list support table.
netsim/​modules/​ripv2.py Links RIPv2 capability errors to the RIPv2 support table.
netsim/​modules/​ospf.py Links OSPF capability errors to the OSPF support table.
netsim/​modules/​mpls.py Links MPLS capability errors to the MPLS support table.
netsim/​modules/​lag.py Links LAG capability errors to the LAG support table.
netsim/​modules/​isis.py Links IS-IS capability errors to the IS-IS support table.
netsim/​modules/​evpn.py Links EVPN capability errors to EVPN support documentation.
netsim/​modules/​dhcp.py Links DHCP capability errors to the DHCP support table.
netsim/​modules/​bgp.py Links BGP session, local-AS, and confederation errors to BGP support tables.
netsim/​modules/​_routing.py Links VRF routing and route-import capability errors to support documentation.
netsim/​modules/​__init__.py Links unsupported module and provider combinations to platform support.
netsim/​extra/​ospf/​areas/​__init__.py Links unsupported OSPF area parameters to plugin documentation.
netsim/​extra/​firewall/​zonebased/​__init__.py Links unsupported zone-based firewall configuration to plugin documentation.
netsim/​extra/​evpn/​multihoming/​__init__.py Links EVPN multihoming capability errors to plugin documentation.
netsim/​extra/​ebgp/​multihop/​__init__.py Links EBGP multihop capability errors to plugin documentation.
netsim/​extra/​bgp/​policy/​__init__.py Links unsupported BGP policy attributes to plugin documentation.
netsim/​augment/​nodes.py Links initial node and interface capability errors to platform support tables.
netsim/​augment/​links.py Links interface addressing and router-advertisement capability errors to platform support.
docs/​plugins/​bgp.policy.md Adds the BGP policy platform-support anchor.
docs/​module/​vxlan.md Adds the VXLAN platform-support anchor.
docs/​module/​vlan.md Adds the VLAN platform-support anchor.
docs/​module/​routing-policy.txt Adds the routing-policy platform-support anchor.
docs/​module/​routing-clist.txt Adds the BGP community-list platform-support anchor.
docs/​module/​ripv2.md Adds the RIPv2 platform-support anchor.
docs/​module/​mpls.md Adds the MPLS platform-support anchor.
docs/​module/​evpn.md Adds the EVPN platform-support anchor.
docs/​module/​eigrp.md Adds the EIGRP platform-support anchor.
docs/​module/​bgp.md Adds BGP session and local-AS support anchors.

Review effort: Lite

category=log.IncorrectType,
module=_config_name)
module=_config_name,
doc_url='plugins/bgp.policy/#plugin-bgp-policy-platform')
Comment on lines +653 to +654
module=proto,
doc_url=f'module/{proto}/#{proto}-platform')
Comment thread netsim/modules/stp.py
Comment on lines +71 to +72
'stp',
doc_url='module/stp/#stp-platform')

This branch has not been deployed

No deployments
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