From: Brian Warner Date: Fri, 26 Jun 2009 06:20:22 +0000 (-0700) Subject: mutable/filenode.py: set _writekey to None, rather than leaving it missing X-Git-Tag: trac-4000~57 X-Git-Url: https://git.rkrishnan.org/pf/content/en/htmlfontify-example.html?a=commitdiff_plain;h=97ffc8a4182c39ef5f6f3e7022276d51f84bd6ab;p=tahoe-lafs%2Ftahoe-lafs.git mutable/filenode.py: set _writekey to None, rather than leaving it missing This will at least turn the really really weird error when a repair of a readonly mutable file is attempted into a merely really weird assertion that mentions "repair currently requires a writecap". --- diff --git a/src/allmydata/mutable/filenode.py b/src/allmydata/mutable/filenode.py index e3f5a675..7dfc010d 100644 --- a/src/allmydata/mutable/filenode.py +++ b/src/allmydata/mutable/filenode.py @@ -85,6 +85,8 @@ class MutableFileNode: self._uri = IMutableFileURI(myuri) if not self._uri.is_readonly(): self._writekey = self._uri.writekey + else: + self._writekey = None self._readkey = self._uri.readkey self._storage_index = self._uri.storage_index self._fingerprint = self._uri.fingerprint