We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent 2d45c82 commit a9872dfCopy full SHA for a9872df
docs/examples/download_file.py
@@ -5,7 +5,7 @@
5
6
def download_file(reactor, url, destination_filename):
7
destination = open(destination_filename, 'wb')
8
- d = treq.get(url)
+ d = treq.get(url, unbuffered=True)
9
d.addCallback(treq.collect, destination.write)
10
d.addBoth(lambda _: destination.close())
11
return d
0 commit comments