add error
This commit is contained in:
parent
f13d755a7e
commit
2db197e128
|
@ -7,7 +7,7 @@ __all__ = (
|
|||
"ERROR_UPDATE_SOURCE_FAILED","ERROR_NETWORK_FAILED","ERROR_NOT_GROUPS_CONFIG","ERROR_SOFTWARE_INDEX_RROKEN",
|
||||
"ERROR_NOT_INIT_PACKAGESINFIO","ERROR_READ_IMPORTANTLIST_FAILED","ERROR_RESOLVER_FAILED","ERROR_NOT_UPGRADE_PACKAGES",
|
||||
"ERROR_REMOVE_ESSENTIAL_PACKAGES","ERROR_NOT_DISK_SPACE","ERROR_NOT_CONFIGPKG_DEPENDENCIES","ERROR_NOT_SELFPKG_DEPENDENCIES",
|
||||
"ERROR_NOT_FIX_SYSTEM","ERROR_READ_LOCAL_DEB","ERROR_INSTALL_DEB_BASE","ERROR_LOAD_CONFIG_FAILED",
|
||||
"ERROR_NOT_FIX_SYSTEM","ERROR_READ_LOCAL_DEB","ERROR_LOCAL_DEB_FORMAT","ERROR_INSTALL_DEB_BASE","ERROR_LOAD_CONFIG_FAILED",
|
||||
"ERROR_UPDATE_KEY_SIGNATURES","ERROR_UPDATE_NET_AUTHENTICATION","ERROR_UPDATE_NOTREAD_SOURCES","PRIORITY_UPGRADE_SUCCCESSED",
|
||||
|
||||
"get_error_description_from_enum", "get_error_string_from_enum", "get_source_name_from_enum", "get_caller_from_enum")
|
||||
|
@ -44,6 +44,7 @@ ERROR_NOT_UPGRADE_PACKAGES = "error-not-upgrade-packages"
|
|||
ERROR_REMOVE_ESSENTIAL_PACKAGES = "error-remove-essential-packages"
|
||||
ERROR_NOT_DISK_SPACE = "error-not-disk-space"
|
||||
ERROR_READ_LOCAL_DEB = "error-read-local-deb"
|
||||
ERROR_LOCAL_DEB_FORMAT = "error-local-deb-format"
|
||||
ERROR_INSTALL_DEB_BASE = "error-install-deb-base"
|
||||
|
||||
_STRINGS_ERROR = {
|
||||
|
@ -71,6 +72,7 @@ _STRINGS_ERROR = {
|
|||
ERROR_REMOVE_ESSENTIAL_PACKAGES: _("There is an exception in the update package."),
|
||||
ERROR_NOT_DISK_SPACE: _("Disk space is insufficient, please clean the disk and then upgrade"),
|
||||
ERROR_READ_LOCAL_DEB:_(" "),
|
||||
ERROR_LOCAL_DEB_FORMAT:_(" "),
|
||||
ERROR_INSTALL_DEB_BASE:_(" ")}
|
||||
|
||||
_DESCS_ERROR = {
|
||||
|
@ -99,6 +101,7 @@ _DESCS_ERROR = {
|
|||
ERROR_REMOVE_ESSENTIAL_PACKAGES: _("You request the removal of a system-essential package."),
|
||||
ERROR_NOT_DISK_SPACE: _("test"),
|
||||
ERROR_READ_LOCAL_DEB:_("Deb format exception, read local deb file error."),
|
||||
ERROR_LOCAL_DEB_FORMAT:_("Deb format exception, failed to parse package file."),
|
||||
ERROR_INSTALL_DEB_BASE:_("Install deb error.")
|
||||
}
|
||||
|
||||
|
|
|
@ -706,6 +706,8 @@ class UpdateManager():
|
|||
logging.error(str(e))
|
||||
if "E:read" in str(e):
|
||||
raise UpdateBaseError(ERROR_READ_LOCAL_DEB)
|
||||
else:
|
||||
raise UpdateBaseError(ERROR_LOCAL_DEB_FORMAT)
|
||||
except Exception as e:
|
||||
logging.error(str(e))
|
||||
raise UpdateBaseError(ERROR_INSTALL_DEB_BASE)
|
||||
|
|
|
@ -13,7 +13,6 @@ backend/SystemUpdater/*.py /usr/share/kylin-system-updater/SystemUpdater/
|
|||
backend/SystemUpdater/backend/*.py /usr/share/kylin-system-updater/SystemUpdater/backend/
|
||||
backend/SystemUpdater/Core/*.py /usr/share/kylin-system-updater/SystemUpdater/Core/
|
||||
backend/build/mo/* /usr/share/locale/
|
||||
<<<<<<< HEAD
|
||||
backend/data/system-updater-defaults.conf /var/lib/kylin-system-updater/
|
||||
backend/data/system-updater-coverable.conf /var/lib/kylin-system-updater/
|
||||
backend/data/unattended-upgrades-policy.conf /var/lib/unattended-upgrades/
|
||||
|
@ -25,19 +24,7 @@ backend/kylin-upgrade-strategies /usr/share/kylin-system-updater/
|
|||
backend/data/com.kylin.UpgradeStrategies.conf /etc/dbus-1/system.d/
|
||||
backend/data/com.kylin.UpgradeStrategies.service /usr/share/dbus-1/system-services/
|
||||
backend/data/cn.kylinos.UpgradeStrategies.policy /usr/share/polkit-1/actions/
|
||||
=======
|
||||
backend/data/system-updater.conf /var/lib/kylin-system-updater/
|
||||
plugin/config_file/* /usr/share/ukui-control-center/upgrade/
|
||||
plugin/translations/* /usr/share/Upgrade/translations/
|
||||
plugin/libupgrade.so /usr/lib/
|
||||
plugin/src/kylin-system-update.desktop /etc/xdg/autostart
|
||||
plugin_2107/* /tmp
|
||||
#notification
|
||||
notification/kylin-updatefinish-notify.desktop /etc/xdg/autostart
|
||||
notification/kylin-system-updater-notify.mo /usr/share/locale/zh_CN/LC_MESSAGES
|
||||
kylin-updatefinish-notify /usr/bin
|
||||
backend/data/kylin-system-updater /etc/logrotate.d
|
||||
>>>>>>> b16a730... 增加错误消息描述字段,
|
||||
|
||||
#uu
|
||||
unattended-upgrades/*.service /lib/systemd/system/
|
||||
|
|
Loading…
Reference in New Issue