summaryrefslogtreecommitdiffstats
path: root/bin
diff options
context:
space:
mode:
authorMattia Rizzolo <mattia@mapreri.org>2015-02-11 00:11:29 +0100
committerMattia Rizzolo <mattia@mapreri.org>2015-02-11 00:11:29 +0100
commit610098b260ea448af23f9a5fd8b31ae422a6c7d8 (patch)
tree24a7eab3bdec2112418980d759cdd868190f50dc /bin
parente2ffeb5b3ef0809382e83feae70329f2976ea995 (diff)
downloadjenkins.debian.net-610098b260ea448af23f9a5fd8b31ae422a6c7d8.tar.xz
reproducible: check notes for validity. Check whether the package actually exists and was tested
Diffstat (limited to 'bin')
-rwxr-xr-xbin/reproducible_html_notes.py11
1 files changed, 11 insertions, 0 deletions
diff --git a/bin/reproducible_html_notes.py b/bin/reproducible_html_notes.py
index dbde9474..4d593a83 100755
--- a/bin/reproducible_html_notes.py
+++ b/bin/reproducible_html_notes.py
@@ -148,6 +148,17 @@ def load_notes():
notes = yaml.load(fd)
log.debug("notes loaded. There are " + str(len(notes)) +
" package listed")
+ for package in notes: # check if every pacakge listed on the notes
+ try: # actually have been tested
+ query = 'SELECT name ' + \
+ 'FROM source_packages ' + \
+ 'WHERE name="%s"' % package
+ result = query_db(query)[0]
+ except IndexError:
+ print_critical_message('This query produces no results: ' + query +
+ '\nThis means there is no tested package with the name ' +
+ package + '.')
+ raise
return notes