cleanup
This commit is contained in:
parent
f487e27416
commit
7baaa63908
|
@ -126,15 +126,14 @@ class Interface:
|
||||||
self.tx_event.set()
|
self.tx_event.set()
|
||||||
|
|
||||||
elif method == 'numblocks.subscribe':
|
elif method == 'numblocks.subscribe':
|
||||||
print "numblocks", result
|
|
||||||
self.blocks = result
|
self.blocks = result
|
||||||
if self.newblock_callback: apply(self.newblock_callback,(result,))
|
if self.newblock_callback: apply(self.newblock_callback,(result,))
|
||||||
|
|
||||||
elif method == 'ping':
|
elif method == 'client.version':
|
||||||
pass
|
pass
|
||||||
|
|
||||||
else:
|
else:
|
||||||
print "received message:", method, params, result
|
print "unknown message:", method, params, result
|
||||||
|
|
||||||
|
|
||||||
def subscribe(self, addresses):
|
def subscribe(self, addresses):
|
||||||
|
@ -321,7 +320,7 @@ class HttpInterface(PollingInterface):
|
||||||
|
|
||||||
response = response_stream.read()
|
response = response_stream.read()
|
||||||
if response:
|
if response:
|
||||||
print "response",response
|
#print "response",response
|
||||||
response = json.loads( response )
|
response = json.loads( response )
|
||||||
if type(response) is not type([]):
|
if type(response) is not type([]):
|
||||||
self.handle_json_response(response)
|
self.handle_json_response(response)
|
||||||
|
|
Loading…
Reference in New Issue