Some vendors (e.g. HP/Aruba ProCurve) advertise a per-port Management
Address TLV that reflects whatever VLAN is routable out that link,
not the switch's real management IP. A neighbor's LLDP report could
therefore overwrite a switch's correct mgmt_ip with a wrong one.
upsert_switch() now takes a trusted flag: a direct scan's mgmt_ip
always wins, while a neighbor-reported one only fills in a blank
value.
Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
Also fixes several LLDP parsing edge cases (blank-field regex bleed,
endpoint-device filtering, HP ProCurve chassis ID format, Aruba port
naming), corrects link dedup to prefer self-reported port names over
neighbor guesses, and repoints NetBox sync at the new instance where
devices are hand-curated rather than auto-created.
Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01Bp1HutYUh9fmTFgwB4qBLz
upsert_link now does a secondary fuzzy dedup by trailing port number
so 'Gi1/9' and '9' are treated as the same port on the same chassis
pair. Prevents duplicate edges when an Aruba and FS switch each report
the same cable using different port name formats.
Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>