Ejemplo n.º 1
0
def do_all_comparisons(cids=settings.DEFAULT.campaigns,
                       pids=settings.DEFAULT.publishers, jobname=None):
    cids = placelocal.get_cids(cids=cids, pids=pids)

    total_compares = 0
    total_errors = 0
    total_skipped = 0

    # Always compare against default job path
    pathbuilder = output.PathBuilder(build=output.DEFAULT_BUILD_NAME)
    if not jobname:
        jobname = output.generate_build_string()

    for cid in cids:
        pathbuilder.cid = cid
        comparisons = settings.DEFAULT.comparisons
        for name in comparisons:
            LOGGER.debug("*** Comparing set: %s...", name)
            configs_to_compare = comparisons[name]
            errors, count, skipped = compare_configs(pathbuilder=pathbuilder,
                                                     configs=configs_to_compare,
                                                     jobname=jobname)
            total_errors += errors
            total_compares += count
            total_skipped += skipped

    LOGGER.info("*** RESULTS ***\nCompared %s images: %s errors, %s skipped",
                total_compares, total_errors,
                total_skipped)
    LOGGER.info("See additional logs at: %s", output.OUTPUT_DIR)
Ejemplo n.º 2
0
def main(build=None):
    LOGGER.info("Starting compare for cid=%s, pids=%s...",
                settings.DEFAULT.campaigns, settings.DEFAULT.publishers)
    output.aggregate()

    if not build:
        build = output.generate_build_string()
    jobname = "compare_" + build
    pb = output.create(build=jobname)

    cids = placelocal.get_cids_from_settings()
    compare(pb, cids=cids)
    return pb
Ejemplo n.º 3
0
def main(cids=settings.DEFAULT.campaigns, pids=settings.DEFAULT.publishers):
    """
    Runs capture, returns the job name for the capture job
    :param cids:
    :param pids:
    :return:
    """
    build = output.generate_build_string()
    pathbuilder = output.PathBuilder(build=build)
    cids = placelocal.get_cids(cids=cids, pids=pids)
    output.aggregate()
    capture_tags_for_all_configs(cids=cids, pathbuilder=pathbuilder)
    return pathbuilder.build
Ejemplo n.º 4
0
def main(build=None):
    LOGGER.info("Starting compare for cid=%s, pids=%s...",
                settings.DEFAULT.campaigns, settings.DEFAULT.publishers)
    output.aggregate()

    if not build:
        build = output.generate_build_string()
    jobname = "compare_" + build
    pb = output.create(build=jobname)

    cids = placelocal.get_cids_from_settings()
    compare(pb, cids=cids)
    return pb
Ejemplo n.º 5
0
def main():
    """
    Runs capture, returns the job name for the capture job
    :param cids:
    :param pids:
    :return:
    """

    original_build = output.generate_build_string()
    build = "capture_" + original_build
    pathbuilder = output.create(build=build)
    cids = placelocal.get_cids_from_settings()
    LOGGER.info("Starting capture against %s for %s campaigns: %s...",
                settings.DEFAULT.domain,
                len(cids), cids)
    output.aggregate()

    configs = settings.DEFAULT.configs_in_comparisons()
    __capture_tags_for_configs(cids=cids, pathbuilder=pathbuilder, configs=configs)
    return original_build
Ejemplo n.º 6
0
def main():
    """
    Runs capture, returns the job name for the capture job
    :param cids:
    :param pids:
    :return:
    """

    original_build = output.generate_build_string()
    build = "capture_" + original_build
    pathbuilder = output.create(build=build)
    cids = placelocal.get_cids_from_settings()
    LOGGER.info("Starting capture against %s for %s campaigns: %s...",
                settings.DEFAULT.domain, len(cids), cids)
    output.aggregate()

    configs = settings.DEFAULT.configs_in_comparisons()
    __capture_tags_for_configs(cids=cids,
                               pathbuilder=pathbuilder,
                               configs=configs)
    return original_build