X-Git-Url: https://git.decadent.org.uk/gitweb/?a=blobdiff_plain;ds=sidebyside;f=dak%2Fqueue_report.py;h=a7086d897a68c54ffc4232bc429c616eb72465e6;hb=2b27c94e1c4d59f54fbec176a91631c09cea4988;hp=1bef3e55915bd9de7b1b43e04120a69ffe377190;hpb=07f1aa392e54c3d7a0747720c32db2b8aa202a42;p=dak.git diff --git a/dak/queue_report.py b/dak/queue_report.py index 1bef3e55..a7086d89 100755 --- a/dak/queue_report.py +++ b/dak/queue_report.py @@ -117,7 +117,15 @@ def time_pp(x): def sg_compare (a, b): a = a[1] b = b[1] - """Sort by have note, time of oldest upload.""" + """Sort by have pending action, have note, time of oldest upload.""" + # Sort by have pending action + a_note_state = a["processed"] + b_note_state = b["processed"] + if a_note_state < b_note_state: + return -1 + elif a_note_state > b_note_state: + return 1 + # Sort by have note a_note_state = a["note_state"] b_note_state = b["note_state"] @@ -175,7 +183,7 @@ def header():
- +