[tor-commits] [doctor/master] Stacktrace if there aren't any bad relays
atagar at torproject.org
atagar at torproject.org
Sat Oct 11 22:10:22 UTC 2014
commit c437c7fb037ba5484608b351ff8c034182519c6c
Author: Damian Johnson <atagar at torproject.org>
Date: Sat Oct 11 15:06:02 2014 -0700
Stacktrace if there aren't any bad relays
If no authorities report bad relays we fail with a stacktrace. Caught by tom
on...
https://trac.torproject.org/projects/tor/ticket/13389
---
consensus_health_checker.py | 3 +++
1 file changed, 3 insertions(+)
diff --git a/consensus_health_checker.py b/consensus_health_checker.py
index 4b2df65..d424ca4 100755
--- a/consensus_health_checker.py
+++ b/consensus_health_checker.py
@@ -608,6 +608,9 @@ def bad_exits_in_sync(latest_consensus, consensuses, votes):
if flagged:
bad_exits[authority] = set(flagged)
+ if not bad_exits:
+ return
+
voting_authorities = set(bad_exits.keys())
agreed_bad_exits = set.intersection(*bad_exits.values())
disagreed_bad_exits = set.union(*bad_exits.values()).difference(agreed_bad_exits)
More information about the tor-commits
mailing list