From 5e72a8b3c0fa3ecabd3af3792db9078345e3a211 Mon Sep 17 00:00:00 2001 From: Jarrod Johnson Date: Wed, 9 Apr 2025 16:29:57 -0400 Subject: [PATCH] Handle reseat with '1a/1b' type bay description This fixes ability to reseat newer chassis when using the coordinate specification for bay location. --- confluent_server/confluent/messages.py | 2 +- .../confluent/plugins/hardwaremanagement/enclosure.py | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/confluent_server/confluent/messages.py b/confluent_server/confluent/messages.py index e8ea972f..f74f027a 100644 --- a/confluent_server/confluent/messages.py +++ b/confluent_server/confluent/messages.py @@ -1060,7 +1060,7 @@ class InputReseatMessage(ConfluentInputMessage): keyname = 'reseat' def is_valid_key(self, key): - return key in self.valid_values or isinstance(key, int) + return key in self.valid_values or isinstance(key, int) or len(key) < 4 class InputBMCReset(ConfluentInputMessage): diff --git a/confluent_server/confluent/plugins/hardwaremanagement/enclosure.py b/confluent_server/confluent/plugins/hardwaremanagement/enclosure.py index 08aa6052..8665386a 100644 --- a/confluent_server/confluent/plugins/hardwaremanagement/enclosure.py +++ b/confluent_server/confluent/plugins/hardwaremanagement/enclosure.py @@ -27,7 +27,7 @@ def reseat_bays(encmgr, bays, configmanager, rspq): for rsp in core.handle_path( '/nodes/{0}/_enclosure/reseat_bay'.format(encmgr), 'update', configmanager, - inputdata={'reseat': int(encbay)}): + inputdata={'reseat': encbay}): rspq.put(rsp) except pygexc.UnsupportedFunctionality as uf: rspq.put(msg.ConfluentNodeError(node, str(uf)))