Merge "Handle StopIteration for Py3.7"

This commit is contained in:
Zuul
2018-08-23 01:28:45 +00:00
committed by Gerrit Code Review

View File

@@ -395,7 +395,10 @@ class ResponseBodyIterator(object):
def __iter__(self):
while True:
yield self.next()
try:
yield self.next()
except StopIteration:
return
def next(self):
chunk = self.resp.read(CHUNKSIZE)