Skip to content

Commit cc1010b

Browse files
authored
Merge pull request xapi-project#3160 from minli1/private/minl1/CA-253959
CA-253959: Modify error message from update precheck script.
2 parents e60d411 + 5dce65b commit cc1010b

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

scripts/extensions/pool_update.precheck

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -38,6 +38,7 @@ ERROR_MESSAGE_PROCESSING_CONFLICT = '--> Processing Conflict:'
3838
ERROR_MESSAGE_PREREQUISITE = 'Requires: '
3939
ERROR_MESSAGE_VERSION_REQUIRED = 'Requires: '
4040
ERROR_MESSAGE_VERSION_INSTALLED = 'Installed: '
41+
ERROR_MESSAGE_VERSION_UPDATED_BY = 'Updated By: '
4142
ERROR_MESSAGE_DOWNLOAD_PACKAGE = 'Error downloading packages:\n'
4243
ERROR_MESSAGE_GPGKEY_NOT_IMPORTED = 'Gpg Keys not imported'
4344
ERROR_XML_START = '<error errorcode='
@@ -149,7 +150,7 @@ def execute_precheck(session, control_package, yum_conf_file, update_precheck_fi
149150
raise ConflictPresent(conflict_updates.rstrip())
150151
else:
151152
raise PrecheckFailure(errmsg)
152-
elif ERROR_MESSAGE_VERSION_REQUIRED in errmsg and ERROR_MESSAGE_VERSION_INSTALLED in errmsg:
153+
elif ERROR_MESSAGE_VERSION_REQUIRED in errmsg and (ERROR_MESSAGE_VERSION_INSTALLED in errmsg or ERROR_MESSAGE_VERSION_UPDATED_BY in errmsg):
153154
regex = ERROR_MESSAGE_VERSION_REQUIRED + '(.+?)\n.+ {2,2}(.+)$'
154155
match = re.search(regex, errmsg, flags=re.DOTALL)
155156
if match:

0 commit comments

Comments
 (0)