def verify_partial(platforms, product, version, build_number, HACK_first_released_versions=None, protocol='http', server='ftp.mozilla.org'): from distutils.version import LooseVersion partial = Partial(product, version, build_number, protocol, server) log.info("Checking for existence of %s complete mar file..." % partial) complete_mar_name = partial.complete_mar_name() for platform in platforms: if HACK_first_released_versions and platform in HACK_first_released_versions: if LooseVersion(version) < LooseVersion(HACK_first_released_versions[platform]): # No partial for this! continue log.info("Platform: %s" % platform) complete_mar_url = partial.complete_mar_url(platform=platform) if partial.exists(platform=platform): log.info("complete mar: %s exists, url: %s" % (complete_mar_name, complete_mar_url)) else: log.error("Requested file, %s, does not exist on %s" " Check again, or use -b to bypass" % (complete_mar_name, complete_mar_url)) error_tally.add('verify_partial') return False return True
def verify_partial(platforms, product, version, build_number, HACK_first_released_versions=None, protocol='http', server='ftp.mozilla.org'): from distutils.version import LooseVersion partial = Partial(product, version, build_number, protocol, server) log.info("Checking for existence of %s complete mar file..." % partial) complete_mar_name = partial.complete_mar_name() for platform in platforms: if HACK_first_released_versions and platform in HACK_first_released_versions: if LooseVersion(version) < LooseVersion( HACK_first_released_versions[platform]): # No partial for this! continue log.info("Platform: %s" % platform) complete_mar_url = partial.complete_mar_url(platform=platform) if partial.exists(platform=platform): log.info("complete mar: %s exists, url: %s" % (complete_mar_name, complete_mar_url)) else: log.error("Requested file, %s, does not exist on %s" " Check again, or use -b to bypass" % (complete_mar_name, complete_mar_url)) error_tally.add('verify_partial') return False return True
def verify_partial(platforms, product, version, build_number, protocol='http', server='archive.mozilla.org'): partial = Partial(product, version, build_number, protocol, server) log.info("Checking for existence of %s complete mar file..." % partial) complete_mar_name = partial.complete_mar_name() for platform in platforms: log.info("Platform: %s" % platform) complete_mar_url = partial.complete_mar_url(platform=platform) if partial.exists(platform=platform): log.info("complete mar: %s exists, url: %s" % (complete_mar_name, complete_mar_url)) else: log.error("Requested file, %s, does not exist on %s" " Check again, or use -b to bypass" % (complete_mar_name, complete_mar_url)) error_tally.add('verify_partial') return False return True