Fix maven_artifact md5 checksum check with archiva repository (#43250)

pull/44958/head
bonzi316 6 years ago committed by ansibot
parent 2822fd8d9b
commit eee406dfd2

@ -434,6 +434,14 @@ class MavenDownloader:
return "Cannot retrieve a valid md5 from %s: %s" % (remote_url, to_native(e))
if(not remote_md5):
return "Cannot find md5 from " + remote_url
try:
# Check if remote md5 only contains md5 or md5 + filename
_remote_md5 = remote_md5.split(None)[0]
remote_md5 = _remote_md5
# remote_md5 is empty so we continue and keep original md5 string
# This should not happen since we check for remote_md5 before
except IndexError as e:
pass
if local_md5 == remote_md5:
return None
else:

Loading…
Cancel
Save