sonic-net / sonic-mgmt

Configuration management examples for SONiC
Other
194 stars 714 forks source link

Fix KVM get device conn graph error #13434

Closed xwjiang-ms closed 3 months ago

xwjiang-ms commented 3 months ago

Description of PR

Summary: Fixes # (issue)

Type of change

Back port request

Approach

What is the motivation for this PR?

When we get conn_graph_facts in fanout_graph_facts function, it would return an empty dict for KVM testbed, and raise key error when we directly get dev_conn[duthost.hostname].items()

How did you do it?

Return fanout conn graph with None when we get an empty device conn graph facts

How did you verify/test it?

Any platform specific information?

Supported testbed topology if it's a new test case?

Documentation