error handling

This commit is contained in:
thomasv 2012-02-02 17:42:00 +01:00
parent 1a7a270901
commit 85c16d10d7

View file

@ -76,13 +76,13 @@ if __name__ == '__main__':
elif k =='signer':
signer = uv
if not wallet.is_valid(signer):
print signer
print "trying canonical URL"
import urllib
url = 'http://'+signer+'/bitcoin.id'
print url
signer = urllib.urlopen(url).read().strip()
print repr(signer)
try:
signer = urllib.urlopen(url).read().strip()
except:
# no need to display something, the signature verification will fail anyway
pass
else: print k,v
if k in ['signer','signature']: