summaryrefslogtreecommitdiffstats
path: root/bin
diff options
context:
space:
mode:
authorMattia Rizzolo <mattia@mapreri.org>2015-02-27 02:43:48 +0100
committerMattia Rizzolo <mattia@mapreri.org>2015-02-27 02:46:07 +0100
commit77877a39ef752adb77790b4c777c73bc6496601d (patch)
tree488684c8f0faae475b9f6ec7eb4eedd7eb019e7b /bin
parentb6167e82b446986055dd1889fd2c33e2c1db6368 (diff)
downloadjenkins.debian.net-77877a39ef752adb77790b4c777c73bc6496601d.tar.xz
reproducible: notes: format the query before calling it in load_notes(). this is to have a useful error message, in case of errors
Diffstat (limited to 'bin')
-rwxr-xr-xbin/reproducible_html_notes.py5
1 files changed, 3 insertions, 2 deletions
diff --git a/bin/reproducible_html_notes.py b/bin/reproducible_html_notes.py
index 313846f4..1f047130 100755
--- a/bin/reproducible_html_notes.py
+++ b/bin/reproducible_html_notes.py
@@ -152,8 +152,9 @@ def load_notes():
try: # actually have been tested
query = 'SELECT s.name ' + \
'FROM results AS r JOIN sources AS s ON r.package_id=s.id ' + \
- 'WHERE s.name="{pkg}" AND r.status != ""'
- result = query_db(query.format(pkg=package))[0]
+ 'WHERE s.name="{pkg}" AND r.status != "" AND s.suite="sid"'
+ query = query.format(pkg=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 ' +