From e05e0e971179a25881cd1272f63aa26391ea35ad Mon Sep 17 00:00:00 2001 From: ThomasV Date: Sat, 31 Mar 2012 12:08:11 +0200 Subject: [PATCH] peers --- client/interface.py | 2 +- client/peers | 11 +++++++++++ 2 files changed, 12 insertions(+), 1 deletion(-) create mode 100755 client/peers diff --git a/client/interface.py b/client/interface.py index 490b6953d..4ed7b284b 100644 --- a/client/interface.py +++ b/client/interface.py @@ -461,7 +461,7 @@ class WalletSynchronizer(threading.Thread): else: self.wallet.up_to_date = False - response = self.interface.responses.get(True,100000000000) # workaround so that it can be keyboard interrupted + response = self.interface.responses.get()#True,100000000000) # workaround so that it can be keyboard interrupted self.handle_response(response) except socket.error: print "socket error" diff --git a/client/peers b/client/peers new file mode 100755 index 000000000..3d6d8a9ff --- /dev/null +++ b/client/peers @@ -0,0 +1,11 @@ +#!/usr/bin/env python + +import socket, time, interface + +i = interface.AsynchronousInterface('ecdsa.org', 50001) +i.start() +i.send([('server.peers.subscribe',[])]) + +while True: + r = i.responses.get(True, 100000000000) + print r.get('result')