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 a38cf1a commit a061e56Copy full SHA for a061e56
src/macaron/util.py
@@ -339,6 +339,7 @@ def stream_file_with_size_limit(
339
size_limit: int
340
The size limit in bytes of the downloaded file.
341
A download will terminate if it reaches beyond this amount.
342
+ The default value of zero disables the limit.
343
344
Returns
345
-------
@@ -356,7 +357,7 @@ def stream_file_with_size_limit(
356
357
return False
358
359
data_processed = 0
- for chunk in response.iter_content(chunk_size=1048576):
360
+ for chunk in response.iter_content(chunk_size=512):
361
if data_processed >= size_limit > 0:
362
response.close()
363
logger.warning(
0 commit comments