mirror of
https://github.com/dashpay/dash.git
synced 2024-12-27 21:12:48 +01:00
qa: Expose on-connection to mininode listeners
This commit is contained in:
parent
8aaba7a6b7
commit
b436f92f72
@ -1540,6 +1540,7 @@ class NodeConnCB(object):
|
|||||||
if conn.ver_send > BIP0031_VERSION:
|
if conn.ver_send > BIP0031_VERSION:
|
||||||
conn.send_message(msg_pong(message.nonce))
|
conn.send_message(msg_pong(message.nonce))
|
||||||
def on_reject(self, conn, message): pass
|
def on_reject(self, conn, message): pass
|
||||||
|
def on_open(self, conn): pass
|
||||||
def on_close(self, conn): pass
|
def on_close(self, conn): pass
|
||||||
def on_mempool(self, conn): pass
|
def on_mempool(self, conn): pass
|
||||||
def on_pong(self, conn, message): pass
|
def on_pong(self, conn, message): pass
|
||||||
@ -1657,6 +1658,7 @@ class NodeConn(asyncore.dispatcher):
|
|||||||
if self.state != "connected":
|
if self.state != "connected":
|
||||||
self.show_debug_msg("MiniNode: Connected & Listening: \n")
|
self.show_debug_msg("MiniNode: Connected & Listening: \n")
|
||||||
self.state = "connected"
|
self.state = "connected"
|
||||||
|
self.cb.on_open(self)
|
||||||
|
|
||||||
def handle_close(self):
|
def handle_close(self):
|
||||||
self.show_debug_msg("MiniNode: Closing Connection to %s:%d... "
|
self.show_debug_msg("MiniNode: Closing Connection to %s:%d... "
|
||||||
|
Loading…
Reference in New Issue
Block a user