Skip to content

Commit

Permalink
[show][config] cli refactor for muxcable with abstract class implemen…
Browse files Browse the repository at this point in the history
…tation from vendors (sonic-net#1722)

Signed-off-by: vaibhav-dahiya vdahiya@microsoft.com

What I did
this PR adds support for cli refactor which is done for abstract class implementation of muxcable which is provided by vendors.
detailed design doc can be found sonic-net/SONiC#757

How I did it
Added the changes in muxcable.py in show and config .

How to verify it
add unit-tests as well as run on a Arista-7050cx3 switch, run unit tests.

no change in outputs, just the functionality has changed.
Signed-off-by: vaibhav-dahiya <vdahiya@microsoft.com>
  • Loading branch information
vdahiya12 committed Aug 25, 2021
1 parent 93d18ea commit ab79eb9
Show file tree
Hide file tree
Showing 2 changed files with 0 additions and 2 deletions.
1 change: 0 additions & 1 deletion config/muxcable.py
Original file line number Diff line number Diff line change
Expand Up @@ -514,7 +514,6 @@ def setswitchmode(db, state, port):
res_dict [1] = "unknown"
res_dict = update_and_get_response_for_xcvr_cmd("config", "result", "True", "XCVRD_CONFIG_HWMODE_SWMODE_CMD", "XCVRD_CONFIG_HWMODE_SWMODE_RSP", port, 1, state)


rc = res_dict[0]

delete_all_keys_in_db_table("APPL_DB", "XCVRD_CONFIG_HWMODE_SWMODE_CMD")
Expand Down
1 change: 0 additions & 1 deletion show/muxcable.py
Original file line number Diff line number Diff line change
Expand Up @@ -740,7 +740,6 @@ def switchmode(db, port):
"""Shows the current switching mode of the muxcable {auto/manual}"""

port = platform_sfputil_helper.get_interface_alias(port, db)

delete_all_keys_in_db_table("APPL_DB", "XCVRD_SHOW_HWMODE_SWMODE_CMD")
delete_all_keys_in_db_table("STATE_DB", "XCVRD_SHOW_HWMODE_SWMODE_RSP")

Expand Down

0 comments on commit ab79eb9

Please sign in to comment.