Re: bug#6214: 23.1; json-read-string crashes emacs with long string
[notmuch-archives.git] / 82 / cdb1ca4fd295dba06f8863054eba72ee1b20b8
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 D2D6C431FBF\r
6         for <notmuch@notmuchmail.org>; Fri,  5 Feb 2010 17:41:55 -0800 (PST)\r
7 X-Virus-Scanned: Debian amavisd-new at olra.theworths.org\r
8 X-Spam-Flag: NO\r
9 X-Spam-Score: -1.88\r
10 X-Spam-Level: \r
11 X-Spam-Status: No, score=-1.88 tagged_above=-999 required=5\r
12         tests=[ALL_TRUSTED=-1.8, AWL=-0.081, BAYES_50=0.001] autolearn=ham\r
13 Received: from olra.theworths.org ([127.0.0.1])\r
14         by localhost (olra.theworths.org [127.0.0.1]) (amavisd-new, port 10024)\r
15         with ESMTP id U8hgvaEPjqZg; Fri,  5 Feb 2010 17:41:55 -0800 (PST)\r
16 Received: from yoom.home.cworth.org (localhost [127.0.0.1])\r
17         by olra.theworths.org (Postfix) with ESMTP id 0B3D9431FAE;\r
18         Fri,  5 Feb 2010 17:41:55 -0800 (PST)\r
19 Received: by yoom.home.cworth.org (Postfix, from userid 1000)\r
20         id B3FC0254181; Sat,  6 Feb 2010 14:41:54 +1300 (NZDT)\r
21 From: Carl Worth <cworth@cworth.org>\r
22 To: david@tethera.net, notmuch@notmuchmail.org\r
23 In-Reply-To: <87my1z97un.wl%bremner@pivot.cs.unb.ca>\r
24 References: <87zl60xjl7.wl%bremner@pivot.cs.unb.ca>\r
25         <87my1z97un.wl%bremner@pivot.cs.unb.ca>\r
26 Date: Fri, 05 Feb 2010 17:41:48 -0800\r
27 Message-ID: <87ock3cf8j.fsf@yoom.home.cworth.org>\r
28 MIME-Version: 1.0\r
29 Content-Type: multipart/signed; boundary="=-=-=";\r
30         micalg=pgp-sha1; protocol="application/pgp-signature"\r
31 Subject: Re: [notmuch] hack to retag a directory\r
32 X-BeenThere: notmuch@notmuchmail.org\r
33 X-Mailman-Version: 2.1.13\r
34 Precedence: list\r
35 List-Id: "Use and development of the notmuch mail system."\r
36         <notmuch.notmuchmail.org>\r
37 List-Unsubscribe: <http://notmuchmail.org/mailman/options/notmuch>,\r
38         <mailto:notmuch-request@notmuchmail.org?subject=unsubscribe>\r
39 List-Archive: <http://notmuchmail.org/pipermail/notmuch>\r
40 List-Post: <mailto:notmuch@notmuchmail.org>\r
41 List-Help: <mailto:notmuch-request@notmuchmail.org?subject=help>\r
42 List-Subscribe: <http://notmuchmail.org/mailman/listinfo/notmuch>,\r
43         <mailto:notmuch-request@notmuchmail.org?subject=subscribe>\r
44 X-List-Received-Date: Sat, 06 Feb 2010 01:41:56 -0000\r
45 \r
46 --=-=-=\r
47 Content-Transfer-Encoding: quoted-printable\r
48 \r
49 On Thu, 03 Dec 2009 15:26:56 -0400, david@tethera.net wrote:\r
50 > > I think this will be obsolete pretty soon when the equivalent is\r
51 > > built-in to notmuch, but in the mean time, here is a script that\r
52 > > somebody might find useful: retag a whole directory (recursively). I\r
53 > > don't claim it is nice in any way, but it seems usable for me, taking\r
54 > > about 5 seconds to retag a directory containing 1000 messages.\r
55 >=20\r
56 > Sigh. And of course the version I posted was broken. I put a fixed versio=\r
57 n at=20\r
58 >=20\r
59 >       http://pivot.cs.unb.ca/git/?p=3Dnotmuch-scripts.git;a=3Dblob_plain;=\r
60 f=3Dtagdir;hb=3DHEAD\r
61 \r
62 Thanks for sharing that, David.\r
63 \r
64 Obviously, we now have outstanding patches to provide search\r
65 capabilities based on the folder containing messages. So once that gets\r
66 merged, you shouldn't need this script anymore.\r
67 \r
68 > You might, or might not also be interested in=20\r
69 >=20\r
70 >     http://pivot.cs.unb.ca/git/?p=3Dnotmuch-scripts.git;a=3Dblob_plain;f=\r
71 =3Dgitmuch;hb=3DHEAD\r
72 >=20\r
73 > which is the beginnings of how to keep tags in git (for syncing\r
74 > between machines).\r
75 \r
76 But this one looks quite interesting. Obviously, it's not a complex\r
77 script, but it looks pretty handy to me. I might start using this to\r
78 have a little history of my tag changes, (rather than just including the\r
79 dump output in occasional backups like I have been doing).\r
80 \r
81 And it's interesting that this script might be just good enough for the\r
82 synchronization needs of some people. It's not integrated, and might\r
83 require manual fixup of any resulting git conflicts, but it might be\r
84 handy for some.\r
85 \r
86 The biggest problem I see is that if I were to read some messages\r
87 locally, and then run "gitmuch restore" then this would wipe out the\r
88 local changes I had made. So we'll definitely want a more integrated\r
89 solution to eliminate the chance of problems like this.\r
90 \r
91 >                     Right now the notmuch restore step is the\r
92 > bottleneck, but Carl apparently knows how to speed 'notmuch restore'\r
93 > up.\r
94 \r
95 One easy answer is to just make "notmuch restore" do nothing for\r
96 messages where the existing tags are the same as the tags mentioned in\r
97 the input file. I just pushed a change to implement this, (along with\r
98 new tests for "notmuch dump" and "notmuch restore" of course).\r
99 \r
100 For me, this takes a "notmuch restore" right after a "notmuch dump" from\r
101 about 10 minutes down to 1 minute, (and it was about 2 hours before the\r
102 Xapian Defect #250 fix).\r
103 \r
104 The other idea that I didn't do yet is to change "notmuch restore" to do\r
105 a single search for all messages rather than N searches each resulting\r
106 in 1 message. But the 1-minute time I'm getting for "notmuch restore"\r
107 now is basically the same time required for a "notmuch dump", (which is\r
108 already doing a single global search). So perhaps Xapian is just plain\r
109 fast enough that a change like that won't help at all.\r
110 \r
111 =2DCarl\r
112 \r
113 --=-=-=\r
114 Content-Type: application/pgp-signature\r
115 \r
116 -----BEGIN PGP SIGNATURE-----\r
117 Version: GnuPG v1.4.10 (GNU/Linux)\r
118 \r
119 iD8DBQFLbMjc6JDdNq8qSWgRAv/JAJ0Ww9bYrhClItuBwMjYpGVYyUn3+gCghVes\r
120 iYbcAXtggeCYCuKgRl6ibzM=\r
121 =sKdH\r
122 -----END PGP SIGNATURE-----\r
123 --=-=-=--\r