MCPcopy Create free account
hub / github.com/bslatkin/effectivepython / send

Method send

example_code/item_076.py:291–295  ·  view source on GitHub ↗
(self, command)

Source from the content-addressed store, hash-verified

289 self.writer = writer # Changed
290
291 async def send(self, command):
292 line = command + "\n"
293 data = line.encode()
294 self.writer.write(data) # Changed
295 await self.writer.drain() # Changed
296
297 async def receive(self):
298 line = await self.reader.readline() # Changed

Callers

nothing calls this directly

Calls 1

writeMethod · 0.80

Tested by

no test coverage detected