Re: [PATCH] Fix typo in Message.maildir_flags_to_tags
[notmuch-archives.git] / 31 / a6afc3ae26670dc0a485c3b7f0af5e1bc96bd7
1 Return-Path: <cworth@cworth.org>\r
2 X-Original-To: notmuch@notmuchmail.org\r
3 Delivered-To: notmuch@notmuchmail.org\r
4 Received: from localhost (localhost [127.0.0.1])\r
5         by olra.theworths.org (Postfix) with ESMTP id 44ED04196F0\r
6         for <notmuch@notmuchmail.org>; Thu,  4 Nov 2010 12:32:00 -0700 (PDT)\r
7 X-Virus-Scanned: Debian amavisd-new at olra.theworths.org\r
8 X-Spam-Flag: NO\r
9 X-Spam-Score: -2.89\r
10 X-Spam-Level: \r
11 X-Spam-Status: No, score=-2.89 tagged_above=-999 required=5\r
12         tests=[ALL_TRUSTED=-1, BAYES_00=-1.9, T_MIME_NO_TEXT=0.01]\r
13         autolearn=ham\r
14 Received: from olra.theworths.org ([127.0.0.1])\r
15         by localhost (olra.theworths.org [127.0.0.1]) (amavisd-new, port 10024)\r
16         with ESMTP id I+W+SBKCzaHP; Thu,  4 Nov 2010 12:31:48 -0700 (PDT)\r
17 Received: from yoom.home.cworth.org (localhost [127.0.0.1])\r
18         by olra.theworths.org (Postfix) with ESMTP id AEBD040D156;\r
19         Thu,  4 Nov 2010 12:31:48 -0700 (PDT)\r
20 Received: by yoom.home.cworth.org (Postfix, from userid 1000)\r
21         id 6A938254102; Thu,  4 Nov 2010 12:31:48 -0700 (PDT)\r
22 From: Carl Worth <cworth@cworth.org>\r
23 To: Sebastian Spaeth <Sebastian@SSpaeth.de>, notmuch <notmuch@notmuchmail.org>\r
24 Subject: Re: Python bindings and Xapian exceptions\r
25 In-Reply-To: <878w6gis5g.fsf@SSpaeth.de>\r
26 References: <87k4q7s43v.fsf@ut.hh.sledj.net> <878w6gis5g.fsf@SSpaeth.de>\r
27 User-Agent: Notmuch/0.4 (http://notmuchmail.org) Emacs/23.2.1\r
28         (i486-pc-linux-gnu)\r
29 Date: Thu, 04 Nov 2010 12:31:48 -0700\r
30 Message-ID: <871v70ril7.fsf@yoom.home.cworth.org>\r
31 MIME-Version: 1.0\r
32 Content-Type: multipart/signed; boundary="=-=-=";\r
33         micalg=pgp-sha1; protocol="application/pgp-signature"\r
34 X-BeenThere: notmuch@notmuchmail.org\r
35 X-Mailman-Version: 2.1.13\r
36 Precedence: list\r
37 List-Id: "Use and development of the notmuch mail system."\r
38         <notmuch.notmuchmail.org>\r
39 List-Unsubscribe: <http://notmuchmail.org/mailman/options/notmuch>,\r
40         <mailto:notmuch-request@notmuchmail.org?subject=unsubscribe>\r
41 List-Archive: <http://notmuchmail.org/pipermail/notmuch>\r
42 List-Post: <mailto:notmuch@notmuchmail.org>\r
43 List-Help: <mailto:notmuch-request@notmuchmail.org?subject=help>\r
44 List-Subscribe: <http://notmuchmail.org/mailman/listinfo/notmuch>,\r
45         <mailto:notmuch-request@notmuchmail.org?subject=subscribe>\r
46 X-List-Received-Date: Thu, 04 Nov 2010 19:32:00 -0000\r
47 \r
48 --=-=-=\r
49 Content-Transfer-Encoding: quoted-printable\r
50 \r
51 On Tue, 15 Jun 2010 11:03:55 +0200, "Sebastian Spaeth" <Sebastian@SSpaeth.d=\r
52 e> wrote:\r
53 > >   A Xapian exception occurred finding message: The revision being read\r
54 > >   has been discarded - you should call Xapian::Database::reopen() and\r
55 > >   retry the operation.\r
56 > > It makes the Python bindings almost useless to me.\r
57 >=20\r
58 > Not sure, if the python bindings should simply drop and reopen a\r
59 > database connection in that case? But I am not sure if libnotmuch.so\r
60 > still simply exits on such an error case.\r
61 >=20\r
62 > The proper fix, and a reason why I am not immediately hacking around in\r
63 > the python bindings is that notmuch the library would actually return a\r
64 > proper error value rather than print to stderr and quit.\r
65 \r
66 For this particular case, I think the correct thing is for the library\r
67 to simply do the reopen() itself.\r
68 \r
69 That way we can pretend that Xapian doesn't make readers block on\r
70 writers.\r
71 \r
72 But for exceptions in general, yes the notmuch library does need to be\r
73 fixed to allow the caller of functions to distinguish between things\r
74 like "no matches found" and "an exception occurred, so it's unknown if\r
75 any messages match the search". That's a general class of library\r
76 interface bugs that all need to be fixed.\r
77 \r
78 =2DCarl\r
79 \r
80 =2D-=20\r
81 carl.d.worth@intel.com\r
82 \r
83 --=-=-=\r
84 Content-Type: application/pgp-signature\r
85 \r
86 -----BEGIN PGP SIGNATURE-----\r
87 Version: GnuPG v1.4.10 (GNU/Linux)\r
88 \r
89 iD8DBQFM0wok6JDdNq8qSWgRAuf1AJsHfbfw6HCVZ16F4Z4lqKpdNnn0PACdHSyP\r
90 UH51CHsHkDx8hs1tmT5MojI=\r
91 =Omjk\r
92 -----END PGP SIGNATURE-----\r
93 --=-=-=--\r