修改方法调用的打印日志

This commit is contained in:
wangsong 2021-11-17 14:43:01 +08:00
parent fa9daab59f
commit 1d1d216117
1 changed files with 5 additions and 4 deletions

View File

@ -63,6 +63,7 @@ class UpdateManagerDbusController(dbus.service.Object):
lock = threading.Lock()
bus = dbus.SystemBus()
try:
logging.info("start to update Source Template...")
obj = bus.get_object('com.kylin.software.properties', '/com/kylin/software/properties')
interface = dbus.Interface(obj, dbus_interface='com.kylin.software.properties.interface')
lock.acquire()
@ -133,8 +134,8 @@ class UpdateManagerDbusController(dbus.service.Object):
logging.warning('Clean In the process of updating or Upgrading...')
return False,'In the process of updating or Upgrading...'
else:
self.parent.start_clean()
logging.info(COLORMETHOR_PREFIX+'method'+COLORLOG_SUFFIX+' Clean ...')
self.parent.start_clean()
return True
except Exception:
return False
@ -158,8 +159,8 @@ class UpdateManagerDbusController(dbus.service.Object):
logging.warning('FixBrokenDepends In the process of updating or Upgrading...')
return False,'In the process of updating or Upgrading...'
else:
self.parent.start_fix_broken()
logging.info(COLORMETHOR_PREFIX+'method'+COLORLOG_SUFFIX+' FixBrokenDepends ...')
self.parent.start_fix_broken()
return True
except Exception:
return False
@ -173,8 +174,8 @@ class UpdateManagerDbusController(dbus.service.Object):
logging.warning('FixIncompleteInstall In the process of updating or Upgrading...')
return False,'In the process of updating or Upgrading...'
else:
self.parent.start_fix_incomplete()
logging.info(COLORMETHOR_PREFIX+'method'+COLORLOG_SUFFIX+' FixIncompleteInstall ...')
self.parent.start_fix_incomplete()
return True
except Exception:
return False
@ -188,8 +189,8 @@ class UpdateManagerDbusController(dbus.service.Object):
logging.warning('UpdateDetect In the process of updating or Upgrading...')
return False,'In the process of updating or Upgrading...'
else:
self.parent.start_update()
logging.info(COLORMETHOR_PREFIX+'method'+COLORLOG_SUFFIX+' UpdateDetect ...')
self.parent.start_update()
return True
except Exception:
return False