1
0
mirror of https://github.com/instaloader/instaloader.git synced 2024-11-09 03:42:31 +01:00

Fix instaloadercontext.get_and_write_raw()

This commit is contained in:
André Koch-Kramer 2018-04-10 09:51:35 +02:00
parent c7f6cff15a
commit dd1cbf0a1d

View File

@ -315,7 +315,7 @@ class InstaloaderContext:
:raises ConnectionException: When download repeatedly failed.""" :raises ConnectionException: When download repeatedly failed."""
try: try:
with self.get_anonymous_session() as anonymous_session: with self.get_anonymous_session() as anonymous_session:
resp = anonymous_session.get(url) resp = anonymous_session.get(url, stream=True)
if resp.status_code == 200: if resp.status_code == 200:
self.log(filename, end=' ', flush=True) self.log(filename, end=' ', flush=True)
with open(filename, 'wb') as file: with open(filename, 'wb') as file: