Message305624
When using highlevel request() api, users can control the block size by
wrapping the file object with an iterator:
class FileIter:
def __init__(self, file, blocksize):
self.file = file
self.blocksize = blocksize
def __iter__(self):
while True:
datablock = self.file.read(self.blocksize)
if not datablock:
break
yield datablock
Adding configurable block size will avoid this workaround. |
|
Date |
User |
Action |
Args |
2017-11-06 09:57:49 | nirs | set | recipients:
+ nirs, brett.cannon, vstinner, serhiy.storchaka, yselivanov |
2017-11-06 09:57:49 | nirs | set | messageid: <1509962269.15.0.213398074469.issue31945@psf.upfronthosting.co.za> |
2017-11-06 09:57:49 | nirs | link | issue31945 messages |
2017-11-06 09:57:49 | nirs | create | |
|