Code Review
/
releng
/
lftools.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
review
|
tree
raw
|
patch
| inline |
side by side
(parent:
e4cf18f
)
Correct script exit condition.
94/15094/3
author
Aric Gardner
<agardner@linuxfoundation.org>
Wed, 27 Mar 2019 20:30:28 +0000
(16:30 -0400)
committer
Aric Gardner
<agardner@linuxfoundation.org>
Thu, 28 Mar 2019 19:15:32 +0000
(15:15 -0400)
Logic error.
When no votes where registered script would exit 0
Change-Id: Ie7dad776c737dcf5e5ed7a0c39b53f362eff980d
Signed-off-by: Aric Gardner <agardner@linuxfoundation.org>
lftools/cli/infofile.py
patch
|
blob
|
history
diff --git
a/lftools/cli/infofile.py
b/lftools/cli/infofile.py
index
c12c25b
..
31fcf54
100644
(file)
--- a/
lftools/cli/infofile.py
+++ b/
lftools/cli/infofile.py
@@
-183,6
+183,10
@@
def check_votes(ctx, info_file, gerrit_url, change_number, tsc):
log.info(have_not_voted)
log.info(have_not_voted_length)
+ if (have_voted_length == 0):
+ log.info("No one has voted:")
+ sys.exit(1)
+
if (have_voted_length != 0):
majority = (committer_lenght / have_voted_length)