MCPcopy Create free account
hub / github.com/ElementsProject/elements / data_received

Method data_received

test/functional/test_framework/p2p.py:212–216  ·  view source on GitHub ↗

asyncio callback when data is read from the socket.

(self, t)

Source from the content-addressed store, hash-verified

210 # Socket read methods
211
212 def data_received(self, t):
213 """asyncio callback when data is read from the socket."""
214 if len(t) > 0:
215 self.recvbuf += t
216 self._on_data()
217
218 def _on_data(self):
219 """Try to read P2P messages from the recv buffer.

Callers

nothing calls this directly

Calls 1

_on_dataMethod · 0.95

Tested by

no test coverage detected