Update python2 to python3
[vfc/nfvo/lcm.git] / lcm / ns / biz / ns_manual_scale.py
index 2db5529..f40cb0a 100644 (file)
@@ -45,13 +45,13 @@ class NSManualScaleService(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(e.message)
+            logger.error(e.args[0])
             logger.error(traceback.format_exc())
             JobUtil.add_job_status(self.job_id, JOB_PROGRESS.ERROR, 'ns scale fail')
-            NsLcmOpOcc.update(self.occ_id, operationState="FAILED", error=e.message)
+            NsLcmOpOcc.update(self.occ_id, operationState="FAILED", error=e.args[0])
         finally:
             self.update_ns_status(NS_INST_STATUS.ACTIVE)