openstack_container.py: fix a bug in type of ContainerListing.is_truncated.
authorDaira Hopwood <daira@jacaranda.org>
Thu, 14 Feb 2013 22:29:17 +0000 (22:29 +0000)
committerDaira Hopwood <daira@jacaranda.org>
Fri, 17 Apr 2015 21:31:38 +0000 (22:31 +0100)
Signed-off-by: David-Sarah Hopwood <david-sarah@jacaranda.org>
src/allmydata/storage/backends/cloud/cloud_common.py
src/allmydata/storage/backends/cloud/openstack/openstack_container.py

index a1338ebbc132580b81641c79d8dc1d767657ee1f..00004c28602d58b4478306461611ff55105f7490 100644 (file)
@@ -302,6 +302,7 @@ class ContainerItem(object):
 class ContainerListing(object):
     def __init__(self, name, prefix, marker, max_keys, is_truncated,
                  contents=None, common_prefixes=None):
+        precondition(isinstance(is_truncated, str))
         self.name = name
         self.prefix = prefix
         self.marker = marker
index 5474effe855185aca85b8687c3df563987b2a730..4dbcf8a7258e47f5ac1ff0a553a6fa89f80d6ac0 100644 (file)
@@ -262,7 +262,7 @@ class OpenStackContainer(ContainerRetryMixin):
                     return ContainerItem(key, modification_date, etag, size, storage_class)
 
             contents = map(_make_containeritem, items)
-            return ContainerListing(self._container_name, prefix, None, 10000, False, contents=contents)
+            return ContainerListing(self._container_name, prefix, None, 10000, "false", contents=contents)
         d.addCallback(_parse_list)
         return d