Message229781
Here's a more complete example
@coroutine
put_data(filename, queue, chunksize=16000):
pbzip2 = yield from asyncio.create_subprocess_exec(
'pbzip2', '-cd', filename,
stdout=asyncio.subprocess.PIPE, limit=self.chunksize*2)
while not pbzip2.stdout.at_eof():
data = yield from pbzip2.stdout.read(chunksize)
yield from queue.put(data)
adding the workaround after createing the stream fixes the issue:
pbzip2.stdout.set_transport(pbzip2._transport.get_pipe_transport(1)) |
|
Date |
User |
Action |
Args |
2014-10-21 20:12:10 | wabu | set | recipients:
+ wabu, gvanrossum, vstinner, yselivanov |
2014-10-21 20:12:10 | wabu | set | messageid: <1413922330.06.0.97195688881.issue22685@psf.upfronthosting.co.za> |
2014-10-21 20:12:10 | wabu | link | issue22685 messages |
2014-10-21 20:12:09 | wabu | create | |
|