Update python2 to python3
[vfc/nfvo/lcm.git] / lcm / ns / biz / ns_heal.py
index 19994df..8ca033f 100644 (file)
@@ -44,12 +44,12 @@ class NSHealService(threading.Thread):
         try:
             self.do_biz()
         except NSLCMException as e:
-            JobUtil.add_job_status(self.job_id, JOB_PROGRESS.ERROR, e.message)
-            NsLcmOpOcc.update(self.occ_id, operationState="FAILED", error=e.message)
+            JobUtil.add_job_status(self.job_id, JOB_PROGRESS.ERROR, e.args[0])
+            NsLcmOpOcc.update(self.occ_id, operationState="FAILED", error=e.args[0])
         except Exception as e:
             logger.error(traceback.format_exc())
             JobUtil.add_job_status(self.job_id, JOB_PROGRESS.ERROR, 'ns heal fail')
-            NsLcmOpOcc.update(self.occ_id, operationState="FAILED", error=e.message)
+            NsLcmOpOcc.update(self.occ_id, operationState="FAILED", error=e.args[0])
 
     def do_biz(self):
         self.update_job(1, desc='ns heal start')