Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[show][muxcable] fix show mux hwmode muxdirection RC #2812

Merged
merged 1 commit into from
Apr 28, 2023

Conversation

zjswhhh
Copy link
Contributor

@zjswhhh zjswhhh commented Apr 28, 2023

What I did

show mux hwmode muxdirection always has rc==1.

Fixed the issue below:

  • get_grpc_cached_version_mux_direction_per_port has reverted TRUE/FALSE return value compared to get_hwmode_mux_direction_port. The former is used to get results for active-active ports, the latter is used to get results for active-standby ports.
  • Use sys.exit() instead of return rc. CLI rc is different from function return value.
  • Fixed show mux grpc muxdirection as well.

sign-off: Jing Zhang

How I did it

How to verify it

  • Tested on DUTs to verify rc. Run commands for single port and all ports, with and without --json.
  • Passed all UTs.

Previous command output (if the output of a command-line utility has changed)

New command output (if the output of a command-line utility has changed)

@zjswhhh zjswhhh merged commit b38fcfd into sonic-net:master Apr 28, 2023
@zjswhhh zjswhhh deleted the rc_show_mux_hwmode_muxdirection branch April 28, 2023 21:17
dprital added a commit to dprital/sonic-buildimage that referenced this pull request May 1, 2023
Update sonic-utilities submodule pointer to include the following:
* 88ffb167 [config]config reload should generate sysinfo if missing ([sonic-net#2778](sonic-net/sonic-utilities#2778))
* 7443b9e5 [sonic-package-manager] support extension with multiple YANG modules ([sonic-net#2752](sonic-net/sonic-utilities#2752))
* 522c3a9e [sonic-package-manager] add support for multiple CLI plugin files ([sonic-net#2753](sonic-net/sonic-utilities#2753))
* b38fcfd1 [show][muxcable] fix  RC ([sonic-net#2812](sonic-net/sonic-utilities#2812))
* 7e24463f [chassis]: remote cli commands infra for sonic chassis ([sonic-net#2701](sonic-net/sonic-utilities#2701))
* bee593e4 [DPB]Fixing typo in config breakout output ([sonic-net#2802](sonic-net/sonic-utilities#2802))
* ada603c5 [config]Support multi-asic  Golden Config override ([sonic-net#2738](sonic-net/sonic-utilities#2738))
* 88a7daa8 [show][barefoot] replace shell=True ([sonic-net#2699](sonic-net/sonic-utilities#2699))
* 5e99edb5 [sonic_package_manager] replace shell=True ([sonic-net#2726](sonic-net/sonic-utilities#2726))
* b547bb45 [acl-loader] Only add default deny rule when table is L3 or L3V6 ([sonic-net#2796](sonic-net/sonic-utilities#2796))

Signed-off-by: dprital <drorp@nvidia.com>
yxieca pushed a commit that referenced this pull request May 4, 2023
What I did
show mux hwmode muxdirection always has rc==1.

Fixed the issue below:

get_grpc_cached_version_mux_direction_per_port has reverted TRUE/FALSE return value compared to get_hwmode_mux_direction_port. The former is used to get results for active-active ports, the latter is used to get results for active-standby ports.
Use sys.exit() instead of return rc. CLI rc is different from function return value.
Fixed show mux grpc muxdirection as well.
sign-off: Jing Zhang

How to verify it
Tested on DUTs to verify rc. Run commands for single port and all ports, with and without --json.
Passed all UTs.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants