slightly better notifications. at least, it fixes #652
This commit is contained in:
@@ -45,6 +45,7 @@ class NetworkProxy(threading.Thread):
|
||||
self.subscriptions = {}
|
||||
self.debug = False
|
||||
self.lock = threading.Lock()
|
||||
self.pending_transactions_for_notifications = []
|
||||
|
||||
|
||||
def start(self, start_daemon=False):
|
||||
|
||||
@@ -105,7 +105,6 @@ class Interface(threading.Thread):
|
||||
#json
|
||||
self.message_id = 0
|
||||
self.unanswered_requests = {}
|
||||
self.pending_transactions_for_notifications= []
|
||||
|
||||
# parse server
|
||||
self.server = server
|
||||
|
||||
@@ -111,6 +111,7 @@ class Network(threading.Thread):
|
||||
self.subscriptions = {}
|
||||
self.subscriptions[self.on_banner] = [('server.banner',[])]
|
||||
self.subscriptions[self.on_peers] = [('server.peers.subscribe',[])]
|
||||
self.pending_transactions_for_notifications = []
|
||||
|
||||
|
||||
def is_connected(self):
|
||||
|
||||
@@ -1103,7 +1103,7 @@ class NewWallet:
|
||||
print_error("received transaction that is no longer referenced in history", tx_hash)
|
||||
return
|
||||
self.transactions[tx_hash] = tx
|
||||
self.network.interface.pending_transactions_for_notifications.append(tx)
|
||||
self.network.pending_transactions_for_notifications.append(tx)
|
||||
self.save_transactions()
|
||||
if self.verifier and tx_height>0:
|
||||
self.verifier.add(tx_hash, tx_height)
|
||||
|
||||
Reference in New Issue
Block a user