From b6132c36a1baf5527cd7a67868450e915a57f225 Mon Sep 17 00:00:00 2001 From: Sebastian Silva Date: Sat, 28 Sep 2013 13:11:18 +0000 Subject: fix download of artifacts in Sugar --- diff --git a/sugar_network_webui/app.py b/sugar_network_webui/app.py index 95e2bb7..16e47f3 100644 --- a/sugar_network_webui/app.py +++ b/sugar_network_webui/app.py @@ -331,7 +331,8 @@ def artifact_copy(guid): blob = artifact.get_blob('data') document_path = get_documents_path() with file(os.path.join(document_path, filename), 'w') as f: - f.write(blob.read()) + for chunk in blob: + f.write(chunk) title = _('Artifact has been downloaded.') body = _('Success!\n\n' 'File %(filename)s has been copied to your Documents folder.\n' -- cgit v0.9.1