[Qa-jenkins-scm] [jenkins.debian.net] 01/04: reproducible: common, html_packages: add a --ignore-missing-files, to suppress those warnings and be able to test stuff outside jenkins where i don't have all the log files

Holger Levsen holger at moszumanska.debian.org
Wed Jul 8 11:51:01 UTC 2015


This is an automated email from the git hooks/post-receive script.

holger pushed a commit to branch master
in repository jenkins.debian.net.

commit 9ae92629c769cea075dcdb5be6769bf23470423f
Author: Mattia Rizzolo <mattia at mapreri.org>
Date:   Wed Jul 8 11:13:09 2015 +0000

    reproducible: common,html_packages: add a --ignore-missing-files, to suppress those warnings and be able to test stuff outside jenkins where i don't have all the log files
---
 bin/reproducible_common.py        | 4 ++++
 bin/reproducible_html_packages.py | 9 +++++----
 2 files changed, 9 insertions(+), 4 deletions(-)

diff --git a/bin/reproducible_common.py b/bin/reproducible_common.py
index eca9140..a22e740 100755
--- a/bin/reproducible_common.py
+++ b/bin/reproducible_common.py
@@ -67,6 +67,8 @@ parser = argparse.ArgumentParser()
 group = parser.add_mutually_exclusive_group()
 group.add_argument("-d", "--debug", action="store_true")
 group.add_argument("-q", "--quiet", action="store_true")
+parser.add_argument("--ignore-missing-files", action="store_true",
+                    help="useful for local testing, where you don't have all the build logs, etc..")
 args, unknown_args = parser.parse_known_args()
 log_level = logging.INFO
 if args.debug or DEBUG:
@@ -106,6 +108,8 @@ log.debug("REPRODUCIBLE_JSON:\t" + REPRODUCIBLE_JSON)
 log.debug("JENKINS_URL:\t\t" + JENKINS_URL)
 log.debug("REPRODUCIBLE_URL:\t" + REPRODUCIBLE_URL)
 
+if args.ignore_missing_files:
+    log.warning("Missing files will be ignored!")
 
 tab = '  '
 
diff --git a/bin/reproducible_html_packages.py b/bin/reproducible_html_packages.py
index ac85c76..a8a920a 100755
--- a/bin/reproducible_html_packages.py
+++ b/bin/reproducible_html_packages.py
@@ -149,7 +149,7 @@ def gen_extra_links(package, version, suite, arch, status):
             default_view = url
     else:
         log.debug('debbindiff not detetected at ' + dbd)
-        if status == 'unreproducible':
+        if status == 'unreproducible' and not args.ignore_missing_files:
             log.critical(REPRODUCIBLE_URL + '/' + suite + '/' + arch + '/' + package +
                          ' is unreproducible, but without debbindiff output.')
     if os.access(dbdtxt, os.R_OK):
@@ -164,8 +164,9 @@ def gen_extra_links(package, version, suite, arch, status):
         links += '<a href="' + url + '" target="main">buildinfo</a>\n'
         if not default_view:
             default_view = url
-    elif status not in ('untested', 'blacklisted', 'FTBFS', 'not for us'):
-        log.critical('buildinfo not detected at ' + buildinfo)
+    elif status not in ('untested', 'blacklisted', 'FTBFS', 'not for us') and \
+        not args.ignore_missing_files:
+            log.critical('buildinfo not detected at ' + buildinfo)
     rbuild = pkg_has_rbuild(package, version, suite, arch)
     if rbuild:  # being a tuple (rbuild path, size), empty if non existant
         url = RBUILD_URI + '/' + suite + '/' + arch + '/' + package + '_' + \
@@ -174,7 +175,7 @@ def gen_extra_links(package, version, suite, arch, status):
                 sizeof_fmt(rbuild[1]) + ')</a>\n'
         if not default_view:
             default_view = url
-    elif status not in ('untested', 'blacklisted'):
+    elif status not in ('untested', 'blacklisted') and not args.ignore_missing_files:
         log.critical(REPRODUCIBLE_URL  + '/' + suite + '/' + arch + '/' + package +
                      ' didn\'t produce a buildlog, even though it has been built.')
     links += link_buildlogs(package, eversion, suite, arch)

-- 
Alioth's /usr/local/bin/git-commit-notice on /srv/git.debian.org/git/qa/jenkins.debian.net.git



More information about the Qa-jenkins-scm mailing list