Skip to content

Commit 005ec30

Browse files
authored
[ycabled] remove some redundant logging for active-active cable type (#274)
This change is required for stop posting MUX_CABLE_INFO entries into state DB for active-active cable_type since for these cables there is no i2c/eeprom or muxcable. This loop is independent of main loop, hence it needs to be changed separately Description Motivation and Context How Has This Been Tested? Unit-tests Signed-off-by: vaibhav-dahiya <[email protected]>
1 parent e889625 commit 005ec30

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

sonic-ycabled/ycable/ycable_utilities/y_cable_helper.py

+2-1
Original file line numberDiff line numberDiff line change
@@ -1424,12 +1424,13 @@ def check_identifier_presence_and_update_mux_info_entry(state_db, mux_tbl, asic_
14241424
port_tbl[asic_id] = swsscommon.Table(config_db[asic_id], "MUX_CABLE")
14251425

14261426
(status, fvs) = port_tbl[asic_index].get(logical_port_name)
1427+
(cable_status, cable_type) = check_mux_cable_port_type(logical_port_name, port_tbl, asic_index)
14271428

14281429
if status is False:
14291430
helper_logger.log_warning("Could not retreive fieldvalue pairs for {}, inside config_db table {}".format(logical_port_name, port_tbl[asic_index].getTableName()))
14301431
return
14311432

1432-
else:
1433+
elif cable_status and cable_type == "active-standby":
14331434
# Convert list of tuples to a dictionary
14341435
mux_table_dict = dict(fvs)
14351436
if "state" in mux_table_dict:

0 commit comments

Comments
 (0)