Skip to content

Commit

Permalink
Work around unpopulated hwsku in db_migrator.py
Browse files Browse the repository at this point in the history
Handle the case where hwsku is None.
See sonic-net/sonic-buildimage#12083 and sonic-net/sonic-buildimage#11416
  • Loading branch information
rjthomson committed Jan 27, 2023
1 parent 1b21201 commit d420f1f
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion scripts/db_migrator.py
Original file line number Diff line number Diff line change
Expand Up @@ -890,7 +890,7 @@ def common_migration_ops(self):
# removed together with calling to migrate_copp_table function.
if self.asic_type != "mellanox":
self.migrate_copp_table()
if self.asic_type == "broadcom" and 'Force10-S6100' in self.hwsku:
if self.asic_type == "broadcom" and self.hwsku and 'Force10-S6100' in self.hwsku:
self.migrate_mgmt_ports_on_s6100()
else:
log.log_notice("Asic Type: {}, Hwsku: {}".format(self.asic_type, self.hwsku))
Expand Down

0 comments on commit d420f1f

Please sign in to comment.