We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 889c546 commit e6ca3a7Copy full SHA for e6ca3a7
asyncio_micro/asyncio_micro.py
@@ -224,6 +224,7 @@ def awrite(self, buf):
224
# to return immediately (which means it has to buffer all the
225
# data), this method is a coroutine.
226
sz = len(buf)
227
+ log.debug("StreamWriter.awrite(): spooling %d bytes", sz)
228
while True:
229
res = self.s.write(buf)
230
# If we spooled everything, return immediately
@@ -233,6 +234,7 @@ def awrite(self, buf):
233
234
if res is None:
235
res = 0
236
log.debug("StreamWriter.awrite(): spooled partial %d bytes", res)
237
+ assert res < sz
238
buf = buf[res:]
239
sz -= res
240
s = yield IOWrite(self.s)
0 commit comments