You are viewing a plain text version of this content. The canonical link for it is here.
Posted to notifications@libcloud.apache.org by to...@apache.org on 2011/04/09 18:25:07 UTC
svn commit: r1090624 - in /incubator/libcloud/trunk/libcloud/storage:
base.py drivers/cloudfiles.py
Author: tomaz
Date: Sat Apr 9 16:25:07 2011
New Revision: 1090624
URL: http://svn.apache.org/viewvc?rev=1090624&view=rev
Log:
Return RawResponse instance.
Modified:
incubator/libcloud/trunk/libcloud/storage/base.py
incubator/libcloud/trunk/libcloud/storage/drivers/cloudfiles.py
Modified: incubator/libcloud/trunk/libcloud/storage/base.py
URL: http://svn.apache.org/viewvc/incubator/libcloud/trunk/libcloud/storage/base.py?rev=1090624&r1=1090623&r2=1090624&view=diff
==============================================================================
--- incubator/libcloud/trunk/libcloud/storage/base.py (original)
+++ incubator/libcloud/trunk/libcloud/storage/base.py Sat Apr 9 16:25:07 2011
@@ -526,7 +526,7 @@ class StorageDriver(object):
raise LibcloudError(value='Object upload failed, Perhaps a timeout?',
driver=self)
- result_dict = { 'response': response.response, 'data_hash': data_hash,
+ result_dict = { 'response': response, 'data_hash': data_hash,
'bytes_transferred': bytes_transferred }
return result_dict
@@ -575,10 +575,7 @@ class StorageDriver(object):
else:
response.connection.connection.send(chunk)
except Exception:
- # @@TR: this wildcard try/except block looks like it
- # could mask unexpected errors. It should be narrowed
- # down to expected exceptions.
-
+ # TODO: let this exception propagate
# Timeout, etc.
return False, None, bytes_transferred
Modified: incubator/libcloud/trunk/libcloud/storage/drivers/cloudfiles.py
URL: http://svn.apache.org/viewvc/incubator/libcloud/trunk/libcloud/storage/drivers/cloudfiles.py?rev=1090624&r1=1090623&r2=1090624&view=diff
==============================================================================
--- incubator/libcloud/trunk/libcloud/storage/drivers/cloudfiles.py (original)
+++ incubator/libcloud/trunk/libcloud/storage/drivers/cloudfiles.py Sat Apr 9 16:25:07 2011
@@ -342,7 +342,7 @@ class CloudFilesStorageDriver(StorageDri
headers=headers, file_path=file_path,
iterator=iterator)
- response = result_dict['response']
+ response = result_dict['response'].response
bytes_transferred = result_dict['bytes_transferred']
if response.status == httplib.EXPECTATION_FAILED: