aboutsummaryrefslogtreecommitdiffhomepage
diff options
context:
space:
mode:
authorGravatar W. Trevor King <wking@tremily.us>2014-02-10 10:40:28 -0800
committerGravatar David Bremner <david@tethera.net>2014-02-10 22:46:37 -0400
commita7e4d9a18fdd9dd0aa3f2ec257d17e364a732876 (patch)
treefd6d735ff2f7482176b3570e1aa86051eb1d87bd
parente4d79bfddb7e8f34f991c9d4ee0256c530187c23 (diff)
nmbug-status: Don't require write access
The database in only used for notmuch.Query, so there's no need for write access. This allows nmbug-status to run while the database is being updated, without raising: A Xapian exception occurred opening database: Unable to get write lock on …: already locked Traceback (most recent call last): File "./nmbug-status", line 182, in <module> db = notmuch.Database(mode=notmuch.Database.MODE.READ_WRITE) File "/…/notmuch/database.py", line 154, in __init__ self.open(path, mode) File "/…/notmuch/database.py", line 214, in open raise NotmuchError(status) notmuch.errors.XapianError
-rwxr-xr-xdevel/nmbug/nmbug-status2
1 files changed, 1 insertions, 1 deletions
diff --git a/devel/nmbug/nmbug-status b/devel/nmbug/nmbug-status
index 199892f7..be3e28e7 100755
--- a/devel/nmbug/nmbug-status
+++ b/devel/nmbug/nmbug-status
@@ -180,7 +180,7 @@ else:
# main program
-db = notmuch.Database(mode=notmuch.Database.MODE.READ_WRITE)
+db = notmuch.Database(mode=notmuch.Database.MODE.READ_ONLY)
if output_format == 'html':
print('''<?xml version="1.0" encoding="utf-8" ?>