[Qa-jenkins-scm] [jenkins.debian.net] 02/05: reproducible: html_packages, breakages: use that pkg_has_rbuild function. Gain support for .gz rbuilds for free
Holger Levsen
holger at moszumanska.debian.org
Mon Jun 1 14:39:22 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 03480336a8402a09d8cafff8ebaa203f91bb6043
Author: Mattia Rizzolo <mattia at mapreri.org>
Date: Sat May 30 02:34:04 2015 +0200
reproducible: html_packages, breakages: use that pkg_has_rbuild function. Gain support for .gz rbuilds for free
---
bin/reproducible_breakages.py | 8 +++-----
bin/reproducible_html_packages.py | 10 ++++------
2 files changed, 7 insertions(+), 11 deletions(-)
diff --git a/bin/reproducible_breakages.py b/bin/reproducible_breakages.py
index 37125ca..2f26eb3 100755
--- a/bin/reproducible_breakages.py
+++ b/bin/reproducible_breakages.py
@@ -75,10 +75,7 @@ def lack_rbuild():
ORDER BY s.name ASC, s.suite DESC'''
results = query_db(query)
for pkg, version, suite, arch in results:
- eversion = strip_epoch(version)
- rbuild = RBUILD_PATH + '/' + suite + '/' + arch + '/' + pkg + '_' + \
- eversion + '.rbuild.log'
- if not os.access(rbuild, os.R_OK):
+ if not pkg_has_rbuild(pkg, version, suite, arch):
bad_pkgs.append((pkg, version, suite, arch))
log.warning(pkg + '/' + suite + ' (' + version + ') has been '
'built, but a buildlog is missing.')
@@ -265,7 +262,8 @@ if __name__ == '__main__':
bugs = get_bugs()
html = '<p>This page lists unexpected things a human should look at and '
html += 'fix, like packages with an incoherent status or files that '
- html += 'should not be there.<em>Please help making this page empty!</em></p>'
+ html += 'should not be there. '
+ html += '<em>Please help making this page empty!</em></p>\n'
breakages = gen_html()
if breakages:
html += breakages
diff --git a/bin/reproducible_html_packages.py b/bin/reproducible_html_packages.py
index 9f34241..10f4797 100755
--- a/bin/reproducible_html_packages.py
+++ b/bin/reproducible_html_packages.py
@@ -112,8 +112,6 @@ def gen_status_link_icon(status, icon, suite, arch):
def gen_extra_links(package, version, suite, arch, status):
eversion = strip_epoch(version)
notes = NOTES_PATH + '/' + package + '_note.html'
- rbuild = RBUILD_PATH + '/' + suite + '/' + arch + '/' + package + '_' + \
- eversion + '.rbuild.log'
buildinfo = BUILDINFO_PATH + '/' + suite + '/' + arch + '/' + package + \
'_' + eversion + '_amd64.buildinfo'
dbd = DBD_PATH + '/' + suite + '/' + arch + '/' + package + '_' + \
@@ -147,12 +145,12 @@ def gen_extra_links(package, version, suite, arch, status):
default_view = url
else:
log.debug('buildinfo not detected at ' + buildinfo)
- if os.access(rbuild, os.R_OK):
+ 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 + '_' + \
- eversion + '.rbuild.log'
- log_size = os.stat(rbuild).st_size
+ eversion + '.rbuild.log' # apache ignores the trailing .gz
links +='<a href="' + url + '" target="main">rbuild (' + \
- sizeof_fmt(log_size) + ')</a>\n'
+ sizeof_fmt(rbuild[1]) + ')</a>\n'
if not default_view:
default_view = url
elif status not in ('untested', 'blacklisted'):
--
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