aboutsummaryrefslogtreecommitdiffstats
path: root/libbe/comment.py
diff options
context:
space:
mode:
authorW. Trevor King <wking@drexel.edu>2011-04-16 21:01:53 -0400
committerW. Trevor King <wking@drexel.edu>2011-04-16 21:07:48 -0400
commit54801289d1c29a57571c3630a438f811370d74cd (patch)
tree5a3c02e2ef8171e33b48811fc0bf4c2725dcf28e /libbe/comment.py
parent933257520d63aac7ab4112fd915206d389fc42a1 (diff)
downloadbugseverywhere-54801289d1c29a57571c3630a438f811370d74cd.tar.gz
Raise exceptions if bug or comment value files are missing.
This happens most often when a previous crash leaves an empty directory `abc` in .be/.../bugs/abc/ or .be/.../bugs/.../comments/abc/. The new exception ensures the error message is "Bug/Comment X missing value file" which tells you where to look for the repository corruption not "summary is None" which told you nothing.
Diffstat (limited to 'libbe/comment.py')
-rw-r--r--libbe/comment.py3
1 files changed, 1 insertions, 2 deletions
diff --git a/libbe/comment.py b/libbe/comment.py
index 8ffb3cd..081ba59 100644
--- a/libbe/comment.py
+++ b/libbe/comment.py
@@ -611,8 +611,7 @@ class Comment (Tree, settings_object.SavedSettingsObject):
if self.uuid == INVALID_UUID:
return
if settings_mapfile == None:
- settings_mapfile = \
- self.storage.get(self.id.storage("values"), default="\n")
+ settings_mapfile = self.storage.get(self.id.storage('values'))
try:
settings = mapfile.parse(settings_mapfile)
except mapfile.InvalidMapfileContents, e: