[tor-commits] [fallback-scripts/master] lookup: Explicitly say "no contact"
teor at torproject.org
teor at torproject.org
Mon Jan 20 05:32:01 UTC 2020
commit 218778081da63af9b4dbe7cfddb59cab86259b07
Author: teor <teor at torproject.org>
Date: Mon Dec 2 14:26:48 2019 +1000
lookup: Explicitly say "no contact"
Rather than just printing "None".
Part of 28863.
---
lookupFallbackDirContact.py | 5 +++--
1 file changed, 3 insertions(+), 2 deletions(-)
diff --git a/lookupFallbackDirContact.py b/lookupFallbackDirContact.py
index 14c53d1..88bad62 100755
--- a/lookupFallbackDirContact.py
+++ b/lookupFallbackDirContact.py
@@ -21,8 +21,9 @@ descriptor_list_fingerprints = []
for d in descriptor_list:
assert d.fingerprint in sys.argv[1:]
descriptor_list_fingerprints.append(d.fingerprint)
- print "{} {}".format(d.fingerprint, d.contact)
+ contact = d.contact if d.contact else "(no contact)"
+ print "{} {}".format(d.fingerprint, contact)
for fingerprint in sys.argv[1:]:
if fingerprint not in descriptor_list_fingerprints:
- print "{} not found in current descriptors".format(fingerprint)
+ print "{} # not found in current descriptors".format(fingerprint)
More information about the tor-commits
mailing list