]> git.rkrishnan.org Git - tahoe-lafs/tahoe-lafs.git/commitdiff
prevent reading unfinished buckets
authorRob Kinninmont <robk@allmydata.com>
Fri, 1 Dec 2006 09:48:27 +0000 (02:48 -0700)
committerRob Kinninmont <robk@allmydata.com>
Fri, 1 Dec 2006 09:48:27 +0000 (02:48 -0700)
allmydata/bucketstore.py

index 0348b5acc06ec016a87cb89747445bbe4c088f40..84b7083a36923e07c5c7a77604771db1af407d63 100644 (file)
@@ -41,6 +41,7 @@ class BucketStore(service.MultiService, Referenceable):
         # for now, only returns those created by this process, in this run
         bucket = self._buckets.get(verifierid)
         if bucket:
+            precondition(bucket.is_complete())
             return BucketReader(bucket)
         elif os.path.exists(self._get_bucket_dir(verifierid)):
             bucket_dir = self._get_bucket_dir(verifierid)