From cfb9575a5e1bdd072fc318be1c6681023f507a61 Mon Sep 17 00:00:00 2001 From: Jarrod Johnon Date: Mon, 19 Jan 2015 16:32:30 -0500 Subject: [PATCH] Fix configuration auto-fixup in ipmi If a session was attempted but failed before creation, a trace was thrown. Fix this by catching the scenario and passing, since the desired effect is already there. --- .../confluent/plugins/hardwaremanagement/ipmi.py | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/confluent_server/confluent/plugins/hardwaremanagement/ipmi.py b/confluent_server/confluent/plugins/hardwaremanagement/ipmi.py index fb9878cf..795e9aed 100644 --- a/confluent_server/confluent/plugins/hardwaremanagement/ipmi.py +++ b/confluent_server/confluent/plugins/hardwaremanagement/ipmi.py @@ -52,7 +52,12 @@ class IpmiCommandWrapper(ipmicommand.Command): super(self.__class__, self).__init__(**kwargs) def _attribschanged(self, nodeattribs, configmanager, **kwargs): - self.ipmi_session._mark_broken() + try: + self.ipmi_session._mark_broken() + except AttributeError: + # if ipmi_session doesn't already exist, + # then do nothing + pass def _ipmi_evtloop(): while True: