sup

A curses threads-with-tags style email client

sup-website.git

git clone https://supmua.dev/git/sup-website/

community/pipermail-archives/sup-talk/2009-08.txt (446072B) - raw

      1 From rlane@club.cc.cmu.edu  Sat Aug  1 02:28:19 2009
      2 From: rlane@club.cc.cmu.edu (Rich Lane)
      3 Date: Sat, 01 Aug 2009 02:28:19 -0400
      4 Subject: [sup-talk] xapian question
      5 In-Reply-To: <1248807365-sup-4965@masanjin.net>
      6 References: <1248716325-sup-7534@masanjin.net>
      7 	<1248795865-sup-6634@pion.club.cc.cmu.edu>
      8 	<1248807365-sup-4965@masanjin.net>
      9 Message-ID: <1249098509-sup-6664@pion.club.cc.cmu.edu>
     10 
     11 I tried out using add_term/remove_term for immediate label changes. It's
     12 significantly faster than sync_message, but it still makes the interface
     13 feel laggy. There's known room for improvement in Xapian's
     14 replace_document. However, we'll still have a lot of latency when we
     15 start using remote sup-servers, so I don't think it's a good idea to do
     16 these index operations synchronously with the UI.
     17 
     18 We could queue up index writes and execute them in a background thread.
     19 We'd want label additions to show up immediately in a search, though.
     20 This is easy to do for inbox-mode and label-view-mode, which covers most
     21 of my daily usage. If/when we support multiple clients connecting to a
     22 sup-server, we'll need a way to notify them that someone else modified a
     23 message. We can implement a simple version of this now that notifies
     24 search-results-mode after the write completes.
     25 
     26 If we're getting rid of buffer saving, it'd probably be easiest to use a
     27 weak-ref table so we keep at most 1 copy of each message in memory -
     28 this would make updating messages across buffers simpler.
     29 
     30 How is sup-server development going?
     31 
     32 From mailinglist@flasht.de  Sat Aug  1 05:26:25 2009
     33 From: mailinglist@flasht.de (Christopher Bertels)
     34 Date: Sat, 01 Aug 2009 11:26:25 +0200
     35 Subject: [sup-talk] Smooth Paging
     36 In-Reply-To: <1249055039-sup-8105@masanjin.net>
     37 References: <1249053249-sup-9884@Longbow> <1249055039-sup-8105@masanjin.net>
     38 Message-ID: <1249118728-sup-5483@thinkpad-debian>
     39 
     40 Excerpts from William Morgan's message of Fr Jul 31 17:44:25 +0200 2009:
     41 > Have you tried J and K vs j and k to scroll?
     42 
     43 Wow, cool. :) 
     44 Good to know.
     45 -- 
     46 ================================
     47 Christopher Bertels
     48 http://www.adztec-independent.de
     49 
     50 From guillaume.quintard@gmail.com  Sat Aug  1 13:44:50 2009
     51 From: guillaume.quintard@gmail.com (Guillaume Quintard)
     52 Date: Sat, 1 Aug 2009 19:44:50 +0200
     53 Subject: [sup-talk] Fwd:  xapian merged into next
     54 In-Reply-To: <1e5fdab70908010934l30373447r4a405c5ca0e406f9@mail.gmail.com>
     55 References: <1248711109-sup-7061@entry>
     56 	<1e5fdab70907270916o2f8e1768vbe7e3bcc1c807e39@mail.gmail.com>
     57 	<1248711777-sup-9329@entry>
     58 	<1e5fdab70907270931t7dfbe285h67197a7355b611d6@mail.gmail.com>
     59 	<1248712876-sup-1446@entry>
     60 	<1e5fdab70907270947n1866decdoc8a568cc9a2733ae@mail.gmail.com>
     61 	<1248713360-sup-5448@entry>
     62 	<1e5fdab70907271009v46639384w4bb3461ccaccf0cc@mail.gmail.com>
     63 	<1248716073-sup-7443@masanjin.net>
     64 	<1e5fdab70908010934l30373447r4a405c5ca0e406f9@mail.gmail.com>
     65 Message-ID: <1e5fdab70908011044q6743d213o554a7bd039e237c2@mail.gmail.com>
     66 
     67 I get this when I run "SUP_INDEX=xapian ruby -Ilib bin/sup-sync --all
     68 --all-sources --restore dumpfile" (only had the time to do it today):
     69 
     70 ./lib/sup/xapian_index.rb:435:in `replace_document':
     71 InvalidArgumentError: Term too long (> 245):
     72 E"name.surname at enst-bretagne.fr,
     73 my_name.my_surname at enst-bretagne.fr, name.surname at enst-bretagne.fr,
     74 name.surname at enst-bretagne.fr,
     75 name.surname at telecom-bretagne.eu,
     76 name.surname at telecom-bretagne.eu,
     77 name.surname at telecom-bretagne.eu, name.surname"@telecom-bretagne.eu
     78 (ArgumentError)
     79 ? ? ? ?from ./lib/sup/xapian_index.rb:435:in `index_message'
     80 ? ? ? ?from ./lib/sup/xapian_index.rb:117:in `sync_message'
     81 ? ? ? ?from /usr/lib/ruby/1.8/monitor.rb:242:in `synchronize'
     82 ? ? ? ?from ./lib/sup/xapian_index.rb:330:in `synchronize'
     83 ? ? ? ?from ./lib/sup/xapian_index.rb:116:in `sync_message'
     84 ? ? ? ?from ./lib/sup/util.rb:519:in `send'
     85 ? ? ? ?from ./lib/sup/util.rb:519:in `method_missing'
     86 ? ? ? ?from ./lib/sup/poll.rb:157:in `add_messages_from'
     87 ? ? ? ?from ./lib/sup/source.rb:100:in `each'
     88 ? ? ? ?from ./lib/sup/util.rb:558:in `send'
     89 ? ? ? ?from ./lib/sup/util.rb:558:in `__pass'
     90 ? ? ? ?from ./lib/sup/util.rb:545:in `method_missing'
     91 ? ? ? ?from ./lib/sup/poll.rb:141:in `add_messages_from'
     92 ? ? ? ?from ./lib/sup/util.rb:519:in `send'
     93 ? ? ? ?from ./lib/sup/util.rb:519:in `method_missing'
     94 ? ? ? ?from bin/sup-sync:140
     95 ? ? ? ?from bin/sup-sync:135:in `each'
     96 ? ? ? ?from bin/sup-sync:135
     97 
     98 Cheers!
     99 
    100 -- 
    101 Guillaume
    102 
    103 From rlane@club.cc.cmu.edu  Sat Aug  1 14:14:34 2009
    104 From: rlane@club.cc.cmu.edu (Rich Lane)
    105 Date: Sat, 01 Aug 2009 14:14:34 -0400
    106 Subject: [sup-talk] Fwd: xapian merged into next
    107 In-Reply-To: <1e5fdab70908011044q6743d213o554a7bd039e237c2@mail.gmail.com>
    108 References: <1248711109-sup-7061@entry>
    109 	<1e5fdab70907270916o2f8e1768vbe7e3bcc1c807e39@mail.gmail.com>
    110 	<1248711777-sup-9329@entry>
    111 	<1e5fdab70907270931t7dfbe285h67197a7355b611d6@mail.gmail.com>
    112 	<1248712876-sup-1446@entry>
    113 	<1e5fdab70907270947n1866decdoc8a568cc9a2733ae@mail.gmail.com>
    114 	<1248713360-sup-5448@entry>
    115 	<1e5fdab70907271009v46639384w4bb3461ccaccf0cc@mail.gmail.com>
    116 	<1248716073-sup-7443@masanjin.net>
    117 	<1e5fdab70908010934l30373447r4a405c5ca0e406f9@mail.gmail.com>
    118 	<1e5fdab70908011044q6743d213o554a7bd039e237c2@mail.gmail.com>
    119 Message-ID: <1249149855-sup-2211@pion.club.cc.cmu.edu>
    120 
    121 Excerpts from Guillaume Quintard's message of Sat Aug 01 13:44:50 -0400 2009:
    122 > E"name.surname at enst-bretagne.fr,
    123 > my_name.my_surname at enst-bretagne.fr, name.surname at enst-bretagne.fr,
    124 > name.surname at enst-bretagne.fr,
    125 > name.surname at telecom-bretagne.eu,
    126 > name.surname at telecom-bretagne.eu,
    127 > name.surname at telecom-bretagne.eu, name.surname"@telecom-bretagne.eu
    128 
    129 That's a very strange email address :). Could you track down the message
    130 causing this and post the headers? It looks like it's getting parsed
    131 incorrectly.
    132 
    133 I think we'd be safe not adding terms for email addresses longer than
    134 244 characters on the assumption that the user isn't going to want to
    135 search for them.
    136 
    137 From guillaume.quintard@gmail.com  Sat Aug  1 14:31:55 2009
    138 From: guillaume.quintard@gmail.com (Guillaume Quintard)
    139 Date: Sat, 01 Aug 2009 20:31:55 +0200
    140 Subject: [sup-talk] Fwd: xapian merged into next
    141 In-Reply-To: <1249149855-sup-2211@pion.club.cc.cmu.edu>
    142 References: <1248711109-sup-7061@entry>
    143 	<1e5fdab70907270916o2f8e1768vbe7e3bcc1c807e39@mail.gmail.com>
    144 	<1248711777-sup-9329@entry>
    145 	<1e5fdab70907270931t7dfbe285h67197a7355b611d6@mail.gmail.com>
    146 	<1248712876-sup-1446@entry>
    147 	<1e5fdab70907270947n1866decdoc8a568cc9a2733ae@mail.gmail.com>
    148 	<1248713360-sup-5448@entry>
    149 	<1e5fdab70907271009v46639384w4bb3461ccaccf0cc@mail.gmail.com>
    150 	<1248716073-sup-7443@masanjin.net>
    151 	<1e5fdab70908010934l30373447r4a405c5ca0e406f9@mail.gmail.com>
    152 	<1e5fdab70908011044q6743d213o554a7bd039e237c2@mail.gmail.com>
    153 	<1249149855-sup-2211@pion.club.cc.cmu.edu>
    154 Message-ID: <1249151189-sup-3864@altis>
    155 
    156 Excerpts from Rich Lane's message of Sat Aug 01 20:14:34 +0200 2009:
    157 > I think we'd be safe not adding terms for email addresses longer than
    158 > 244 characters on the assumption that the user isn't going to want to
    159 > search for them.
    160 
    161 http://files.getdropbox.com/u/155904/grepped
    162 
    163 I did a simple grep, tell me if it's not enough (I'd rather not dive
    164 into the humongous mbox file).
    165 The mails come from the mailing-list admin tool (sympa), encoding
    166 problem it looks, the mangled part is "Propri?taires de liste" (list
    167 owners in french)
    168 
    169 -- 
    170 Guillaume
    171 
    172 From vasudeva@linkswarm.com  Sat Aug  1 17:58:13 2009
    173 From: vasudeva@linkswarm.com (vasudeva)
    174 Date: Sat, 01 Aug 2009 17:58:13 -0400
    175 Subject: [sup-talk] Smooth Paging
    176 In-Reply-To: <1249118728-sup-5483@thinkpad-debian>
    177 References: <1249053249-sup-9884@Longbow> <1249055039-sup-8105@masanjin.net>
    178 	<1249118728-sup-5483@thinkpad-debian>
    179 Message-ID: <1249163726-sup-5839@lenin>
    180 
    181 Excerpts from Christopher Bertels's message of Sat Aug 01 05:26:25 -0400 2009:
    182 > Excerpts from William Morgan's message of Fr Jul 31 17:44:25 +0200 2009:
    183 > > Have you tried J and K vs j and k to scroll?
    184 > 
    185 > Wow, cool. :) 
    186 > Good to know.
    187 
    188 That is nifty -- I didn't know it existed either. It seems slow on this machine though, and after using it in thread-view-mode, inbox-mode seems to have lost its mind a bit.
    189 
    190 I had wondered if the behavior the original poster was after might be akin to vim's 'scrolloff' setting. 
    191 
    192 Setting scrolloff=10 in vim means the selected line moves freely up and down but you're always going to have 10 lines of context at the edges; that is, the text starts scrolling upward when the selected line reaches 10 lines from the bottom. It kind of applies a 'force field' to the top and bottom edges of the page view so you never hit top or bottom of the viewport until you're at the top or bottom of the file itself.
    193 -- 
    194 linkswarm.com :: Collaborative Insolence
    195 vasudeva.linkswarm.com/gallery2 :: For The Faint of Heart
    196 
    197 
    198 From rlane@club.cc.cmu.edu  Sat Aug  1 18:56:09 2009
    199 From: rlane@club.cc.cmu.edu (Rich Lane)
    200 Date: Sat,  1 Aug 2009 15:56:09 -0700
    201 Subject: [sup-talk] [PATCH] xapian: drop excessively long terms
    202 Message-ID: <1249167369-16043-1-git-send-email-rlane@club.cc.cmu.edu>
    203 
    204 ---
    205  lib/sup/xapian_index.rb |    4 +++-
    206  1 files changed, 3 insertions(+), 1 deletions(-)
    207 
    208 diff --git a/lib/sup/xapian_index.rb b/lib/sup/xapian_index.rb
    209 index 6358a20..5a5dfc1 100644
    210 --- a/lib/sup/xapian_index.rb
    211 +++ b/lib/sup/xapian_index.rb
    212 @@ -304,6 +304,8 @@ class XapianIndex < BaseIndex
    213  
    214    DATE_VALUENO = 0
    215  
    216 +  MAX_TERM_LENGTH = 245
    217 +
    218    # Xapian can very efficiently sort in ascending docid order. Sup always wants
    219    # to sort by descending date, so this method maps between them. In order to
    220    # handle multiple messages per second, we use a logistic curve centered
    221 @@ -428,7 +430,7 @@ class XapianIndex < BaseIndex
    222  
    223      @term_generator.document = doc
    224      text.each { |text,prefix| @term_generator.index_text text, 1, prefix }
    225 -    terms.each { |term| doc.add_term term }
    226 +    terms.each { |term| doc.add_term term if term.length <= MAX_TERM_LENGTH }
    227      doc.add_value DATE_VALUENO, date_value
    228      doc.data = m.id
    229  
    230 -- 
    231 1.6.0.4
    232 
    233 
    234 From rlane@club.cc.cmu.edu  Sat Aug  1 19:03:06 2009
    235 From: rlane@club.cc.cmu.edu (Rich Lane)
    236 Date: Sat, 01 Aug 2009 19:03:06 -0400
    237 Subject: [sup-talk] Fwd: xapian merged into next
    238 In-Reply-To: <1249151189-sup-3864@altis>
    239 References: <1248711109-sup-7061@entry>
    240 	<1e5fdab70907270916o2f8e1768vbe7e3bcc1c807e39@mail.gmail.com>
    241 	<1248711777-sup-9329@entry>
    242 	<1e5fdab70907270931t7dfbe285h67197a7355b611d6@mail.gmail.com>
    243 	<1248712876-sup-1446@entry>
    244 	<1e5fdab70907270947n1866decdoc8a568cc9a2733ae@mail.gmail.com>
    245 	<1248713360-sup-5448@entry>
    246 	<1e5fdab70907271009v46639384w4bb3461ccaccf0cc@mail.gmail.com>
    247 	<1248716073-sup-7443@masanjin.net>
    248 	<1e5fdab70908010934l30373447r4a405c5ca0e406f9@mail.gmail.com>
    249 	<1e5fdab70908011044q6743d213o554a7bd039e237c2@mail.gmail.com>
    250 	<1249149855-sup-2211@pion.club.cc.cmu.edu>
    251 	<1249151189-sup-3864@altis>
    252 Message-ID: <1249167402-sup-6423@pion.club.cc.cmu.edu>
    253 
    254 Excerpts from Guillaume Quintard's message of Sat Aug 01 14:31:55 -0400 2009:
    255 > Excerpts from Rich Lane's message of Sat Aug 01 20:14:34 +0200 2009:
    256 > > I think we'd be safe not adding terms for email addresses longer than
    257 > > 244 characters on the assumption that the user isn't going to want to
    258 > > search for them.
    259 > 
    260 > http://files.getdropbox.com/u/155904/grepped
    261 > 
    262 > I did a simple grep, tell me if it's not enough (I'd rather not dive
    263 > into the humongous mbox file).
    264 > The mails come from the mailing-list admin tool (sympa), encoding
    265 > problem it looks, the mangled part is "Propri?taires de liste" (list
    266 > owners in french)
    267 > 
    268 
    269 I posted a patch that should keep Xapian from throwing an exception
    270 with long email addresses. I'm not any sort of encoding expert, but I'd
    271 guess that sup isn't responsible for the mangling.
    272 
    273 From guillaume.quintard@gmail.com  Sat Aug  1 19:35:25 2009
    274 From: guillaume.quintard@gmail.com (Guillaume Quintard)
    275 Date: Sun, 02 Aug 2009 01:35:25 +0200
    276 Subject: [sup-talk] Fwd: xapian merged into next
    277 In-Reply-To: <1249167402-sup-6423@pion.club.cc.cmu.edu>
    278 References: <1248711109-sup-7061@entry>
    279 	<1e5fdab70907270916o2f8e1768vbe7e3bcc1c807e39@mail.gmail.com>
    280 	<1248711777-sup-9329@entry>
    281 	<1e5fdab70907270931t7dfbe285h67197a7355b611d6@mail.gmail.com>
    282 	<1248712876-sup-1446@entry>
    283 	<1e5fdab70907270947n1866decdoc8a568cc9a2733ae@mail.gmail.com>
    284 	<1248713360-sup-5448@entry>
    285 	<1e5fdab70907271009v46639384w4bb3461ccaccf0cc@mail.gmail.com>
    286 	<1248716073-sup-7443@masanjin.net>
    287 	<1e5fdab70908010934l30373447r4a405c5ca0e406f9@mail.gmail.com>
    288 	<1e5fdab70908011044q6743d213o554a7bd039e237c2@mail.gmail.com>
    289 	<1249149855-sup-2211@pion.club.cc.cmu.edu>
    290 	<1249151189-sup-3864@altis>
    291 	<1249167402-sup-6423@pion.club.cc.cmu.edu>
    292 Message-ID: <1249169629-sup-5176@altis>
    293 
    294 Excerpts from Rich Lane's message of Sun Aug 02 01:03:06 +0200 2009:
    295 > with long email addresses. I'm not any sort of encoding expert, but I'd
    296 > guess that sup isn't responsible for the mangling.
    297 
    298 it isn't, the mangling comes from the mbox file, yet sup was able to
    299 import it at some point. I guesse the quotes don't really help.
    300 
    301 -- 
    302 Guillaume
    303 
    304 From mailinglist@flasht.de  Sat Aug  1 19:51:06 2009
    305 From: mailinglist@flasht.de (Christopher Bertels)
    306 Date: Sun, 02 Aug 2009 01:51:06 +0200
    307 Subject: [sup-talk] Smooth Paging
    308 In-Reply-To: <1249163726-sup-5839@lenin>
    309 References: <1249053249-sup-9884@Longbow> <1249055039-sup-8105@masanjin.net>
    310 	<1249118728-sup-5483@thinkpad-debian> <1249163726-sup-5839@lenin>
    311 Message-ID: <1249170613-sup-5276@thinkpad-debian>
    312 
    313 Excerpts from vasudeva's message of Sa Aug 01 23:58:13 +0200 2009:
    314 > I had wondered if the behavior the original poster was after might be akin to
    315 > vim's 'scrolloff' setting. 
    316 > 
    317 > Setting scrolloff=10 in vim means the selected line moves freely up and down
    318 > but you're always going to have 10 lines of context at the edges; that is, the
    319 > text starts scrolling upward when the selected line reaches 10 lines from the
    320 > bottom. It kind of applies a 'force field' to the top and bottom edges of the
    321 > page view so you never hit top or bottom of the viewport until you're at the
    322 > top or bottom of the file itself.
    323 
    324 I'd actually love to see something like this in sup as well.
    325 -- 
    326 ================================
    327 Christopher Bertels
    328 http://www.adztec-independent.de
    329 
    330 From benoit.pierre@gmail.com  Sun Aug  2 11:23:47 2009
    331 From: benoit.pierre@gmail.com (=?utf-8?q?Beno=C3=AEt_PIERRE?=)
    332 Date: Sun, 02 Aug 2009 17:23:47 +0200
    333 Subject: [sup-talk] [PATCH] run-mailcap fix
    334 Message-ID: <1249226521-sup-4719@localdomain>
    335 
    336 I use this line in my ~/.mailcap to view HTML attachements in Mutt:
    337 
    338 text/html; w3m -dump -T text/html %s | pager; needsterminal; description=HTML Text; nametemplate=%s.html
    339 
    340 which doesn't work with Sup. The attached patch fix this by not redirecting
    341 stderr to /dev/null.  It also restores the correct ncurses state (including
    342 arrow keypresses, thanks to Edward Z. Yang recent patch).
    343 -- 
    344 A: Because it destroys the flow of conversation.
    345 Q: Why is top posting dumb?
    346 -------------- next part --------------
    347 A non-text attachment was scrubbed...
    348 Name: sup-run-mailcap.patch
    349 Type: application/octet-stream
    350 Size: 704 bytes
    351 Desc: not available
    352 URL: <http://rubyforge.org/pipermail/sup-talk/attachments/20090802/1fa7b4f6/attachment.obj>
    353 -------------- next part --------------
    354 A non-text attachment was scrubbed...
    355 Name: signature.asc
    356 Type: application/pgp-signature
    357 Size: 197 bytes
    358 Desc: not available
    359 URL: <http://rubyforge.org/pipermail/sup-talk/attachments/20090802/1fa7b4f6/attachment.bin>
    360 
    361 From mark@markdrayton.info  Mon Aug  3 04:16:24 2009
    362 From: mark@markdrayton.info (Mark Drayton)
    363 Date: Mon, 3 Aug 2009 09:16:24 +0100
    364 Subject: [sup-talk] Stack overflow in regexp matcher
    365 Message-ID: <92457f310908030116k146a901aleee95a09db907d97@mail.gmail.com>
    366 
    367 Hi there
    368 
    369 I'm trying to run sup 0.8.1 on Mac OS 10.5.6, Ruby 1.8.6 but sup-sync
    370 is repeatedly dying:
    371 
    372 MC-S001930:~ draytm01$ sup-sync -c
    373 [..]
    374 [Mon Aug 03 08:45:18 +0100 2009] Connecting to IMAP server foo:143...
    375 [Mon Aug 03 08:45:18 +0100 2009] Logging in...
    376 [..]
    377 [Mon Aug 03 08:45:19 +0100 2009] fetching IMAP headers 1..1002
    378 [Mon Aug 03 08:45:20 +0100 2009] done fetching IMAP headers
    379 Scanning imap://foo/INBOX...
    380 [..]
    381 ## read 440m (about 52%) @ 2.2m/s. 0:03:19 elapsed, about 0:03:03 remaining
    382 [Mon Aug 03 08:48:49 +0100 2009] unlocking /Users/draytm01/.sup/lock...
    383 /Library/Ruby/Gems/1.8/gems/sup-0.8.1/lib/sup/util.rb:204:in `split':
    384 Stack overflow in regexp matcher:
    385 /,\s*(?=(?:[^"]*"[^"]*")*(?![^"]*"))/ (RegexpError)
    386 	from /Library/Ruby/Gems/1.8/gems/sup-0.8.1/lib/sup/util.rb:204:in
    387 `split_on_commas'
    388 	from /Library/Ruby/Gems/1.8/gems/sup-0.8.1/lib/sup/person.rb:110:in
    389 `from_address_list'
    390 	from /Library/Ruby/Gems/1.8/gems/sup-0.8.1/lib/sup/message.rb:104:in
    391 `parse_header'
    392 	from /Library/Ruby/Gems/1.8/gems/sup-0.8.1/lib/sup/message.rb:208:in
    393 `load_from_source!'
    394 	from /Library/Ruby/Gems/1.8/gems/sup-0.8.1/lib/sup/poll.rb:151:in
    395 `add_messages_from'
    396 	from /Library/Ruby/Gems/1.8/gems/sup-0.8.1/lib/sup/imap.rb:187:in `each'
    397 	from /Library/Ruby/Gems/1.8/gems/sup-0.8.1/lib/sup/imap.rb:175:in `upto'
    398 	from /Library/Ruby/Gems/1.8/gems/sup-0.8.1/lib/sup/imap.rb:175:in `each'
    399 	 ... 7 levels...
    400 	from /Library/Ruby/Gems/1.8/gems/sup-0.8.1/bin/sup-sync:135:in `each'
    401 	from /Library/Ruby/Gems/1.8/gems/sup-0.8.1/bin/sup-sync:135
    402 	from /usr/bin/sup-sync:19:in `load'
    403 	from /usr/bin/sup-sync:19
    404 
    405 This error seems to have cropped up in other software so I suspect
    406 it's a problem with Ruby, not sup. Anyone able to confirm this?
    407 
    408 Cheers,
    409 
    410 Mark
    411 
    412 From wmorgan-sup@masanjin.net  Mon Aug  3 13:18:50 2009
    413 From: wmorgan-sup@masanjin.net (William Morgan)
    414 Date: Mon, 03 Aug 2009 10:18:50 -0700
    415 Subject: [sup-talk] Odd bug with lazy-loaded messages
    416 In-Reply-To: <1248716007-sup-5156@javelin>
    417 References: <1248716007-sup-5156@javelin>
    418 Message-ID: <1249319474-sup-8322@masanjin.net>
    419 
    420 Sorry I didn't respond to this earlier.
    421 
    422 Reformatted excerpts from Edward Z. Yang's message of 2009-07-27:
    423 > Specifically, the "default" opened message when I open a thread
    424 > gets a weird misrendering of the headers that looks like:
    425 > 
    426 > To: foo
    427 >     foo <foo at example.com>
    428 >     foo
    429 > 
    430 > And so forth, for all lines in To and Cc.
    431 
    432 This is because we store a couple variants of the address in the index
    433 (e.g. the email address to the left of the @), so that a search on any
    434 of them will bring up the message. Without #load_from_source!, the
    435 message is loaded from the index, so it reflects those fields. So it's
    436 basically a hack at this point. You could further hack it by undoing
    437 that transformation. Or we could add the original version of the fields
    438 to the index in a separate, non-searchable field, incurring the
    439 associated storage penalties.
    440 -- 
    441 William <wmorgan-sup at masanjin.net>
    442 
    443 From wmorgan-sup@masanjin.net  Mon Aug  3 13:31:34 2009
    444 From: wmorgan-sup@masanjin.net (William Morgan)
    445 Date: Mon, 03 Aug 2009 10:31:34 -0700
    446 Subject: [sup-talk] Handling big mailing lists
    447 In-Reply-To: <m3prbjwgf8.fsf@iny.iki.fi>
    448 References: <m3zlaovx3t.fsf@iny.iki.fi> <1248874122-sup-3830@masanjin.net>
    449 	<m3prbjwgf8.fsf@iny.iki.fi>
    450 Message-ID: <1249320458-sup-6019@masanjin.net>
    451 
    452 Reformatted excerpts from iny+dev's message of 2009-07-29:
    453 > I guess so. How long it takes to index few months of ruby-talk?
    454 
    455 Offhand I see index speeds of 50-80 messages/s depending on index size,
    456 backend, etc.
    457 
    458 > Could Sup use IMAP search features?
    459 
    460 No, that would require a very different architecture and philosophy.
    461 -- 
    462 William <wmorgan-sup at masanjin.net>
    463 
    464 From wmorgan-sup@masanjin.net  Mon Aug  3 14:03:54 2009
    465 From: wmorgan-sup@masanjin.net (William Morgan)
    466 Date: Mon, 03 Aug 2009 11:03:54 -0700
    467 Subject: [sup-talk] xapian question
    468 In-Reply-To: <1249098509-sup-6664@pion.club.cc.cmu.edu>
    469 References: <1248716325-sup-7534@masanjin.net>
    470 	<1248795865-sup-6634@pion.club.cc.cmu.edu>
    471 	<1248807365-sup-4965@masanjin.net>
    472 	<1249098509-sup-6664@pion.club.cc.cmu.edu>
    473 Message-ID: <1249320789-sup-2608@masanjin.net>
    474 
    475 Reformatted excerpts from Rich Lane's message of 2009-07-31:
    476 > I tried out using add_term/remove_term for immediate label changes.
    477 > It's significantly faster than sync_message,
    478 
    479 Excellent.
    480 
    481 > but it still makes the interface feel laggy.  There's known room for
    482 > improvement in Xapian's replace_document.  However, we'll still have a
    483 > lot of latency when we start using remote sup-servers, so I don't
    484 > think it's a good idea to do these index operations synchronously with
    485 > the UI.
    486 
    487 I agree, synchronous is not an option.
    488 
    489 > We could queue up index writes and execute them in a background
    490 > thread. We'd want label additions to show up immediately in a search,
    491 > though. This is easy to do for inbox-mode and label-view-mode, which
    492 > covers most of my daily usage.
    493 
    494 I'm fine with queuing up index writes and letting the user continue
    495 while they take effect in the background. I'm also fine with the easier
    496 option of just blocking during a search until the writes are complete.
    497 
    498 > If/when we support multiple clients connecting to a sup-server, we'll
    499 > need a way to notify them that someone else modified a message.
    500 
    501 I think this is more of a nice-to-have than a necessity, but it would be
    502 nice to have, even if it was a "we've detected a change somewhere on the
    503 internet; reload? (y/n)"-kinda thing.
    504 
    505 > How is sup-server development going?
    506 
    507 Well. I have a simple version that stores "items" to files on disk, and
    508 uses Ferret to provide the search semantics. It's modular enough that
    509 upgrading to Xapian shouldn't be as painful as it was with Sup. There
    510 are even unit tests that enforce the semantics of the modules. Go me.
    511 
    512 I'm going to make a couple internal API changes in Sup and then try
    513 throwing the code together.
    514 -- 
    515 William <wmorgan-sup at masanjin.net>
    516 
    517 From tom@dbservice.com  Tue Aug  4 05:56:11 2009
    518 From: tom@dbservice.com (Tomas Carnecky)
    519 Date: Tue, 4 Aug 2009 11:56:11 +0200
    520 Subject: [sup-talk] sup on opensolaris
    521 In-Reply-To: <1249059559-sup-8960@matrix>
    522 References: <1249059559-sup-8960@matrix>
    523 Message-ID: <F8547FC4-8D0A-40AB-9604-7CB49BED27EC@dbservice.com>
    524 
    525 I hate mailing lists that force me to subscribe. Luckily I have a  
    526 friend who was already subscribed and forwarded me the emails.
    527 
    528 >
    529 >> I have an ugly patch for lib/sup/textfield.rb that uses its own  
    530 >> string
    531 >> buffer instead of relying on field_buffer(). It's not perfect, but it
    532 >> at least allows me to write emails and assign tags.
    533 >
    534 > If it's not too much work to clean up, I'd be interested in this  
    535 > patch.
    536 > The field buffer stuff is broken in weird ways anyways (the history
    537 > never seems to be quite right), and anything that reduces the reliance
    538 > on ncurses is always the right approach.
    539 
    540 I never programed in ruby before and I don't intend to learn it. Feel  
    541 free to look at the last commit in the solaris-fixes:curses-form- 
    542 buffer branch. It is the simplest possible solution to the problem at  
    543 hand that didn't require me to learn too much ruby. It still needs a  
    544 considerable amount of work before it is useful (like, being able to  
    545 delete characters in the stringio buffer etc). I'm not planing to work  
    546 on the patch in the foreseeable future, but someone else might find  
    547 the patch useful as a starting point.
    548 
    549 >
    550 >>  - strftime("%P") is a GNU extension, I work around this by using
    551 >> strftime("%p").downcase.
    552 >
    553 > Submit a patch! I'm fine with this.
    554 >
    555 >>  - Iconv.iconv(target + "//IGNORE", charset, text + " ") <- the "//
    556 >> IGNORE" is causing an InvalidEncoding exception, removing it didn't
    557 >> seem to cause any regressions
    558 >
    559 > Hm, this is a trickier one. Allegedly the //IGNORE reduces the
    560 > exceptions thrown by Iconv, but since we're catching them all anyways,
    561 > we might be able to get away with removing this. Or we could
    562 > special-case it to your arch.
    563 
    564 
    565 Both patches are available in the solaris-fixes master branch.
    566 
    567 tom
    568 
    569 
    570 From wmorgan-sup@masanjin.net  Wed Aug  5 09:55:47 2009
    571 From: wmorgan-sup@masanjin.net (William Morgan)
    572 Date: Wed, 05 Aug 2009 06:55:47 -0700
    573 Subject: [sup-talk] [PATCH] xapian: drop excessively long terms
    574 In-Reply-To: <1249167369-16043-1-git-send-email-rlane@club.cc.cmu.edu>
    575 References: <1249167369-16043-1-git-send-email-rlane@club.cc.cmu.edu>
    576 Message-ID: <1249480531-sup-9805@masanjin.net>
    577 
    578 Applied, thanks!
    579 
    580 BTW I've merged the xapian stuff into master.
    581 -- 
    582 William <wmorgan-sup at masanjin.net>
    583 
    584 From dato@net.com.org.es  Wed Aug  5 10:09:26 2009
    585 From: dato@net.com.org.es (=?utf-8?q?Adeodato_Sim=C3=B3?=)
    586 Date: Wed, 05 Aug 2009 16:09:26 +0200
    587 Subject: [sup-talk] sup ignoring SIGTERM?
    588 Message-ID: <1249481294-sup-9967@chistera.yi.org>
    589 
    590 Hello,
    591 
    592 it is my impression that sup is ignoring SIGTERM, whereas I would be
    593 expecting for sup to clean up (including removal of the lock file) and
    594 exit normally upon receiving this signal.
    595 
    596 Any clues about this? (I tried inserting a "trap", but it didn't seem to
    597 help.)
    598 
    599 Thanks,
    600 
    601 -- 
    602 - Are you sure we're good?
    603 - Always.
    604         -- Rory and Lorelai
    605 
    606 
    607 From ezyang@MIT.EDU  Wed Aug  5 10:54:31 2009
    608 From: ezyang@MIT.EDU (Edward Z. Yang)
    609 Date: Wed, 05 Aug 2009 10:54:31 -0400
    610 Subject: [sup-talk] [PATCH] xapian: drop excessively long terms
    611 In-Reply-To: <1249480531-sup-9805@masanjin.net>
    612 References: <1249167369-16043-1-git-send-email-rlane@club.cc.cmu.edu>
    613 	<1249480531-sup-9805@masanjin.net>
    614 Message-ID: <1249484040-sup-1879@javelin>
    615 
    616 Excerpts from William Morgan's message of Wed Aug 05 09:55:47 -0400 2009:
    617 > BTW I've merged the xapian stuff into master.
    618 
    619 Exciting days we live in. :-) Maybe I'll wait another week and update my local
    620 checkout.
    621 
    622 Cheers,
    623 Edward
    624 
    625 From wmorgan-sup@masanjin.net  Wed Aug  5 11:29:27 2009
    626 From: wmorgan-sup@masanjin.net (William Morgan)
    627 Date: Wed, 05 Aug 2009 08:29:27 -0700
    628 Subject: [sup-talk] sup crashing after sending mail
    629 In-Reply-To: <CBBB81512D1FE445823400465FCCFFF2D8AA45@sluga.fer.hr>
    630 References: <CBBB81512D1FE445823400465FCCFFF2D8AA45@sluga.fer.hr>
    631 Message-ID: <1249486021-sup-1246@masanjin.net>
    632 
    633 Hi Igor,
    634 
    635 Reformatted excerpts from Igor Brkic's message of 2009-08-02:
    636 > For mail sending I use sSMTP and my ISP's SMTP server. When I try to
    637 > send mail from sup, after pressing y on keyboard, mail gets sent but
    638 > sup crashes (exception-log_0.txt in attachment).
    639 
    640 A few people have reported this and I'm trying to track it down. Would
    641 you mind applying the following patch, and then running:
    642   sup-sync -a sup://sent
    643 
    644 Hopefully that will generate a little debugging output I can use. Thanks!
    645 
    646 diff --git a/lib/sup/message.rb b/lib/sup/message.rb
    647 index 5372fc7..fc9af59 100644
    648 --- a/lib/sup/message.rb
    649 +++ b/lib/sup/message.rb
    650 @@ -92,11 +92,11 @@ class Message
    651        begin
    652          Time.parse date
    653        rescue ArgumentError => e
    654 -        #Redwood::log "faking mangled date header for #{@id} (orig #{header['date']
    655 +        Redwood::log "faking mangled date header for #{@id} (orig #{header['date'].
    656          Time.now
    657        end
    658      else
    659 -      #Redwood::log "faking non-existent date header for #{@id}"
    660 +      Redwood::log "faking non-existent date header for #{@id}"
    661        Time.now
    662      end
    663  
    664 diff --git a/lib/sup/poll.rb b/lib/sup/poll.rb
    665 index 354bd21..365f828 100644
    666 --- a/lib/sup/poll.rb
    667 +++ b/lib/sup/poll.rb
    668 @@ -148,7 +148,9 @@ EOS
    669          labels = labels + (source.archived? ? [] : [:inbox])
    670  
    671          m = Message.new :source => source, :source_info => offset, :labels => label
    672 +        Redwood::log "XX before load: #{m.date.inspect}"
    673          m.load_from_source!
    674 +        Redwood::log "XX after load: #{m.date.inspect}"
    675  
    676          if m.source_marked_read?
    677            m.remove_label :unread
    678 @@ -157,7 +159,9 @@ EOS
    679  
    680          docid, entry = Index.load_entry_for_id m.id
    681          HookManager.run "before-add-message", :message => m
    682 +        Redwood::log "XX after add-message: #{m.date.inspect}"
    683          m = yield(m, offset, entry) or next if block_given?
    684 +        Redwood::log "XX after yield: #{m.date.inspect}"
    685          times = Index.sync_message m, false, docid, entry, opts
    686          UpdateManager.relay self, :added, m unless entry
    687        end
    688 
    689 
    690 -- 
    691 William <wmorgan-sup at masanjin.net>
    692 
    693 From rlane@club.cc.cmu.edu  Wed Aug  5 11:36:19 2009
    694 From: rlane@club.cc.cmu.edu (Rich Lane)
    695 Date: Wed, 05 Aug 2009 11:36:19 -0400
    696 Subject: [sup-talk] [PATCH] xapian: drop excessively long terms
    697 In-Reply-To: <1249480531-sup-9805@masanjin.net>
    698 References: <1249167369-16043-1-git-send-email-rlane@club.cc.cmu.edu>
    699 	<1249480531-sup-9805@masanjin.net>
    700 Message-ID: <1249485678-sup-4545@pion.club.cc.cmu.edu>
    701 
    702 Excerpts from William Morgan's message of Wed Aug 05 09:55:47 -0400 2009:
    703 > BTW I've merged the xapian stuff into master.
    704 
    705 Let's not advertise this as stable just yet - I've got a patchset that
    706 removes the GDBM databases which will break compatibility. Using just
    707 Xapian means better consistency if your kernel panics and potentially
    708 better performance. However, I have some Xapian bugs to squash before
    709 it's usable.
    710 
    711 From wmorgan-sup@masanjin.net  Wed Aug  5 11:48:35 2009
    712 From: wmorgan-sup@masanjin.net (William Morgan)
    713 Date: Wed, 05 Aug 2009 08:48:35 -0700
    714 Subject: [sup-talk] [PATCH] xapian: drop excessively long terms
    715 In-Reply-To: <1249485678-sup-4545@pion.club.cc.cmu.edu>
    716 References: <1249167369-16043-1-git-send-email-rlane@club.cc.cmu.edu>
    717 	<1249480531-sup-9805@masanjin.net>
    718 	<1249485678-sup-4545@pion.club.cc.cmu.edu>
    719 Message-ID: <1249487110-sup-1824@masanjin.net>
    720 
    721 Reformatted excerpts from Rich Lane's message of 2009-08-05:
    722 > Let's not advertise this as stable just yet - I've got a patchset that
    723 > removes the GDBM databases which will break compatibility.
    724 
    725 Since the xapian stuff is only enabled via an obscure environment
    726 variable, I'm not too concerned about it being uber-stable. I've merged
    727 this more for the internal API changes, which seem stable and which I'm
    728 now building off of.
    729 -- 
    730 William <wmorgan-sup at masanjin.net>
    731 
    732 From nicolas.pouillard@gmail.com  Wed Aug  5 13:29:48 2009
    733 From: nicolas.pouillard@gmail.com (Nicolas Pouillard)
    734 Date: Wed, 05 Aug 2009 19:29:48 +0200
    735 Subject: [sup-talk] [PATCH] xapian: drop excessively long terms
    736 In-Reply-To: <1249485678-sup-4545@pion.club.cc.cmu.edu>
    737 References: <1249167369-16043-1-git-send-email-rlane@club.cc.cmu.edu>
    738 	<1249480531-sup-9805@masanjin.net>
    739 	<1249485678-sup-4545@pion.club.cc.cmu.edu>
    740 Message-ID: <1249493306-sup-4994@ausone.home>
    741 
    742 Excerpts from Rich Lane's message of Wed Aug 05 17:36:19 +0200 2009:
    743 > Excerpts from William Morgan's message of Wed Aug 05 09:55:47 -0400 2009:
    744 > > BTW I've merged the xapian stuff into master.
    745 > 
    746 > Let's not advertise this as stable just yet -
    747 
    748 > I've got a patchset that
    749 > removes the GDBM databases which will break compatibility.
    750 
    751 I was planning to try a migration today, should I better wait a little?
    752 
    753 -- 
    754 Nicolas Pouillard
    755 http://nicolaspouillard.fr
    756 
    757 From rlane@club.cc.cmu.edu  Wed Aug  5 13:48:11 2009
    758 From: rlane@club.cc.cmu.edu (Rich Lane)
    759 Date: Wed, 05 Aug 2009 13:48:11 -0400
    760 Subject: [sup-talk] [PATCH] xapian: drop excessively long terms
    761 In-Reply-To: <1249493306-sup-4994@ausone.home>
    762 References: <1249167369-16043-1-git-send-email-rlane@club.cc.cmu.edu>
    763 	<1249480531-sup-9805@masanjin.net>
    764 	<1249485678-sup-4545@pion.club.cc.cmu.edu>
    765 	<1249493306-sup-4994@ausone.home>
    766 Message-ID: <1249493896-sup-7335@pion.club.cc.cmu.edu>
    767 
    768 Excerpts from Nicolas Pouillard's message of Wed Aug 05 13:29:48 -0400 2009:
    769 > I was planning to try a migration today, should I better wait a little?
    770 
    771 I'd say go for it, just be aware you'll need to reindex soon. For the
    772 full experience compile svn xapian and export XAPIAN_PREFER_CHERT=1.
    773 
    774 From nicolas.pouillard@gmail.com  Wed Aug  5 13:58:43 2009
    775 From: nicolas.pouillard@gmail.com (Nicolas Pouillard)
    776 Date: Wed, 05 Aug 2009 19:58:43 +0200
    777 Subject: [sup-talk] [PATCH] xapian: drop excessively long terms
    778 In-Reply-To: <1249493896-sup-7335@pion.club.cc.cmu.edu>
    779 References: <1249167369-16043-1-git-send-email-rlane@club.cc.cmu.edu>
    780 	<1249480531-sup-9805@masanjin.net>
    781 	<1249485678-sup-4545@pion.club.cc.cmu.edu>
    782 	<1249493306-sup-4994@ausone.home>
    783 	<1249493896-sup-7335@pion.club.cc.cmu.edu>
    784 Message-ID: <1249495000-sup-6057@ausone.home>
    785 
    786 Excerpts from Rich Lane's message of Wed Aug 05 19:48:11 +0200 2009:
    787 > Excerpts from Nicolas Pouillard's message of Wed Aug 05 13:29:48 -0400 2009:
    788 > > I was planning to try a migration today, should I better wait a little?
    789 > 
    790 > I'd say go for it, just be aware you'll need to reindex soon. For the
    791 > full experience compile svn xapian and export XAPIAN_PREFER_CHERT=1.
    792 
    793 When you say the svn version you mean the trunk or the 1.0-branch ?
    794 
    795 -- 
    796 Nicolas Pouillard
    797 http://nicolaspouillard.fr
    798 
    799 From rlane@club.cc.cmu.edu  Wed Aug  5 14:06:39 2009
    800 From: rlane@club.cc.cmu.edu (Rich Lane)
    801 Date: Wed, 05 Aug 2009 14:06:39 -0400
    802 Subject: [sup-talk] [PATCH] xapian: drop excessively long terms
    803 In-Reply-To: <1249495000-sup-6057@ausone.home>
    804 References: <1249167369-16043-1-git-send-email-rlane@club.cc.cmu.edu>
    805 	<1249480531-sup-9805@masanjin.net>
    806 	<1249485678-sup-4545@pion.club.cc.cmu.edu>
    807 	<1249493306-sup-4994@ausone.home>
    808 	<1249493896-sup-7335@pion.club.cc.cmu.edu>
    809 	<1249495000-sup-6057@ausone.home>
    810 Message-ID: <1249495530-sup-6312@pion.club.cc.cmu.edu>
    811 
    812 Excerpts from Nicolas Pouillard's message of Wed Aug 05 13:58:43 -0400 2009:
    813 > Excerpts from Rich Lane's message of Wed Aug 05 19:48:11 +0200 2009:
    814 > > Excerpts from Nicolas Pouillard's message of Wed Aug 05 13:29:48 -0400 2009:
    815 > > > I was planning to try a migration today, should I better wait a little?
    816 > > 
    817 > > I'd say go for it, just be aware you'll need to reindex soon. For the
    818 > > full experience compile svn xapian and export XAPIAN_PREFER_CHERT=1.
    819 > 
    820 > When you say the svn version you mean the trunk or the 1.0-branch ?
    821 
    822 Trunk.
    823 
    824 From wmorgan-sup@masanjin.net  Wed Aug  5 16:03:09 2009
    825 From: wmorgan-sup@masanjin.net (William Morgan)
    826 Date: Wed, 05 Aug 2009 13:03:09 -0700
    827 Subject: [sup-talk] sup ignoring SIGTERM?
    828 In-Reply-To: <1249481294-sup-9967@chistera.yi.org>
    829 References: <1249481294-sup-9967@chistera.yi.org>
    830 Message-ID: <1249502171-sup-8079@masanjin.net>
    831 
    832 Reformatted excerpts from Adeodato Sim?'s message of 2009-08-05:
    833 > it is my impression that sup is ignoring SIGTERM, whereas I would be
    834 > expecting for sup to clean up (including removal of the lock file) and
    835 > exit normally upon receiving this signal.
    836 
    837 Good point. I've fixed that in branch ncurses-fixes, which I've merged
    838 into next. Let me know if it works for you.
    839 
    840 I'm also happy to report that I've finally managed to get Sup to deal
    841 with screen resizes, which, oddly enough, was a related problem. Go me!
    842 Steps closer to curses-induced insanity: 4!
    843 
    844 Available on next or ncurses-fixes branches.
    845 -- 
    846 William <wmorgan-sup at masanjin.net>
    847 
    848 From nicolas.pouillard@gmail.com  Wed Aug  5 16:25:49 2009
    849 From: nicolas.pouillard@gmail.com (Nicolas Pouillard)
    850 Date: Wed, 05 Aug 2009 22:25:49 +0200
    851 Subject: [sup-talk] sup ignoring SIGTERM?
    852 In-Reply-To: <1249502171-sup-8079@masanjin.net>
    853 References: <1249481294-sup-9967@chistera.yi.org>
    854 	<1249502171-sup-8079@masanjin.net>
    855 Message-ID: <1249503870-sup-1415@ausone.home>
    856 
    857 Excerpts from William Morgan's message of Wed Aug 05 22:03:09 +0200 2009:
    858 > Reformatted excerpts from Adeodato Sim?'s message of 2009-08-05:
    859 > > it is my impression that sup is ignoring SIGTERM, whereas I would be
    860 > > expecting for sup to clean up (including removal of the lock file) and
    861 > > exit normally upon receiving this signal.
    862 > 
    863 > Good point. I've fixed that in branch ncurses-fixes, which I've merged
    864 > into next. Let me know if it works for you.
    865 > 
    866 > I'm also happy to report that I've finally managed to get Sup to deal
    867 > with screen resizes, which, oddly enough, was a related problem. Go me!
    868 > Steps closer to curses-induced insanity: 4!
    869 > 
    870 > Available on next or ncurses-fixes branches.
    871 
    872 With the ncurses-fixes branch (even with the last patch), when I launch sup
    873 I get a blank screen (with the status bar saying "Searching for threads...".
    874 
    875 -- 
    876 Nicolas Pouillard
    877 http://nicolaspouillard.fr
    878 
    879 From bwalton@artsci.utoronto.ca  Wed Aug  5 16:35:51 2009
    880 From: bwalton@artsci.utoronto.ca (Ben Walton)
    881 Date: Wed, 05 Aug 2009 16:35:51 -0400
    882 Subject: [sup-talk] sup ignoring SIGTERM?
    883 In-Reply-To: <1249502171-sup-8079@masanjin.net>
    884 References: <1249481294-sup-9967@chistera.yi.org>
    885 	<1249502171-sup-8079@masanjin.net>
    886 Message-ID: <1249504381-sup-8445@ntdws12.chass.utoronto.ca>
    887 
    888 Excerpts from William Morgan's message of Wed Aug 05 16:03:09 -0400 2009:
    889 
    890 > Good point. I've fixed that in branch ncurses-fixes, which I've merged
    891 > into next. Let me know if it works for you.
    892 
    893 I just pulled next and fired it up.  It was _hoooooribly_,
    894 _bruuuutallly_ slow to load the index.  I git bisected between my
    895 previous running ORIG_HEAD and HEAD.  I came up with 75d9f5e3db as the
    896 offender.  It seems to do what you intend but (for me, anyway) at the
    897 expense of really bad interactivity.  [We're talking 10+ minutes to
    898 load the index part way...]
    899 
    900 This doesn't help identify the problem, but I'd be looking at the
    901 Ncurses.nodelay bits...
    902 
    903 Thanks
    904 -Ben
    905 -- 
    906 Ben Walton
    907 Systems Programmer - CHASS
    908 University of Toronto
    909 C:416.407.5610 | W:416.978.4302
    910 
    911 GPG Key Id: 8E89F6D2; Key Server: pgp.mit.edu
    912 Contact me to arrange for a CAcert assurance meeting.
    913 -------------- next part --------------
    914 A non-text attachment was scrubbed...
    915 Name: signature.asc
    916 Type: application/pgp-signature
    917 Size: 189 bytes
    918 Desc: not available
    919 URL: <http://rubyforge.org/pipermail/sup-talk/attachments/20090805/b4062212/attachment.bin>
    920 
    921 From wmorgan-sup@masanjin.net  Wed Aug  5 17:24:49 2009
    922 From: wmorgan-sup@masanjin.net (William Morgan)
    923 Date: Wed, 05 Aug 2009 14:24:49 -0700
    924 Subject: [sup-talk] sup ignoring SIGTERM?
    925 In-Reply-To: <1249503870-sup-1415@ausone.home>
    926 References: <1249481294-sup-9967@chistera.yi.org>
    927 	<1249502171-sup-8079@masanjin.net>
    928 	<1249503870-sup-1415@ausone.home>
    929 Message-ID: <1249507336-sup-7887@masanjin.net>
    930 
    931 Reformatted excerpts from Nicolas Pouillard's message of 2009-08-05:
    932 > With the ncurses-fixes branch (even with the last patch), when I
    933 > launch sup I get a blank screen (with the status bar saying "Searching
    934 > for threads...".
    935 
    936 Dammit. I see that too, on some computers. The problem is that
    937 Ncurses.getch is actually blocking the background threads from working.
    938 (You can tell because threads will start loading when you press lots of
    939 keys.)
    940 
    941 I've unmerged the branch from next for the time being.
    942 
    943 The problem is the removal of the select() in nonblocking_getch
    944 (buffer.rb circa line 25). With it in, resizes don't work right. With it
    945 removed, background threads are blocked on some computers. Not sure what
    946 makes the difference. Sigh...
    947 -- 
    948 William <wmorgan-sup at masanjin.net>
    949 
    950 From ezyang@MIT.EDU  Wed Aug  5 17:28:43 2009
    951 From: ezyang@MIT.EDU (Edward Z. Yang)
    952 Date: Wed, 05 Aug 2009 17:28:43 -0400
    953 Subject: [sup-talk] sup ignoring SIGTERM?
    954 In-Reply-To: <1249502171-sup-8079@masanjin.net>
    955 References: <1249481294-sup-9967@chistera.yi.org>
    956 	<1249502171-sup-8079@masanjin.net>
    957 Message-ID: <1249507702-sup-8439@javelin>
    958 
    959 Excerpts from William Morgan's message of Wed Aug 05 16:03:09 -0400 2009:
    960 > I'm also happy to report that I've finally managed to get Sup to deal
    961 > with screen resizes, which, oddly enough, was a related problem. Go me!
    962 > Steps closer to curses-induced insanity: 4!
    963 
    964 Sounds exciting. What was the fix?
    965 
    966 Cheers,
    967 Edward
    968 
    969 From igor.brkic@fer.hr  Wed Aug  5 19:24:38 2009
    970 From: igor.brkic@fer.hr (Igor Brkic)
    971 Date: Thu, 06 Aug 2009 01:24:38 +0200
    972 Subject: [sup-talk] sup crashing after sending mail
    973 In-Reply-To: <1249486021-sup-1246@masanjin.net>
    974 References: <CBBB81512D1FE445823400465FCCFFF2D8AA45@sluga.fer.hr>
    975 	<1249486021-sup-1246@masanjin.net>
    976 Message-ID: <1249514106-sup-9112@xps>
    977 
    978 Excerpts from William Morgan's message of Sri Kol 05 17:29:27 +0200 2009:
    979 > A few people have reported this and I'm trying to track it down. Would
    980 > you mind applying the following patch, and then running:
    981 >   sup-sync -a sup://sent
    982 > 
    983 > Hopefully that will generate a little debugging output I can use. Thanks!
    984 
    985 I (partially) solved/hacked the problem. The problem was (I think) in wrong
    986 set locale and Sup not being able to recognize and compare sending date
    987 (which had croatian tags for month and day of the week) and Time.now (which
    988 was whole in english/universal format).
    989 
    990 I solved the problem by commenting out the "Time.parse time, 0" (line 15 in
    991 file lib/sup/mbox.rb).
    992 
    993 It's not perfect solution (if that line should be commented out, it would
    994 be :D), but for me it works for now (I'm writing this mail from it).
    995 
    996 Cheers!
    997 Igor Brkic
    998 
    999 From wmorgan-sup@masanjin.net  Thu Aug  6 10:40:08 2009
   1000 From: wmorgan-sup@masanjin.net (William Morgan)
   1001 Date: Thu, 06 Aug 2009 07:40:08 -0700
   1002 Subject: [sup-talk] sup crashing after sending mail
   1003 In-Reply-To: <1249514106-sup-9112@xps>
   1004 References: <CBBB81512D1FE445823400465FCCFFF2D8AA45@sluga.fer.hr>
   1005 	<1249486021-sup-1246@masanjin.net> <1249514106-sup-9112@xps>
   1006 Message-ID: <1249568949-sup-3922@masanjin.net>
   1007 
   1008 Reformatted excerpts from Igor Brkic's message of 2009-08-05:
   1009 > I solved the problem by commenting out the "Time.parse time, 0" (line
   1010 > 15 in file lib/sup/mbox.rb).
   1011 
   1012 I'm glad that works, but I have a hard time understanding why.
   1013 
   1014 That line is for parsing the mbox "From " separator line (which has a
   1015 date on it). It has nothing to do with the date field in the message,
   1016 which is what isn't being set (and thus raising the exception).
   1017 
   1018 If the date parsing on that line is screwed up, then I would except to
   1019 see an out-of-sync error raised by Sup, since it would be expecting an
   1020 mbox "From " separator line and wouldn't detect the line as such.
   1021 
   1022 If you feel like it, send me a small mbox file (possible your
   1023 ~/.sup/sent.mbox after being censored) and I can take a look.
   1024 -- 
   1025 William <wmorgan-sup at masanjin.net>
   1026 
   1027 From igor.brkic@fer.hr  Thu Aug  6 12:57:03 2009
   1028 From: igor.brkic@fer.hr (Igor Brkic)
   1029 Date: Thu, 06 Aug 2009 18:57:03 +0200
   1030 Subject: [sup-talk] sup crashing after sending mail
   1031 In-Reply-To: <1249568949-sup-3922@masanjin.net>
   1032 References: <CBBB81512D1FE445823400465FCCFFF2D8AA45@sluga.fer.hr>
   1033 	<1249486021-sup-1246@masanjin.net> <1249514106-sup-9112@xps>
   1034 	<1249568949-sup-3922@masanjin.net>
   1035 Message-ID: <1249576777-sup-3885@xps>
   1036 
   1037 Excerpts from William Morgan's message of ?et Kol 06 16:40:08 +0200 2009:
   1038 > 
   1039 > If you feel like it, send me a small mbox file (possible your
   1040 > ~/.sup/sent.mbox after being censored) and I can take a look.
   1041 
   1042 This is weird... For the last hour and a half I've been trying to
   1043 reproduce the error I was having - I uncommented the line in mbox.rb,
   1044 returned locale settings to previous state - but everything is working 
   1045 flawless. Whatever I make, it won't crash. I'll keep trying, though :)
   1046 
   1047 I'm afraid I can't send you the mbox file that is causing sup to crash
   1048 because I deleted all logs and sent.mbox files the moment all started
   1049 to work.
   1050 
   1051 
   1052 From wmorgan-sup@masanjin.net  Thu Aug  6 13:45:50 2009
   1053 From: wmorgan-sup@masanjin.net (William Morgan)
   1054 Date: Thu, 06 Aug 2009 10:45:50 -0700
   1055 Subject: [sup-talk] sup crashing after sending mail
   1056 In-Reply-To: <1249579173-sup-573@xps>
   1057 References: <CBBB81512D1FE445823400465FCCFFF2D8AA45@sluga.fer.hr>
   1058 	<1249486021-sup-1246@masanjin.net> <1249514106-sup-9112@xps>
   1059 	<1249568949-sup-3922@masanjin.net> <1249576777-sup-3885@xps>
   1060 	<1249579173-sup-573@xps>
   1061 Message-ID: <1249580716-sup-6413@masanjin.net>
   1062 
   1063 Reformatted excerpts from Igor Brkic's message of 2009-08-06:
   1064 > I attached output of "sup-sync -a sup://sent" with patch you sent me
   1065 > applyed (sync-log.txt).
   1066 
   1067 Awesome. This looks very juicy. Thanks!
   1068 -- 
   1069 William <wmorgan-sup at masanjin.net>
   1070 
   1071 From wmorgan-sup@masanjin.net  Thu Aug  6 13:53:43 2009
   1072 From: wmorgan-sup@masanjin.net (William Morgan)
   1073 Date: Thu, 06 Aug 2009 10:53:43 -0700
   1074 Subject: [sup-talk] sup ignoring SIGTERM?
   1075 In-Reply-To: <1249507336-sup-7887@masanjin.net>
   1076 References: <1249481294-sup-9967@chistera.yi.org>
   1077 	<1249502171-sup-8079@masanjin.net>
   1078 	<1249503870-sup-1415@ausone.home>
   1079 	<1249507336-sup-7887@masanjin.net>
   1080 Message-ID: <1249581215-sup-2548@masanjin.net>
   1081 
   1082 Reformatted excerpts from William Morgan's message of 2009-08-05:
   1083 > The problem is the removal of the select() in nonblocking_getch
   1084 > (buffer.rb circa line 25). With it in, resizes don't work right. With
   1085 > it removed, background threads are blocked on some computers. Not sure
   1086 > what makes the difference. Sigh...
   1087 
   1088 Ok, I've tracked this down. FWIW, this is a problem that's been around
   1089 in ruby ncurses libraries since at least 2005, when I complained about
   1090 it on ruby-core.
   1091 
   1092 In many ruby ncurses libraries, including the most recent gem,
   1093 Ncurses.getch blocks all Ruby threads from running. That's a bug. The
   1094 workaround is to wrap it in a select() call. But then you have to handle
   1095 sigwinch manually (i.e via Kernel#trap), because getch won't return a
   1096 resize "keystroke" until the user hits an actual key.
   1097 
   1098 The libncurses-ruby library on modern Ubuntu systems actually doesn't
   1099 have this problem. You can set nodelay false, throw out the select call,
   1100 and everything works the way it's supposed to: background threads run,
   1101 and you get a resize keystroke when a sigwinch happens without you
   1102 having to install your own handler. And that's the library I had been
   1103 developing against, which is why everything worked on one computer but
   1104 didn't work on the others.
   1105 
   1106 Anyways, for those who were having problems with this branch before,
   1107 please try the most recent version and confirm that:
   1108 1. Email threads load as normal, i.e. in the background.
   1109 2. Resizing the terminal refreshes the screen without you having to
   1110   press any keys.
   1111 3. Ctrl-l still works.
   1112 4. Ctrl-c still works (prompts you, and y/n do the right thing).
   1113 5. Killing Sup works.
   1114 
   1115 If everyone's happy, I'll merge this branch into next.
   1116 
   1117 If you're curious about whether you have a good or bad ncurses library,
   1118 run this program: (But either should work correctly with Sup.)
   1119 
   1120   require 'rubygems'
   1121   require 'ncurses'
   1122   require 'thread'
   1123 
   1124   Ncurses.initscr
   1125   Ncurses.noecho
   1126   Ncurses.cbreak
   1127   Ncurses.curs_set 0
   1128 
   1129   Thread.new do
   1130     sleep 0.1
   1131     Ncurses.stdscr.mvaddstr 0, 0, "ncurses library is GOOD."
   1132   end
   1133 
   1134   begin
   1135     Ncurses.stdscr.mvaddstr 0, 0, "ncurses library is BAD."
   1136     Ncurses.getch
   1137   ensure
   1138     Ncurses.curs_set 1
   1139     Ncurses.endwin
   1140     puts "bye"
   1141   end
   1142 -- 
   1143 William <wmorgan-sup at masanjin.net>
   1144 
   1145 From nicolas.pouillard@gmail.com  Thu Aug  6 14:09:35 2009
   1146 From: nicolas.pouillard@gmail.com (Nicolas Pouillard)
   1147 Date: Thu, 06 Aug 2009 20:09:35 +0200
   1148 Subject: [sup-talk] sup ignoring SIGTERM?
   1149 In-Reply-To: <1249581215-sup-2548@masanjin.net>
   1150 References: <1249481294-sup-9967@chistera.yi.org>
   1151 	<1249502171-sup-8079@masanjin.net>
   1152 	<1249503870-sup-1415@ausone.home>
   1153 	<1249507336-sup-7887@masanjin.net>
   1154 	<1249581215-sup-2548@masanjin.net>
   1155 Message-ID: <1249582142-sup-9952@ausone.home>
   1156 
   1157 Excerpts from William Morgan's message of Thu Aug 06 19:53:43 +0200 2009:
   1158 > Reformatted excerpts from William Morgan's message of 2009-08-05:
   1159 > > The problem is the removal of the select() in nonblocking_getch
   1160 > > (buffer.rb circa line 25). With it in, resizes don't work right. With
   1161 > > it removed, background threads are blocked on some computers. Not sure
   1162 > > what makes the difference. Sigh...
   1163 [...]
   1164 > If everyone's happy, I'll merge this branch into next.
   1165 
   1166 Works just great! Thanks.
   1167 
   1168 -- 
   1169 Nicolas Pouillard
   1170 http://nicolaspouillard.fr
   1171 
   1172 From dato@net.com.org.es  Thu Aug  6 14:37:25 2009
   1173 From: dato@net.com.org.es (Adeodato =?utf-8?B?U2ltw7M=?=)
   1174 Date: Thu, 6 Aug 2009 20:37:25 +0200
   1175 Subject: [sup-talk] sup ignoring SIGTERM?
   1176 In-Reply-To: <1249502171-sup-8079@masanjin.net>
   1177 References: <1249481294-sup-9967@chistera.yi.org>
   1178 	<1249502171-sup-8079@masanjin.net>
   1179 Message-ID: <20090806183725.GA8363@chistera.yi.org>
   1180 
   1181 + William Morgan (Wed, 05 Aug 2009 13:03:09 -0700):
   1182 
   1183 > Reformatted excerpts from Adeodato Sim?'s message of 2009-08-05:
   1184 > > it is my impression that sup is ignoring SIGTERM, whereas I would be
   1185 > > expecting for sup to clean up (including removal of the lock file) and
   1186 > > exit normally upon receiving this signal.
   1187 
   1188 > Good point. I've fixed that in branch ncurses-fixes, which I've merged
   1189 > into next. Let me know if it works for you.
   1190 
   1191 Everything seems to work fine as of 3478e40, including sup terminating
   1192 upon SIGTERM. If I may, I'd suggest normal termination instead of
   1193 raising an exception. IMHO, it is expected that programs that capture
   1194 SIGTERM, will do cleanup and exit normally, rather than behave as if an
   1195 error had happened. (Perhaps it'd be difficult to exit sup cleanly from
   1196 the handler in any other way than an exception: that, I don't know.)
   1197 
   1198 Thanks, in any case.
   1199 
   1200 -- 
   1201 - Are you sure we're good?
   1202 - Always.
   1203         -- Rory and Lorelai
   1204 
   1205 
   1206 From bwalton@artsci.utoronto.ca  Thu Aug  6 19:56:51 2009
   1207 From: bwalton@artsci.utoronto.ca (Ben Walton)
   1208 Date: Thu, 06 Aug 2009 19:56:51 -0400
   1209 Subject: [sup-talk] sup ignoring SIGTERM?
   1210 In-Reply-To: <1249581215-sup-2548@masanjin.net>
   1211 References: <1249481294-sup-9967@chistera.yi.org>
   1212 	<1249502171-sup-8079@masanjin.net>
   1213 	<1249503870-sup-1415@ausone.home>
   1214 	<1249507336-sup-7887@masanjin.net>
   1215 	<1249581215-sup-2548@masanjin.net>
   1216 Message-ID: <1249602985-sup-8547@ntdws12.chass.utoronto.ca>
   1217 
   1218 Excerpts from William Morgan's message of Thu Aug 06 13:53:43 -0400 2009:
   1219 > Ok, I've tracked this down. FWIW, this is a problem that's been around
   1220 > in ruby ncurses libraries since at least 2005, when I complained about
   1221 > it on ruby-core.
   1222 
   1223 ...yup, looks like you stuck the landing this time! :)
   1224 
   1225 Thanks
   1226 -Ben
   1227 -- 
   1228 Ben Walton
   1229 Systems Programmer - CHASS
   1230 University of Toronto
   1231 C:416.407.5610 | W:416.978.4302
   1232 
   1233 GPG Key Id: 8E89F6D2; Key Server: pgp.mit.edu
   1234 Contact me to arrange for a CAcert assurance meeting.
   1235 -------------- next part --------------
   1236 A non-text attachment was scrubbed...
   1237 Name: signature.asc
   1238 Type: application/pgp-signature
   1239 Size: 189 bytes
   1240 Desc: not available
   1241 URL: <http://rubyforge.org/pipermail/sup-talk/attachments/20090806/72c6f045/attachment.bin>
   1242 
   1243 From wmorgan-sup@masanjin.net  Thu Aug  6 21:38:53 2009
   1244 From: wmorgan-sup@masanjin.net (William Morgan)
   1245 Date: Thu, 06 Aug 2009 18:38:53 -0700
   1246 Subject: [sup-talk] sup ignoring SIGTERM?
   1247 In-Reply-To: <20090806183725.GA8363@chistera.yi.org>
   1248 References: <1249481294-sup-9967@chistera.yi.org>
   1249 	<1249502171-sup-8079@masanjin.net>
   1250 	<20090806183725.GA8363@chistera.yi.org>
   1251 Message-ID: <1249609105-sup-5858@masanjin.net>
   1252 
   1253 Reformatted excerpts from Adeodato Sim?'s message of 2009-08-06:
   1254 > Everything seems to work fine as of 3478e40, including sup terminating
   1255 > upon SIGTERM. If I may, I'd suggest normal termination instead of
   1256 > raising an exception. IMHO, it is expected that programs that capture
   1257 > SIGTERM, will do cleanup and exit normally, rather than behave as if
   1258 > an error had happened.
   1259 
   1260 Good idea. Try it now.
   1261 -- 
   1262 William <wmorgan-sup at masanjin.net>
   1263 
   1264 From dato@net.com.org.es  Fri Aug  7 06:31:51 2009
   1265 From: dato@net.com.org.es (Adeodato =?utf-8?B?U2ltw7M=?=)
   1266 Date: Fri, 7 Aug 2009 12:31:51 +0200
   1267 Subject: [sup-talk] sup ignoring SIGTERM?
   1268 In-Reply-To: <1249609105-sup-5858@masanjin.net>
   1269 References: <1249481294-sup-9967@chistera.yi.org>
   1270 	<1249502171-sup-8079@masanjin.net>
   1271 	<20090806183725.GA8363@chistera.yi.org>
   1272 	<1249609105-sup-5858@masanjin.net>
   1273 Message-ID: <20090807103151.GA20799@chistera.yi.org>
   1274 
   1275 + William Morgan (Thu, 06 Aug 2009 18:38:53 -0700):
   1276 
   1277 > Reformatted excerpts from Adeodato Sim?'s message of 2009-08-06:
   1278 > > Everything seems to work fine as of 3478e40, including sup terminating
   1279 > > upon SIGTERM. If I may, I'd suggest normal termination instead of
   1280 > > raising an exception. IMHO, it is expected that programs that capture
   1281 > > SIGTERM, will do cleanup and exit normally, rather than behave as if
   1282 > > an error had happened.
   1283 
   1284 > Good idea. Try it now.
   1285 
   1286 Ah, excellent: works as suggested now.
   1287 
   1288 Regarding 57dea7a (refactor index locking interaction and replace
   1289 suicidemanager), I'll note that at least on my system, and after having
   1290 moved to Xapian, those codepaths no longer execute. That is, if a sup is
   1291 running and a second one is started, it never gets to ask whether to
   1292 suggest dieing to the first one, because this second one dies with:
   1293 
   1294 [Fri Aug 07 12:31:05 +0200 2009] using character set encoding "UTF-8"
   1295 [Fri Aug 07 12:31:05 +0200 2009] using index Redwood::XapianIndex
   1296 [Fri Aug 07 12:31:05 +0200 2009] dynamically loading setlocale() from libc.so.6
   1297 [Fri Aug 07 12:31:05 +0200 2009] setting locale...
   1298 .../lib/sup/xapian_index.rb:24:in `initialize': Resource temporarily unavailable - /home/adeodato/.sup/entries.db (Errno::EAGAIN)
   1299         from .../lib/sup/xapian_index.rb:24:in `new'
   1300         from .../lib/sup/xapian_index.rb:24:in `initialize'
   1301         from .../bin/sup:132:in `new'
   1302         from .../bin/sup:132
   1303 
   1304 Thanks!
   1305 
   1306 -- 
   1307 - Are you sure we're good?
   1308 - Always.
   1309         -- Rory and Lorelai
   1310 
   1311 
   1312 From rlane@club.cc.cmu.edu  Thu Aug  6 15:32:44 2009
   1313 From: rlane@club.cc.cmu.edu (Rich Lane)
   1314 Date: Thu,  6 Aug 2009 12:32:44 -0700
   1315 Subject: [sup-talk] [PATCH] move xapian index loading into load_index
   1316 Message-ID: <1249587164-14080-1-git-send-email-rlane@club.cc.cmu.edu>
   1317 
   1318 ---
   1319  lib/sup/xapian_index.rb |   17 ++++++++---------
   1320  1 files changed, 8 insertions(+), 9 deletions(-)
   1321 
   1322 diff --git a/lib/sup/xapian_index.rb b/lib/sup/xapian_index.rb
   1323 index 5a5dfc1..861c2a3 100644
   1324 --- a/lib/sup/xapian_index.rb
   1325 +++ b/lib/sup/xapian_index.rb
   1326 @@ -20,14 +20,16 @@ class XapianIndex < BaseIndex
   1327      super
   1328  
   1329      @index_mutex = Monitor.new
   1330 +  end
   1331  
   1332 -    @entries = MarshalledGDBM.new File.join(dir, "entries.db")
   1333 -    @docids = MarshalledGDBM.new File.join(dir, "docids.db")
   1334 -    @thread_members = MarshalledGDBM.new File.join(dir, "thread_members.db")
   1335 -    @thread_ids = MarshalledGDBM.new File.join(dir, "thread_ids.db")
   1336 -    @assigned_docids = GDBM.new File.join(dir, "assigned_docids.db")
   1337 +  def load_index
   1338 +    @entries = MarshalledGDBM.new File.join(@dir, "entries.db")
   1339 +    @docids = MarshalledGDBM.new File.join(@dir, "docids.db")
   1340 +    @thread_members = MarshalledGDBM.new File.join(@dir, "thread_members.db")
   1341 +    @thread_ids = MarshalledGDBM.new File.join(@dir, "thread_ids.db")
   1342 +    @assigned_docids = GDBM.new File.join(@dir, "assigned_docids.db")
   1343  
   1344 -    @xapian = Xapian::WritableDatabase.new(File.join(dir, "xapian"), Xapian::DB_CREATE_OR_OPEN)
   1345 +    @xapian = Xapian::WritableDatabase.new(File.join(@dir, "xapian"), Xapian::DB_CREATE_OR_OPEN)
   1346      @term_generator = Xapian::TermGenerator.new()
   1347      @term_generator.stemmer = Xapian::Stem.new(STEM_LANGUAGE)
   1348      @enquire = Xapian::Enquire.new @xapian
   1349 @@ -35,9 +37,6 @@ class XapianIndex < BaseIndex
   1350      @enquire.docid_order = Xapian::Enquire::ASCENDING
   1351    end
   1352  
   1353 -  def load_index
   1354 -  end
   1355 -
   1356    def save_index
   1357    end
   1358  
   1359 -- 
   1360 1.6.4
   1361 
   1362 
   1363 From rlane@club.cc.cmu.edu  Fri Aug  7 12:40:18 2009
   1364 From: rlane@club.cc.cmu.edu (Rich Lane)
   1365 Date: Fri, 07 Aug 2009 12:40:18 -0400
   1366 Subject: [sup-talk] sup ignoring SIGTERM?
   1367 In-Reply-To: <20090807103151.GA20799@chistera.yi.org>
   1368 References: <1249481294-sup-9967@chistera.yi.org>
   1369 	<1249502171-sup-8079@masanjin.net>
   1370 	<20090806183725.GA8363@chistera.yi.org>
   1371 	<1249609105-sup-5858@masanjin.net>
   1372 	<20090807103151.GA20799@chistera.yi.org>
   1373 Message-ID: <1249662782-sup-638@pion.club.cc.cmu.edu>
   1374 
   1375 Excerpts from Adeodato Sim?'s message of Fri Aug 07 06:31:51 -0400 2009:
   1376 > Regarding 57dea7a (refactor index locking interaction and replace
   1377 > suicidemanager), I'll note that at least on my system, and after having
   1378 > moved to Xapian, those codepaths no longer execute. That is, if a sup is
   1379 > running and a second one is started, it never gets to ask whether to
   1380 > suggest dieing to the first one, because this second one dies with:
   1381 > 
   1382 > [Fri Aug 07 12:31:05 +0200 2009] using character set encoding "UTF-8"
   1383 > [Fri Aug 07 12:31:05 +0200 2009] using index Redwood::XapianIndex
   1384 > [Fri Aug 07 12:31:05 +0200 2009] dynamically loading setlocale() from libc.so.6
   1385 > [Fri Aug 07 12:31:05 +0200 2009] setting locale...
   1386 > .../lib/sup/xapian_index.rb:24:in `initialize': Resource temporarily
   1387 > unavailable - /home/adeodato/.sup/entries.db (Errno::EAGAIN)
   1388 >         from .../lib/sup/xapian_index.rb:24:in `new'
   1389 >         from .../lib/sup/xapian_index.rb:24:in `initialize'
   1390 >         from .../bin/sup:132:in `new'
   1391 >         from .../bin/sup:132
   1392 
   1393 I've just posted a patch that should fix this.
   1394 
   1395 From ezyang@MIT.EDU  Sat Aug  8 02:07:22 2009
   1396 From: ezyang@MIT.EDU (Edward Z. Yang)
   1397 Date: Sat, 08 Aug 2009 02:07:22 -0400
   1398 Subject: [sup-talk] Odd bug with lazy-loaded messages
   1399 In-Reply-To: <1249319474-sup-8322@masanjin.net>
   1400 References: <1248716007-sup-5156@javelin> <1249319474-sup-8322@masanjin.net>
   1401 Message-ID: <1249711570-sup-2277@javelin>
   1402 
   1403 Excerpts from William Morgan's message of Mon Aug 03 13:18:50 -0400 2009:
   1404 > This is because we store a couple variants of the address in the index
   1405 > (e.g. the email address to the left of the @), so that a search on any
   1406 > of them will bring up the message. Without #load_from_source!, the
   1407 > message is loaded from the index, so it reflects those fields. So it's
   1408 > basically a hack at this point. You could further hack it by undoing
   1409 > that transformation. Or we could add the original version of the fields
   1410 > to the index in a separate, non-searchable field, incurring the
   1411 > associated storage penalties.
   1412 
   1413 Great.  I sprinkled a few extra load_from_source! calls and I think
   1414 I made the weird behavior go away.  It's kind of sketchy though.
   1415 
   1416 >From 6c539b9c0fb952b0cc10c121cb906b1aefd58c31 Mon Sep 17 00:00:00 2001
   1417 From: Edward Z. Yang <edwardzyang at thewritingpot.com>
   1418 Date: Mon, 8 Jun 2009 22:21:01 -0400
   1419 Subject: [PATCH 1/3] Remove message pre-loading; optimizes for the common case.
   1420 
   1421 There are some load_from_source! calls to flush away extra
   1422 header info that we don't want displayed.  We may need to add
   1423 this in more/less places.
   1424 
   1425 Signed-off-by: Edward Z. Yang <ezyang at mit.edu>
   1426 ---
   1427  lib/sup/modes/thread-index-mode.rb |    1 -
   1428  lib/sup/modes/thread-view-mode.rb  |    2 ++
   1429  2 files changed, 2 insertions(+), 1 deletions(-)
   1430 
   1431 diff --git a/lib/sup/modes/thread-index-mode.rb b/lib/sup/modes/thread-index-mode.rb
   1432 index b671119..5e58072 100644
   1433 --- a/lib/sup/modes/thread-index-mode.rb
   1434 +++ b/lib/sup/modes/thread-index-mode.rb
   1435 @@ -105,7 +105,6 @@ EOS
   1436          t.each_with_index do |(m, *o), i|
   1437            next unless m
   1438            BufferManager.say "#{message} (#{i}/#{num})", sid if t.size > 1
   1439 -          m.load_from_source! 
   1440          end
   1441        end
   1442        mode = ThreadViewMode.new t, @hidden_labels, self
   1443 diff --git a/lib/sup/modes/thread-view-mode.rb b/lib/sup/modes/thread-view-mode.rb
   1444 index 737f6f1..94e3ed7 100644
   1445 --- a/lib/sup/modes/thread-view-mode.rb
   1446 +++ b/lib/sup/modes/thread-view-mode.rb
   1447 @@ -124,6 +124,7 @@ EOS
   1448        end
   1449      end
   1450  
   1451 +    latest.load_from_source!
   1452      @layout[latest].state = :open if @layout[latest].state == :closed
   1453      @layout[earliest].state = :detailed if earliest.has_label?(:unread) || @thread.size == 1
   1454  
   1455 @@ -555,6 +556,7 @@ private
   1456  
   1457    def initial_state_for m
   1458      if m.has_label?(:starred) || m.has_label?(:unread)
   1459 +      m.load_from_source!
   1460        :open
   1461      else
   1462        :closed
   1463 -- 
   1464 1.6.3.3
   1465 
   1466 From dato@net.com.org.es  Sat Aug  8 05:23:25 2009
   1467 From: dato@net.com.org.es (Adeodato =?utf-8?B?U2ltw7M=?=)
   1468 Date: Sat, 8 Aug 2009 11:23:25 +0200
   1469 Subject: [sup-talk] sup ignoring SIGTERM?
   1470 In-Reply-To: <1249662782-sup-638@pion.club.cc.cmu.edu>
   1471 References: <1249481294-sup-9967@chistera.yi.org>
   1472 	<1249502171-sup-8079@masanjin.net>
   1473 	<20090806183725.GA8363@chistera.yi.org>
   1474 	<1249609105-sup-5858@masanjin.net>
   1475 	<20090807103151.GA20799@chistera.yi.org>
   1476 	<1249662782-sup-638@pion.club.cc.cmu.edu>
   1477 Message-ID: <20090808092325.GA2392@chistera.yi.org>
   1478 
   1479 + Rich Lane (Fri, 07 Aug 2009 12:40:18 -0400):
   1480 > > [Fri Aug 07 12:31:05 +0200 2009] using character set encoding "UTF-8"
   1481 > > [Fri Aug 07 12:31:05 +0200 2009] using index Redwood::XapianIndex
   1482 > > [Fri Aug 07 12:31:05 +0200 2009] dynamically loading setlocale() from libc.so.6
   1483 > > [Fri Aug 07 12:31:05 +0200 2009] setting locale...
   1484 > > .../lib/sup/xapian_index.rb:24:in `initialize': Resource temporarily
   1485 > > unavailable - /home/adeodato/.sup/entries.db (Errno::EAGAIN)
   1486 > >         from .../lib/sup/xapian_index.rb:24:in `new'
   1487 > >         from .../lib/sup/xapian_index.rb:24:in `initialize'
   1488 > >         from .../bin/sup:132:in `new'
   1489 > >         from .../bin/sup:132
   1490 
   1491 > I've just posted a patch that should fix this.
   1492 
   1493 It works, thank you!
   1494 
   1495 -- 
   1496 - Are you sure we're good?
   1497 - Always.
   1498         -- Rory and Lorelai
   1499 
   1500 
   1501 From ezyang@MIT.EDU  Sun Aug  9 04:40:33 2009
   1502 From: ezyang@MIT.EDU (Edward Z. Yang)
   1503 Date: Sun, 09 Aug 2009 04:40:33 -0400
   1504 Subject: [sup-talk] Odd bug with lazy-loaded messages
   1505 In-Reply-To: <1249711570-sup-2277@javelin>
   1506 References: <1248716007-sup-5156@javelin> <1249319474-sup-8322@masanjin.net>
   1507 	<1249711570-sup-2277@javelin>
   1508 Message-ID: <1249807206-sup-55@javelin>
   1509 
   1510 Excerpts from Edward Z. Yang's message of Sat Aug 08 02:07:22 -0400 2009:
   1511 > Great.  I sprinkled a few extra load_from_source! calls and I think
   1512 > I made the weird behavior go away.  It's kind of sketchy though.
   1513 
   1514 It looks like it's still a problem in some sporadic cases.  Going to
   1515 submit a more thorough patch soon.
   1516 
   1517 Cheers,
   1518 Edward
   1519 
   1520 From jstewart@fusionary.com  Mon Aug 10 09:22:43 2009
   1521 From: jstewart@fusionary.com (Jason Stewart)
   1522 Date: Mon, 10 Aug 2009 09:22:43 -0400
   1523 Subject: [sup-talk] Starring messages in a hook
   1524 Message-ID: <1249910430-sup-4573@JasonsComputer-3.local>
   1525 
   1526 Hello,
   1527 
   1528 New sup user here and I have to say that I'm very impressed with it even
   1529 though I've only been using it for a few days. 
   1530 
   1531 I'm using a before-add-message to label messages, and was wondering if
   1532 there's a way to star them in this hook? Looking at the source for
   1533 message.rb I see an add_label, but no add_star.
   1534 
   1535 From ismith@MIT.EDU  Mon Aug 10 11:07:38 2009
   1536 From: ismith@MIT.EDU (Ian Smith)
   1537 Date: Mon, 10 Aug 2009 11:07:38 -0400
   1538 Subject: [sup-talk] Starring messages in a hook
   1539 In-Reply-To: <1249910430-sup-4573@JasonsComputer-3.local>
   1540 References: <1249910430-sup-4573@JasonsComputer-3.local>
   1541 Message-ID: <1249916791-sup-4269@baad>
   1542 
   1543 Hi Jason,
   1544 
   1545 Starred messages are labeled "Starred"; presumably just adding this
   1546 label to the message would do what you want.
   1547 
   1548 Ian
   1549 
   1550 Excerpts from Jason Stewart's message of Mon Aug 10 09:22:43 -0400 2009:
   1551 > Hello,
   1552 > 
   1553 > New sup user here and I have to say that I'm very impressed with it even
   1554 > though I've only been using it for a few days. 
   1555 > 
   1556 > I'm using a before-add-message to label messages, and was wondering if
   1557 > there's a way to star them in this hook? Looking at the source for
   1558 > message.rb I see an add_label, but no add_star.
   1559 -- 
   1560 Ian Smith
   1561 ismith at mit.edu
   1562 ismith at bostonaccess.org
   1563 
   1564 From wmorgan-sup@masanjin.net  Tue Aug 11 16:14:44 2009
   1565 From: wmorgan-sup@masanjin.net (William Morgan)
   1566 Date: Tue, 11 Aug 2009 13:14:44 -0700
   1567 Subject: [sup-talk] some internal api refactors
   1568 Message-ID: <1250021119-sup-4253@masanjin.net>
   1569 
   1570 Hi Rich, and others,
   1571 
   1572 In the branch various-api-refactors I've made a couple significant
   1573 genotypic changes to the index and polling API that I want to make sure
   1574 are in line with your evil plans. Commit 8aa1370d in particular replaces
   1575 Index.sync_message with three methods, one for adding new messages, one
   1576 for updating existing messages, and one for just tweaking the labels.
   1577 The current implementation just calls the original sync_message
   1578 implementation for all three. The rest of the changes are tweaks in the
   1579 various consumers of these messages.
   1580 
   1581 The intention is that this will be useful both for Xapian and Sup the
   1582 server, which may need to distinguish between these three methods of
   1583 index access (or may simply want to for speed).
   1584 -- 
   1585 William <wmorgan-sup at masanjin.net>
   1586 
   1587 From wmorgan-sup@masanjin.net  Tue Aug 11 16:18:15 2009
   1588 From: wmorgan-sup@masanjin.net (William Morgan)
   1589 Date: Tue, 11 Aug 2009 13:18:15 -0700
   1590 Subject: [sup-talk] [PATCH] move xapian index loading into load_index
   1591 In-Reply-To: <1249587164-14080-1-git-send-email-rlane@club.cc.cmu.edu>
   1592 References: <1249587164-14080-1-git-send-email-rlane@club.cc.cmu.edu>
   1593 Message-ID: <1250021889-sup-3224@masanjin.net>
   1594 
   1595 Applied, thanks!
   1596 -- 
   1597 William <wmorgan-sup at masanjin.net>
   1598 
   1599 From wmorgan-sup@masanjin.net  Tue Aug 11 16:22:30 2009
   1600 From: wmorgan-sup@masanjin.net (William Morgan)
   1601 Date: Tue, 11 Aug 2009 13:22:30 -0700
   1602 Subject: [sup-talk] Stack overflow in regexp matcher
   1603 In-Reply-To: <92457f310908030116k146a901aleee95a09db907d97@mail.gmail.com>
   1604 References: <92457f310908030116k146a901aleee95a09db907d97@mail.gmail.com>
   1605 Message-ID: <1250021966-sup-933@masanjin.net>
   1606 
   1607 Hi Mark,
   1608 
   1609 Reformatted excerpts from Mark Drayton's message of 2009-08-03:
   1610 > ## read 440m (about 52%) @ 2.2m/s. 0:03:19 elapsed, about 0:03:03 remaining
   1611 > Stack overflow in regexp matcher:
   1612 > /,\s*(?=(?:[^"]*"[^"]*")*(?![^"]*"))/ (RegexpError)
   1613 
   1614 Interesting. Looks like Sup is trying to split a header line into
   1615 multiple email addresses and something's causing it to bomb. Are you
   1616 able to identify the line that's causing this problem? That would be
   1617 helpful to know.
   1618 
   1619 > This error seems to have cropped up in other software so I suspect
   1620 > it's a problem with Ruby, not sup. Anyone able to confirm this?
   1621 
   1622 It's a problem with Ruby's regular expression implementation, I suppose,
   1623 but we've never seen it before. The solution is to either tweak the
   1624 regexp until it starts working, or implement a custom parsing solution,
   1625 neither of which sounds that entertaining...
   1626 -- 
   1627 William <wmorgan-sup at masanjin.net>
   1628 
   1629 From wmorgan-sup@masanjin.net  Tue Aug 11 16:28:46 2009
   1630 From: wmorgan-sup@masanjin.net (William Morgan)
   1631 Date: Tue, 11 Aug 2009 13:28:46 -0700
   1632 Subject: [sup-talk] [PATCH] run-mailcap fix
   1633 In-Reply-To: <1249226521-sup-4719@localdomain>
   1634 References: <1249226521-sup-4719@localdomain>
   1635 Message-ID: <1250022259-sup-8328@masanjin.net>
   1636 
   1637 Hi Beno?t,
   1638 
   1639 Reformatted excerpts from Beno?t PIERRE's message of 2009-08-02:
   1640 > The attached patch fix this by not redirecting stderr to /dev/null.
   1641 > It also restores the correct ncurses state (including arrow
   1642 > keypresses, thanks to Edward Z. Yang recent patch).
   1643 
   1644 Thanks! Not redirecting stderr to /dev/null is probably fine. But how
   1645 about calling BufferManager.shell_out instead?
   1646 
   1647 If you want to submit a proper git commit via git-format-email, I will
   1648 be happy to apply it and you can get your name in the illustrious Sup
   1649 contributor roster. Otherwise I will make this change for you.
   1650 -- 
   1651 William <wmorgan-sup at masanjin.net>
   1652 
   1653 From benoit.pierre@gmail.com  Tue Aug 11 18:09:40 2009
   1654 From: benoit.pierre@gmail.com (=?utf-8?q?Beno=C3=AEt=20PIERRE?=)
   1655 Date: Wed, 12 Aug 2009 00:09:40 +0200
   1656 Subject: [sup-talk] [PATCH run-mailcap 1/2] Don't redirect stderr to
   1657 	/dev/null when calling run-mailcap.
   1658 In-Reply-To: <1250022259-sup-8328@masanjin.net>
   1659 References: <1250022259-sup-8328@masanjin.net>
   1660 Message-ID: <1250028581-15826-1-git-send-email-benoit.pierre@gmail.com>
   1661 
   1662 Some programs will fail to work correctly if this is done, like for
   1663 example: w3m --dump, to view HTML files.
   1664 ---
   1665  lib/sup/message-chunks.rb |    2 +-
   1666  1 files changed, 1 insertions(+), 1 deletions(-)
   1667 
   1668 diff --git a/lib/sup/message-chunks.rb b/lib/sup/message-chunks.rb
   1669 index 0d742d9..4c947e1 100644
   1670 --- a/lib/sup/message-chunks.rb
   1671 +++ b/lib/sup/message-chunks.rb
   1672 @@ -131,7 +131,7 @@ EOS
   1673      def initial_state; :open end
   1674      def viewable?; @lines.nil? end
   1675      def view_default! path
   1676 -      cmd = "/usr/bin/run-mailcap --action=view '#{@content_type}:#{path}' 2>/dev/null"
   1677 +      cmd = "/usr/bin/run-mailcap --action=view '#{@content_type}:#{path}'"
   1678        Redwood::log "running: #{cmd.inspect}"
   1679        system cmd
   1680        $? == 0
   1681 -- 
   1682 1.6.3.3
   1683 
   1684 
   1685 From benoit.pierre@gmail.com  Tue Aug 11 18:09:41 2009
   1686 From: benoit.pierre@gmail.com (=?utf-8?q?Beno=C3=AEt=20PIERRE?=)
   1687 Date: Wed, 12 Aug 2009 00:09:41 +0200
   1688 Subject: [sup-talk] [PATCH run-mailcap 2/2] Use BufferManager.shell_out to
   1689 	call run-mailcap instead of system.
   1690 In-Reply-To: <1250028581-15826-1-git-send-email-benoit.pierre@gmail.com>
   1691 References: <1250028581-15826-1-git-send-email-benoit.pierre@gmail.com>
   1692 Message-ID: <1250028581-15826-2-git-send-email-benoit.pierre@gmail.com>
   1693 
   1694 This ensure ncurses state is correctly restored upon command completion.
   1695 ---
   1696  lib/sup/message-chunks.rb |    2 +-
   1697  1 files changed, 1 insertions(+), 1 deletions(-)
   1698 
   1699 diff --git a/lib/sup/message-chunks.rb b/lib/sup/message-chunks.rb
   1700 index 4c947e1..1910abd 100644
   1701 --- a/lib/sup/message-chunks.rb
   1702 +++ b/lib/sup/message-chunks.rb
   1703 @@ -133,7 +133,7 @@ EOS
   1704      def view_default! path
   1705        cmd = "/usr/bin/run-mailcap --action=view '#{@content_type}:#{path}'"
   1706        Redwood::log "running: #{cmd.inspect}"
   1707 -      system cmd
   1708 +      BufferManager.shell_out(cmd)
   1709        $? == 0
   1710      end
   1711  
   1712 -- 
   1713 1.6.3.3
   1714 
   1715 
   1716 From rlane@club.cc.cmu.edu  Wed Aug 12 01:26:53 2009
   1717 From: rlane@club.cc.cmu.edu (Rich Lane)
   1718 Date: Wed, 12 Aug 2009 01:26:53 -0400
   1719 Subject: [sup-talk] some internal api refactors
   1720 In-Reply-To: <1250021119-sup-4253@masanjin.net>
   1721 References: <1250021119-sup-4253@masanjin.net>
   1722 Message-ID: <1250054282-sup-9053@pion.club.cc.cmu.edu>
   1723 
   1724 It's worth noting that update_message_state needs to handle modified
   1725 refs and snippets as well as labels. Maybe add a comment about this in
   1726 BaseIndex?
   1727 
   1728 From mark@markdrayton.info  Wed Aug 12 04:45:01 2009
   1729 From: mark@markdrayton.info (Mark Drayton)
   1730 Date: Wed, 12 Aug 2009 09:45:01 +0100
   1731 Subject: [sup-talk] Stack overflow in regexp matcher
   1732 In-Reply-To: <1250021966-sup-933@masanjin.net>
   1733 References: <92457f310908030116k146a901aleee95a09db907d97@mail.gmail.com>
   1734 	<1250021966-sup-933@masanjin.net>
   1735 Message-ID: <92457f310908120145n453d6639mf22fe68b62054392@mail.gmail.com>
   1736 
   1737 Hi William
   1738 
   1739 On Tue, Aug 11, 2009 at 9:22 PM, William Morgan<wmorgan-sup at masanjin.net> wrote:
   1740 > Interesting. Looks like Sup is trying to split a header line into
   1741 > multiple email addresses and something's causing it to bomb. Are you
   1742 > able to identify the line that's causing this problem? That would be
   1743 > helpful to know.
   1744 
   1745 Sorry, I should have dug a bit deeper before reporting this. I was
   1746 naively assuming it was a known problem (though Google didn't know, so
   1747 I guess it's not) and that the answer would be "upgrade foo".
   1748 
   1749 The line it's choking on is 284058 bytes long and contains ~6400
   1750 addresses. (gotta love mail from "internal communications"). If I
   1751 halve the number of addresses it works, so perhaps this isn't worth
   1752 fixing at all. If you do want to tackle it I'm happy to help off-list.
   1753 
   1754 Cheers,
   1755 
   1756 Mark
   1757 
   1758 From ingmar@exherbo.org  Wed Aug 12 09:05:35 2009
   1759 From: ingmar@exherbo.org (Ingmar Vanhassel)
   1760 Date: Wed, 12 Aug 2009 15:05:35 +0200
   1761 Subject: [sup-talk] [PATCH 0/18] Xapian-based index
   1762 In-Reply-To: <1249056691-sup-9011@pion.club.cc.cmu.edu>
   1763 References: <1245531017-9907-1-git-send-email-rlane@club.cc.cmu.edu>
   1764 	<1245854803-sup-4481@entry> <1245864733-sup-1216@entry>
   1765 	<loom.20090625T222159-861@post.gmane.org>
   1766 	<1246022094-sup-3336@entry> <1247873980-sup-8574@wrasse>
   1767 	<20090723102325.GA4291@chistera.yi.org>
   1768 	<1248497184-sup-939@pion.club.cc.cmu.edu>
   1769 	<1248513425-sup-2484@chistera.yi.org>
   1770 	<1248550384-sup-74@pion.club.cc.cmu.edu>
   1771 	<1248709681-sup-4141@entry>
   1772 	<1248710432-sup-1734@pion.club.cc.cmu.edu>
   1773 	<1249056691-sup-9011@pion.club.cc.cmu.edu>
   1774 Message-ID: <1250082297-sup-6018@cannonball>
   1775 
   1776 Excerpts from Rich Lane's message of Fri Jul 31 18:20:41 +0200 2009:
   1777 > Excerpts from Rich Lane's message of Mon Jul 27 13:06:34 -0400 2009:
   1778 > > Excerpts from William Morgan's message of Mon Jul 27 11:48:38 -0400 2009:
   1779 > > > Reformatted excerpts from Rich Lane's message of 2009-07-25:
   1780 > > > > One issue I've noticed is that removing labels from messages doesn't
   1781 > > > > always immediately work.
   1782 > > > 
   1783 > > > Is this true even after you sync changes to the index? What about if you
   1784 > > > reload the label list buffer? ('@')
   1785 > > 
   1786 > > Yes. This is looking like a Xapian bug - I've reproduced it without any
   1787 > > Sup code. I'm working on a fix.
   1788 > 
   1789 > I've fixed this, it should be released in Xapian 1.0.15. Or, grab Xapian
   1790 > SVN and you can try out the Chert backend too (XAPIAN_PREFER_CHERT=1).
   1791 
   1792 Could you point me to the SVN revision containing the fix? I'd like to
   1793 backport the fix to my Xapian 1.0.14 packages, pending 1.0.15 release.
   1794 
   1795 Thanks!
   1796 
   1797 -- 
   1798 Exherbo KDE, X.org maintainer
   1799 
   1800 From nicolas.pouillard@gmail.com  Wed Aug 12 10:32:04 2009
   1801 From: nicolas.pouillard@gmail.com (Nicolas Pouillard)
   1802 Date: Wed, 12 Aug 2009 16:32:04 +0200
   1803 Subject: [sup-talk] [PATCH 0/18] Xapian-based index
   1804 In-Reply-To: <1250082297-sup-6018@cannonball>
   1805 References: <1245531017-9907-1-git-send-email-rlane@club.cc.cmu.edu>
   1806 	<1245854803-sup-4481@entry> <1245864733-sup-1216@entry>
   1807 	<loom.20090625T222159-861@post.gmane.org>
   1808 	<1246022094-sup-3336@entry> <1247873980-sup-8574@wrasse>
   1809 	<20090723102325.GA4291@chistera.yi.org>
   1810 	<1248497184-sup-939@pion.club.cc.cmu.edu>
   1811 	<1248513425-sup-2484@chistera.yi.org>
   1812 	<1248550384-sup-74@pion.club.cc.cmu.edu>
   1813 	<1248709681-sup-4141@entry>
   1814 	<1248710432-sup-1734@pion.club.cc.cmu.edu>
   1815 	<1249056691-sup-9011@pion.club.cc.cmu.edu>
   1816 	<1250082297-sup-6018@cannonball>
   1817 Message-ID: <1250087467-sup-6888@ausone.inria.fr>
   1818 
   1819 Excerpts from Ingmar Vanhassel's message of Wed Aug 12 15:05:35 +0200 2009:
   1820 > Excerpts from Rich Lane's message of Fri Jul 31 18:20:41 +0200 2009:
   1821 > > Excerpts from Rich Lane's message of Mon Jul 27 13:06:34 -0400 2009:
   1822 > > > Excerpts from William Morgan's message of Mon Jul 27 11:48:38 -0400 2009:
   1823 > > > > Reformatted excerpts from Rich Lane's message of 2009-07-25:
   1824 > > > > > One issue I've noticed is that removing labels from messages doesn't
   1825 > > > > > always immediately work.
   1826 > > > > 
   1827 > > > > Is this true even after you sync changes to the index? What about if you
   1828 > > > > reload the label list buffer? ('@')
   1829 > > > 
   1830 > > > Yes. This is looking like a Xapian bug - I've reproduced it without any
   1831 > > > Sup code. I'm working on a fix.
   1832 > > 
   1833 > > I've fixed this, it should be released in Xapian 1.0.15. Or, grab Xapian
   1834 > > SVN and you can try out the Chert backend too (XAPIAN_PREFER_CHERT=1).
   1835 
   1836 BTW, does someone have successfully built Xapian under Mac OS X ?
   1837 
   1838 -- 
   1839 Nicolas Pouillard
   1840 http://nicolaspouillard.fr
   1841 
   1842 From taruti@taruti.net  Thu Aug 13 03:32:02 2009
   1843 From: taruti@taruti.net (Taru Karttunen)
   1844 Date: Thu, 13 Aug 2009 10:32:02 +0300
   1845 Subject: [sup-talk] Sup crashing
   1846 Message-ID: <1250148617-sup-6053@oz.taruti.net>
   1847 
   1848 Hello
   1849 
   1850 I am using Sup git master version and it started to crash today
   1851 when viewing messages with a label. Any hints how to fix this?
   1852 
   1853 --- ArgumentError from thread: load threads for thread-index-mode
   1854 :93349 is out of range [0..93204] for IndexReader#[]
   1855 /usr/lib/ruby/1.8/ferret/index.rb:421:in `[]'
   1856 /usr/lib/ruby/1.8/ferret/index.rb:421:in `[]'
   1857 /usr/lib/ruby/1.8/monitor.rb:242:in `synchronize'
   1858 /usr/lib/ruby/1.8/ferret/index.rb:413:in `[]'
   1859 ./lib/sup/ferret_index.rb:151:in `each_id_by_date'
   1860 /usr/lib/ruby/1.8/monitor.rb:242:in `synchronize'
   1861 ./lib/sup/ferret_index.rb:151:in `each_id_by_date'
   1862 ./lib/sup/ferret_index.rb:150:in `each'
   1863 ./lib/sup/ferret_index.rb:150:in `each_id_by_date'
   1864 ./lib/sup/thread.rb:328:in `load_n_threads'
   1865 ./lib/sup/modes/thread-index-mode.rb:623:in `__unprotected_load_n_threads'
   1866 (eval):12:in `load_n_threads'
   1867 ./lib/sup/modes/thread-index-mode.rb:607:in `load_n_threads_background'
   1868 ./lib/sup.rb:77:in `reporting_thread'
   1869 ./lib/sup.rb:75:in `initialize'
   1870 ./lib/sup.rb:75:in `new'
   1871 ./lib/sup.rb:75:in `reporting_thread'
   1872 ./lib/sup/modes/thread-index-mode.rb:606:in `load_n_threads_background'
   1873 ./lib/sup/modes/thread-index-mode.rb:676:in `__unprotected_load_threads'
   1874 (eval):12:in `load_threads'
   1875 ./lib/sup/modes/label-search-results-mode.rb:33:in `spawn_nicely'
   1876 ./lib/sup/modes/label-list-mode.rb:93:in `select_label'
   1877 ./lib/sup/mode.rb:50:in `send'
   1878 ./lib/sup/mode.rb:50:in `handle_input'
   1879 ./lib/sup/buffer.rb:249:in `handle_input'
   1880 bin/sup:236
   1881 
   1882 - Taru Karttunen
   1883 
   1884 From rlane@club.cc.cmu.edu  Fri Aug 14 01:23:21 2009
   1885 From: rlane@club.cc.cmu.edu (Rich Lane)
   1886 Date: Fri, 14 Aug 2009 01:23:21 -0400
   1887 Subject: [sup-talk] [PATCH 0/18] Xapian-based index
   1888 In-Reply-To: <1250082297-sup-6018@cannonball>
   1889 References: <1245531017-9907-1-git-send-email-rlane@club.cc.cmu.edu>
   1890 	<1245854803-sup-4481@entry> <1245864733-sup-1216@entry>
   1891 	<loom.20090625T222159-861@post.gmane.org>
   1892 	<1246022094-sup-3336@entry> <1247873980-sup-8574@wrasse>
   1893 	<20090723102325.GA4291@chistera.yi.org>
   1894 	<1248497184-sup-939@pion.club.cc.cmu.edu>
   1895 	<1248513425-sup-2484@chistera.yi.org>
   1896 	<1248550384-sup-74@pion.club.cc.cmu.edu>
   1897 	<1248709681-sup-4141@entry>
   1898 	<1248710432-sup-1734@pion.club.cc.cmu.edu>
   1899 	<1249056691-sup-9011@pion.club.cc.cmu.edu>
   1900 	<1250082297-sup-6018@cannonball>
   1901 Message-ID: <1250227281-sup-8626@pion.club.cc.cmu.edu>
   1902 
   1903 Excerpts from Ingmar Vanhassel's message of Wed Aug 12 09:05:35 -0400 2009:
   1904 > Could you point me to the SVN revision containing the fix? I'd like to
   1905 > backport the fix to my Xapian 1.0.14 packages, pending 1.0.15 release.
   1906 
   1907 Revision 13219.
   1908 
   1909 From guillaume.quintard@gmail.com  Fri Aug 14 06:18:25 2009
   1910 From: guillaume.quintard@gmail.com (Guillaume Quintard)
   1911 Date: Fri, 14 Aug 2009 12:18:25 +0200
   1912 Subject: [sup-talk] Poll delay and states not really saved
   1913 Message-ID: <1250244850-sup-5869@altis>
   1914 
   1915 Hi,
   1916 Two things:
   1917 - I'm using xapian (git) and it seems that staates are only saved during
   1918 exits. Meaning that if I clean my inbox with A, then save with $, and
   1919 then refresh with @., all the messages are still here (as read, though).
   1920 
   1921 - Can we have a config options for the time between poll, currently it's
   1922 hardcoded to 300s but I like to hammer my gmail box with requests.
   1923 
   1924 Apart from that, sup works pretty well with xapian.
   1925 
   1926 Cheers,
   1927 
   1928 -- 
   1929 Guillaume
   1930 
   1931 From ingmar@exherbo.org  Fri Aug 14 07:12:04 2009
   1932 From: ingmar@exherbo.org (Ingmar Vanhassel)
   1933 Date: Fri, 14 Aug 2009 13:12:04 +0200
   1934 Subject: [sup-talk] Poll delay and states not really saved
   1935 In-Reply-To: <1250244850-sup-5869@altis>
   1936 References: <1250244850-sup-5869@altis>
   1937 Message-ID: <1250248287-sup-2973@cannonball>
   1938 
   1939 Excerpts from Guillaume Quintard's message of Fri Aug 14 12:18:25 +0200 2009:
   1940 > Hi,
   1941 > Two things:
   1942 > - I'm using xapian (git) and it seems that staates are only saved during
   1943 > exits. Meaning that if I clean my inbox with A, then save with $, and
   1944 > then refresh with @., all the messages are still here (as read, though).
   1945 > 
   1946 > - Can we have a config options for the time between poll, currently it's
   1947 > hardcoded to 300s but I like to hammer my gmail box with requests.
   1948 > 
   1949 > Apart from that, sup works pretty well with xapian.
   1950 > 
   1951 > Cheers,
   1952 > 
   1953 
   1954 See http://mid.gmane.org/1248710432-sup-1734 at pion.club.cc.cmu.edu
   1955 
   1956 -- 
   1957 Exherbo KDE, X.org maintainer
   1958 
   1959 From guillaume.quintard@gmail.com  Fri Aug 14 07:18:44 2009
   1960 From: guillaume.quintard@gmail.com (Guillaume Quintard)
   1961 Date: Fri, 14 Aug 2009 13:18:44 +0200
   1962 Subject: [sup-talk] Poll delay and states not really saved
   1963 In-Reply-To: <1250248287-sup-2973@cannonball>
   1964 References: <1250244850-sup-5869@altis> <1250248287-sup-2973@cannonball>
   1965 Message-ID: <1250248660-sup-2819@altis>
   1966 
   1967 Excerpts from Ingmar Vanhassel's message of Fri Aug 14 13:12:04 +0200 2009:
   1968 > See http://mid.gmane.org/1248710432-sup-1734 at pion.club.cc.cmu.edu
   1969 > 
   1970 
   1971 ah thanks, didn't remember that mail.
   1972 
   1973 but the poll delay still stands :-)
   1974 
   1975 -- 
   1976 Guillaume
   1977 
   1978 From wmorgan-sup@masanjin.net  Fri Aug 14 16:17:38 2009
   1979 From: wmorgan-sup@masanjin.net (William Morgan)
   1980 Date: Fri, 14 Aug 2009 13:17:38 -0700
   1981 Subject: [sup-talk] [PATCH run-mailcap 2/2] Use BufferManager.shell_out
   1982 	to call run-mailcap instead of system.
   1983 In-Reply-To: <1250028581-15826-2-git-send-email-benoit.pierre@gmail.com>
   1984 References: <1250022259-sup-8328@masanjin.net>
   1985 	<1250028581-15826-2-git-send-email-benoit.pierre@gmail.com>
   1986 Message-ID: <1250281039-sup-2788@masanjin.net>
   1987 
   1988 Reformatted excerpts from Beno?t PIERRE's message of 2009-08-11:
   1989 > This ensure ncurses state is correctly restored upon command completion.
   1990 
   1991 Both patches applies to branch run-mailcap-fixes, merged into next.
   1992 Thanks!
   1993 -- 
   1994 William <wmorgan-sup at masanjin.net>
   1995 
   1996 From wmorgan-sup@masanjin.net  Fri Aug 14 16:20:28 2009
   1997 From: wmorgan-sup@masanjin.net (William Morgan)
   1998 Date: Fri, 14 Aug 2009 13:20:28 -0700
   1999 Subject: [sup-talk] Sup crashing
   2000 In-Reply-To: <1250148617-sup-6053@oz.taruti.net>
   2001 References: <1250148617-sup-6053@oz.taruti.net>
   2002 Message-ID: <1250281208-sup-4199@masanjin.net>
   2003 
   2004 Reformatted excerpts from Taru Karttunen's message of 2009-08-13:
   2005 > --- ArgumentError from thread: load threads for thread-index-mode
   2006 > :93349 is out of range [0..93204] for IndexReader#[]
   2007 
   2008 Weird. Does sup-sync --optimize fix anything?
   2009 -- 
   2010 William <wmorgan-sup at masanjin.net>
   2011 
   2012 From benoit.pierre@gmail.com  Fri Aug 14 18:37:21 2009
   2013 From: benoit.pierre@gmail.com (=?utf-8?q?Beno=C3=AEt_PIERRE?=)
   2014 Date: Sat, 15 Aug 2009 00:37:21 +0200
   2015 Subject: [sup-talk] [PATCH run-mailcap 2/2] Use BufferManager.shell_out
   2016 	to call run-mailcap instead of system.
   2017 In-Reply-To: <1250281039-sup-2788@masanjin.net>
   2018 References: <1250022259-sup-8328@masanjin.net>
   2019 	<1250028581-15826-2-git-send-email-benoit.pierre@gmail.com>
   2020 	<1250281039-sup-2788@masanjin.net>
   2021 Message-ID: <1250289386-sup-7331@localdomain>
   2022 
   2023 Excerpts from William Morgan's message of Fri Aug 14 22:17:38 +0200 2009:
   2024 > Reformatted excerpts from Beno?t PIERRE's message of 2009-08-11:
   2025 > > This ensure ncurses state is correctly restored upon command completion.
   2026 > 
   2027 > Both patches applies to branch run-mailcap-fixes, merged into next.
   2028 
   2029 Great!
   2030 
   2031 One problem though, I tested next, and 3478e400ae31b459b2875cc226796a6d4bba11f9
   2032 (rewrap getch in select, handle sigwinch manually) introduced a regression: I
   2033 get some 'key not handled' errors after run-mail has been called when sup is
   2034 getting back control if I press for example an arrow... ;(
   2035 
   2036 Arrows become usable again after I press a "normal" key (like 'a').
   2037 
   2038 Cheers,
   2039 -- 
   2040 A: Because it destroys the flow of conversation.
   2041 Q: Why is top posting dumb?
   2042 
   2043 From benoit.pierre@gmail.com  Fri Aug 14 19:08:48 2009
   2044 From: benoit.pierre@gmail.com (=?utf-8?q?Beno=C3=AEt_PIERRE?=)
   2045 Date: Sat, 15 Aug 2009 01:08:48 +0200
   2046 Subject: [sup-talk] [PATCH] Restore keypad mode after we force ncurses to
   2047 	refresh the whole screen.
   2048 In-Reply-To: <1250289386-sup-7331@localdomain>
   2049 References: <1250022259-sup-8328@masanjin.net>
   2050 	<1250028581-15826-2-git-send-email-benoit.pierre@gmail.com>
   2051 	<1250281039-sup-2788@masanjin.net>
   2052 	<1250289386-sup-7331@localdomain>
   2053 Message-ID: <1250291137-sup-2796@localdomain>
   2054 
   2055 This also happen to fix a regression after a call to run-mailcap, since
   2056 for some reason a screen resize event is triggered when we get control
   2057 back...
   2058 ---
   2059  lib/sup/buffer.rb |    1 +
   2060  1 files changed, 1 insertions(+), 0 deletions(-)
   2061 
   2062 diff --git a/lib/sup/buffer.rb b/lib/sup/buffer.rb
   2063 index b3a256f..09281e9 100644
   2064 --- a/lib/sup/buffer.rb
   2065 +++ b/lib/sup/buffer.rb
   2066 @@ -270,6 +270,7 @@ EOS
   2067  
   2068      ## this magic makes Ncurses get the new size of the screen
   2069      Ncurses.endwin
   2070 +    Ncurses.stdscr.keypad 1
   2071      Ncurses.refresh
   2072      @sigwinch_mutex.synchronize { @sigwinch_happened = false }
   2073      Redwood::log "new screen size is #{Ncurses.rows} x #{Ncurses.cols}"
   2074 -- 
   2075 1.6.3.3
   2076 -- 
   2077 A: Because it destroys the flow of conversation.
   2078 Q: Why is top posting dumb?
   2079 -------------- next part --------------
   2080 A non-text attachment was scrubbed...
   2081 Name: signature.asc
   2082 Type: application/pgp-signature
   2083 Size: 197 bytes
   2084 Desc: not available
   2085 URL: <http://rubyforge.org/pipermail/sup-talk/attachments/20090815/a67dfe70/attachment.bin>
   2086 
   2087 From cworth@cworth.org  Sat Aug 15 00:05:32 2009
   2088 From: cworth@cworth.org (Carl Worth)
   2089 Date: Fri, 14 Aug 2009 21:05:32 -0700
   2090 Subject: [sup-talk] Introduction, thanks, and a tiny patch
   2091 Message-ID: <1250307036-sup-8890@yoom>
   2092 
   2093 Hi. My name's Carl, and I've uh, been collecting email for 12 years.
   2094 
   2095 First off, I want to thank William and all contributors for sup! I
   2096 just started using it this morning, and I'm amazed by it. I've long
   2097 been frustrated by wrong-headed email systems, and also long been
   2098 dreaming of one done right, (entirely label-and-search-based and
   2099 focused on threads as the primary unit, bonus points if the UI is 100%
   2100 keyboard-driven and integrates with emacs). What a dream come true to
   2101 find sup!
   2102 
   2103 In my first use of sup, I was surprised by two things immediately:
   2104 
   2105    1. Most text is white-on-white (invisible) if the default terminal
   2106       background color is white. I would suggest that the default
   2107       background color be changed from "default" to "black" to avoid
   2108       this trap.
   2109 
   2110    2. All of the mail I imported from various maildir folders was
   2111       labelled as "unread", (in spite of the fact that a large
   2112       majority of it had the 'S' tag for "seen" in the maildir
   2113       filename). I tracked this down to my maildir filenames
   2114       containing ',' characters to the left of the ':' like so:
   2115 
   2116 1250158845.M979457P4354V000000000000FE01I001B8B56_0.yoom,S=46114:2,S
   2117 
   2118 I've attached a patch to fix this second issue, (a single-character
   2119 change).
   2120 
   2121 As for my involvement with sup, here are a couple of things I'd like
   2122 to help with:
   2123 
   2124    1. I love the NewUserGuide, but I've needed a ReferenceManual for
   2125       various issues already, (configuring colors, configuring SMTP,
   2126       understanding the sources.yaml file well enough to be able to
   2127       re-process mail that was mis-labelled the first time,
   2128       etc.).
   2129 
   2130       The wiki has been useful for much of this already, but I'd like
   2131       to have some of this information more cleanly organized, and
   2132       perhaps distributed as plain-text in alongside the user
   2133       guide. So I'd like to try pulling some existing information
   2134       together, organizing things, and also identifying missing
   2135       sections.
   2136 
   2137       One potential issue is that I don't see any explicit license
   2138       terms on the wiki. Can I assume that any text on the wiki is
   2139       suitable for putting into a document to be contributed to and
   2140       distributed with sup?
   2141 
   2142    2. I really like the ideas William has posted on his blog about
   2143       separating the interface from the guts of sup, (to make the new
   2144       STS). I'd be happy to help with that as well if possible.
   2145 
   2146 -Carl
   2147 -------------- next part --------------
   2148 A non-text attachment was scrubbed...
   2149 Name: 0001-maildir-Allow-in-the-unique-name-portion-of-a-maildi.patch
   2150 Type: application/octet-stream
   2151 Size: 1097 bytes
   2152 Desc: not available
   2153 URL: <http://rubyforge.org/pipermail/sup-talk/attachments/20090814/bb1094e7/attachment.obj>
   2154 -------------- next part --------------
   2155 A non-text attachment was scrubbed...
   2156 Name: signature.asc
   2157 Type: application/pgp-signature
   2158 Size: 235 bytes
   2159 Desc: not available
   2160 URL: <http://rubyforge.org/pipermail/sup-talk/attachments/20090814/bb1094e7/attachment.bin>
   2161 
   2162 From igor.brkic@fer.hr  Sat Aug 15 06:18:33 2009
   2163 From: igor.brkic@fer.hr (Igor Brkic)
   2164 Date: Sat, 15 Aug 2009 12:18:33 +0200
   2165 Subject: [sup-talk] Introduction, thanks, and a small patch
   2166 In-Reply-To: <20090815041446.GA1249@yoom.home.cworth.org>
   2167 References: <20090815041446.GA1249@yoom.home.cworth.org>
   2168 Message-ID: <1250331013-sup-3083@xps>
   2169 
   2170 Excerpts from Carl Worth's message of Sub Kol 15 06:14:46 +0200 2009:
   2171 > PS. I'm sending this message from mutt since sup crashed when I tried
   2172 > to send the message (see exception output below). I think this is one
   2173 
   2174 Hi Carl!
   2175 
   2176 I had same problem with sup. Sup actually manages to send message before
   2177 crashing and then it crashes when indexing sent messages.
   2178 
   2179 Solution that worked for me is to comment out line "Time.parse time, 0"
   2180 in mbox.rb file. This is not good solution, more like a hack, but for
   2181 some reason it works for me. Try it out.
   2182 
   2183 I tried to find out why this is happening, but I'm not so familiar with 
   2184 sup internals (and not so good in ruby too) and didn't come to any conclusion.
   2185 
   2186 Igor
   2187 
   2188 From marco-oweber@gmx.de  Sat Aug 15 07:03:00 2009
   2189 From: marco-oweber@gmx.de (Marc Weber)
   2190 Date: Sat, 15 Aug 2009 13:03:00 +0200
   2191 Subject: [sup-talk] Introduction, thanks, and a small patch
   2192 In-Reply-To: <20090815041446.GA1249@yoom.home.cworth.org>
   2193 References: <20090815041446.GA1249@yoom.home.cworth.org>
   2194 Message-ID: <1250334013-sup-3733@nixos>
   2195 
   2196 >    1. Most text is white-on-white (invisible) if the default terminal
   2197 >       background color is white. I would suggest that the default
   2198 >       background color be changed from "default" to "black" to avoid
   2199 >       this trap.
   2200 
   2201 The bg colour is set to black somewhere but for some reason it doesn't
   2202 work here. I've switched my terminal bg colour to light green so that I
   2203 can still read all text. It's a little bit annoying though. So if you
   2204 can tell me how to make sup background black I'd be happy.
   2205 
   2206 I haven't taken the time yet to investigate the issue.
   2207 
   2208 Sincerly
   2209 Marc Weber
   2210 
   2211 From cworth@cworth.org  Sat Aug 15 10:35:02 2009
   2212 From: cworth@cworth.org (Carl Worth)
   2213 Date: Sat, 15 Aug 2009 07:35:02 -0700
   2214 Subject: [sup-talk] Introduction, thanks, and a small patch
   2215 In-Reply-To: <1250331013-sup-3083@xps>
   2216 References: <20090815041446.GA1249@yoom.home.cworth.org>
   2217 	<1250331013-sup-3083@xps>
   2218 Message-ID: <1250346449-sup-6703@yoom>
   2219 
   2220 Excerpts from Igor Brkic's message of Sat Aug 15 03:18:33 -0700 2009:
   2221 > Hi Carl!
   2222 
   2223 Hi Igor!
   2224 
   2225 > I had same problem with sup. Sup actually manages to send message before
   2226 > crashing and then it crashes when indexing sent messages.
   2227 
   2228 Ah, yes. I did notice afterwards that my original message did make it
   2229 to the list. So sorry for all the noise, (though my first send of the
   2230 patch did have some debug junk in it, so I suppose it's good I sent a
   2231 cleaner version).
   2232 
   2233 > Solution that worked for me is to comment out line "Time.parse time, 0"
   2234 > in mbox.rb file. This is not good solution, more like a hack, but for
   2235 > some reason it works for me. Try it out.
   2236 
   2237 Thanks. I gave this a try, but it didn't work for me. I'm also not
   2238 much for debugging ruby so I haven't made much progress here yet. (Is
   2239 there anything like gdb for ruby? If I could just march up the stack
   2240 and more easily find where m.date should be initialized to non-nil
   2241 then that might help).
   2242 
   2243 But thanks for describing the bug more accurately for mo. At least
   2244 knowing that the crash is happening while indexing ~/.sup/sent.mb I
   2245 was able to just move that out of the way for now, so I can at least
   2246 run sup again.
   2247 
   2248 And actually, this brings up another point for that missing reference
   2249 manual. How can I configure sup to deliver sent messages to a maildir
   2250 instead of an mbox? (I'd prefer that anyway, and it just might
   2251 workaround this bug.)
   2252 
   2253 Thanks for the warm welcome,
   2254 
   2255 -Carl
   2256 -------------- next part --------------
   2257 A non-text attachment was scrubbed...
   2258 Name: signature.asc
   2259 Type: application/pgp-signature
   2260 Size: 189 bytes
   2261 Desc: not available
   2262 URL: <http://rubyforge.org/pipermail/sup-talk/attachments/20090815/849f4ac4/attachment.bin>
   2263 
   2264 From cworth@cworth.org  Sat Aug 15 10:41:51 2009
   2265 From: cworth@cworth.org (Carl Worth)
   2266 Date: Sat, 15 Aug 2009 07:41:51 -0700
   2267 Subject: [sup-talk] Introduction, thanks, and a small patch
   2268 In-Reply-To: <1250334013-sup-3733@nixos>
   2269 References: <20090815041446.GA1249@yoom.home.cworth.org>
   2270 	<1250334013-sup-3733@nixos>
   2271 Message-ID: <1250346921-sup-8888@yoom>
   2272 
   2273 Excerpts from Marc Weber's message of Sat Aug 15 04:03:00 -0700 2009:
   2274 > The bg colour is set to black somewhere but for some reason it doesn't
   2275 > work here. I've switched my terminal bg colour to light green so that I
   2276 > can still read all text. It's a little bit annoying though. So if you
   2277 > can tell me how to make sup background black I'd be happy.
   2278 > 
   2279 > I haven't taken the time yet to investigate the issue.
   2280 
   2281 I did my color configuration according to the following page:
   2282 
   2283 http://sup.rubyforge.org/wiki/wiki.pl?CustomizingColors
   2284 
   2285 That provides this very useful command which reads all the default
   2286 color settings and puts them into a configuration file that you can
   2287 easily edit:
   2288 
   2289 ruby -rubygems -rsup -e 'print Redwood::Colormap::DEFAULT_COLORS.to_yaml' > ~/.sup/colors.yaml
   2290 
   2291 You know, I don't think it would be a crazy idea for sup to
   2292 automatically dump that there on its first run. Or perhaps better,
   2293 sup-config could do it, (and could even ask if the user would prefer a
   2294 black-on-white or a white-on-black default color scheme).
   2295 
   2296 -Carl
   2297 -------------- next part --------------
   2298 A non-text attachment was scrubbed...
   2299 Name: signature.asc
   2300 Type: application/pgp-signature
   2301 Size: 189 bytes
   2302 Desc: not available
   2303 URL: <http://rubyforge.org/pipermail/sup-talk/attachments/20090815/e3d7b777/attachment.bin>
   2304 
   2305 From rlane@club.cc.cmu.edu  Sun Aug 16 15:35:30 2009
   2306 From: rlane@club.cc.cmu.edu (Rich Lane)
   2307 Date: Sun, 16 Aug 2009 12:35:30 -0700
   2308 Subject: [sup-talk] [PATCH 1/2] move all GDBM data into Xapian
   2309 Message-ID: <1250451331-16070-1-git-send-email-rlane@club.cc.cmu.edu>
   2310 
   2311 Keeping everything in Xapian means much better consistency in case of a crash.
   2312 Thread killing is now supported.
   2313 ---
   2314  lib/sup/xapian_index.rb |  177 +++++++++++++++++++++++++++++------------------
   2315  1 files changed, 110 insertions(+), 67 deletions(-)
   2316 
   2317 diff --git a/lib/sup/xapian_index.rb b/lib/sup/xapian_index.rb
   2318 index 861c2a3..825e7a3 100644
   2319 --- a/lib/sup/xapian_index.rb
   2320 +++ b/lib/sup/xapian_index.rb
   2321 @@ -1,5 +1,4 @@
   2322  require 'xapian'
   2323 -require 'gdbm'
   2324  require 'set'
   2325  
   2326  module Redwood
   2327 @@ -23,12 +22,6 @@ class XapianIndex < BaseIndex
   2328    end
   2329  
   2330    def load_index
   2331 -    @entries = MarshalledGDBM.new File.join(@dir, "entries.db")
   2332 -    @docids = MarshalledGDBM.new File.join(@dir, "docids.db")
   2333 -    @thread_members = MarshalledGDBM.new File.join(@dir, "thread_members.db")
   2334 -    @thread_ids = MarshalledGDBM.new File.join(@dir, "thread_ids.db")
   2335 -    @assigned_docids = GDBM.new File.join(@dir, "assigned_docids.db")
   2336 -
   2337      @xapian = Xapian::WritableDatabase.new(File.join(@dir, "xapian"), Xapian::DB_CREATE_OR_OPEN)
   2338      @term_generator = Xapian::TermGenerator.new()
   2339      @term_generator.stemmer = Xapian::Stem.new(STEM_LANGUAGE)
   2340 @@ -48,19 +41,19 @@ class XapianIndex < BaseIndex
   2341    end
   2342  
   2343    def contains_id? id
   2344 -    synchronize { @entries.member? id }
   2345 +    synchronize { find_docid(id) && true }
   2346    end
   2347  
   2348    def source_for_id id
   2349 -    synchronize { @entries[id][:source_id] }
   2350 +    synchronize { get_entry(id)[:source_id] }
   2351    end
   2352  
   2353    def delete id
   2354 -    synchronize { @xapian.delete_document @docids[id] }
   2355 +    synchronize { @xapian.delete_document mkterm(:msgid, id) }
   2356    end
   2357  
   2358    def build_message id
   2359 -    entry = synchronize { @entries[id] }
   2360 +    entry = synchronize { get_entry id }
   2361      return unless entry
   2362  
   2363      source = SourceManager[entry[:source_id]]
   2364 @@ -88,7 +81,7 @@ class XapianIndex < BaseIndex
   2365    end
   2366  
   2367    def sync_message m, opts={}
   2368 -    entry = synchronize { @entries[m.id] }
   2369 +    entry = synchronize { get_entry m.id }
   2370      snippet = m.snippet
   2371      entry ||= {}
   2372      labels = m.labels
   2373 @@ -113,9 +106,7 @@ class XapianIndex < BaseIndex
   2374      m.labels.each { |l| LabelManager << l }
   2375  
   2376      synchronize do
   2377 -      index_message m, opts
   2378 -      union_threads([m.id] + m.refs + m.replytos)
   2379 -      @entries[m.id] = d
   2380 +      index_message m, d, opts
   2381      end
   2382      true
   2383    end
   2384 @@ -147,8 +138,26 @@ class XapianIndex < BaseIndex
   2385    def each_message_in_thread_for m, opts={}
   2386      # TODO thread by subject
   2387      # TODO handle killed threads
   2388 -    ids = synchronize { @thread_members[@thread_ids[m.id]] } || []
   2389 -    ids.select { |id| contains_id? id }.each { |id| yield id, lambda { build_message id } }
   2390 +    return unless doc = find_doc(m.id)
   2391 +    queue = doc.value(THREAD_VALUENO).split(',')
   2392 +    msgids = [m.id]
   2393 +    seen_threads = Set.new
   2394 +    seen_messages = Set.new [m.id]
   2395 +    while not queue.empty?
   2396 +      thread_id = queue.pop
   2397 +      next if seen_threads.member? thread_id
   2398 +      return false if thread_killed? thread_id 
   2399 +      seen_threads << thread_id
   2400 +      docs = term_docids(mkterm(:thread, thread_id)).map { |x| @xapian.document x }
   2401 +      docs.each do |doc|
   2402 +        msgid = doc.value MSGID_VALUENO
   2403 +        next if seen_messages.member? msgid
   2404 +        msgids << msgid
   2405 +        seen_messages << msgid
   2406 +        queue.concat doc.value(THREAD_VALUENO).split(',')
   2407 +      end
   2408 +    end
   2409 +    msgids.each { |id| yield id, lambda { build_message id } }
   2410      true
   2411    end
   2412  
   2413 @@ -297,11 +306,16 @@ class XapianIndex < BaseIndex
   2414      'label' => 'L',
   2415      'source_id' => 'I',
   2416      'attachment_extension' => 'O',
   2417 +    'msgid' => 'Q',
   2418 +    'thread' => 'H',
   2419 +    'ref' => 'R',
   2420    }
   2421  
   2422    PREFIX = NORMAL_PREFIX.merge BOOLEAN_PREFIX
   2423  
   2424 -  DATE_VALUENO = 0
   2425 +  MSGID_VALUENO = 0
   2426 +  THREAD_VALUENO = 1
   2427 +  DATE_VALUENO = 2
   2428  
   2429    MAX_TERM_LENGTH = 245
   2430  
   2431 @@ -317,14 +331,48 @@ class XapianIndex < BaseIndex
   2432    def assign_docid m, truncated_date
   2433      t = (truncated_date.to_i - MIDDLE_DATE.to_i).to_f
   2434      docid = (DOCID_SCALE - DOCID_SCALE/(Math::E**(-(t/TIME_SCALE)) + 1)).to_i
   2435 +    while docid > 0 and docid_exists? docid
   2436 +      docid -= 1
   2437 +    end
   2438 +    docid > 0 ? docid : nil
   2439 +  end
   2440 +
   2441 +  # XXX is there a better way?
   2442 +  def docid_exists? docid
   2443      begin
   2444 -      while @assigned_docids.member? [docid].pack("N")
   2445 -        docid -= 1
   2446 -      end
   2447 -    rescue
   2448 +      @xapian.doclength docid
   2449 +      true
   2450 +    rescue RuntimeError #Xapian::DocNotFoundError
   2451 +      raise unless $!.message =~ /DocNotFoundError/
   2452 +      false
   2453      end
   2454 -    @assigned_docids[[docid].pack("N")] = ''
   2455 -    docid
   2456 +  end
   2457 +
   2458 +  def term_docids term
   2459 +    @xapian.postlist(term).map { |x| x.docid }
   2460 +  end
   2461 +
   2462 +  def find_docid id
   2463 +    term_docids(mkterm(:msgid,id)).tap { |x| fail unless x.size <= 1 }.first
   2464 +  end
   2465 +
   2466 +  def find_doc id
   2467 +    return unless docid = find_docid(id)
   2468 +    @xapian.document docid
   2469 +  end
   2470 +
   2471 +  def get_id docid
   2472 +    return unless doc = @xapian.document(docid)
   2473 +    doc.value MSGID_VALUENO
   2474 +  end
   2475 +
   2476 +  def get_entry id
   2477 +    return unless doc = find_doc(id)
   2478 +    Marshal.load doc.data
   2479 +  end
   2480 +
   2481 +  def thread_killed? thread_id
   2482 +    not run_query(Q.new(Q::OP_AND, mkterm(:thread, thread_id), mkterm(:label, :Killed)), 0, 1).empty?
   2483    end
   2484  
   2485    def synchronize &b
   2486 @@ -340,7 +388,7 @@ class XapianIndex < BaseIndex
   2487  
   2488    def run_query_ids xapian_query, offset, limit
   2489      matchset = run_query xapian_query, offset, limit
   2490 -    matchset.matches.map { |r| r.document.data }
   2491 +    matchset.matches.map { |r| r.document.value MSGID_VALUENO }
   2492    end
   2493  
   2494    Q = Xapian::Query
   2495 @@ -371,7 +419,7 @@ class XapianIndex < BaseIndex
   2496      end
   2497    end
   2498  
   2499 -  def index_message m, opts
   2500 +  def index_message m, entry, opts
   2501      terms = []
   2502      text = []
   2503  
   2504 @@ -394,6 +442,7 @@ class XapianIndex < BaseIndex
   2505      terms << mkterm(:date,m.date) if m.date
   2506      m.labels.each { |t| terms << mkterm(:label,t) }
   2507      terms << mkterm(:type, 'mail')
   2508 +    terms << mkterm(:msgid, m.id)
   2509      terms << mkterm(:source_id, m.source.id)
   2510      m.attachments.each do |a|
   2511        a =~ /\.(\w+)$/ or next
   2512 @@ -401,6 +450,23 @@ class XapianIndex < BaseIndex
   2513        terms << t
   2514      end
   2515  
   2516 +    ## Thread membership
   2517 +    children = term_docids(mkterm(:ref, m.id)).map { |docid| @xapian.document docid }
   2518 +    parent_ids = m.refs + m.replytos
   2519 +    parents = parent_ids.map { |id| find_doc id }.compact
   2520 +    thread_members = SavingHash.new { [] }
   2521 +    (children + parents).each do |doc2|
   2522 +      thread_ids = doc2.value(THREAD_VALUENO).split ','
   2523 +      thread_ids.each { |thread_id| thread_members[thread_id] << doc2 }
   2524 +    end
   2525 +
   2526 +    thread_ids = thread_members.empty? ? [m.id] : thread_members.keys
   2527 +
   2528 +    thread_ids.each { |thread_id| terms << mkterm(:thread, thread_id) }
   2529 +    parent_ids.each do |ref|
   2530 +      terms << mkterm(:ref, ref)
   2531 +    end
   2532 +
   2533      # Full text search content
   2534      text << [subject_text, PREFIX['subject']]
   2535      text << [subject_text, PREFIX['body']]
   2536 @@ -424,17 +490,29 @@ class XapianIndex < BaseIndex
   2537        Xapian.sortable_serialise 0
   2538      end
   2539  
   2540 -    doc = Xapian::Document.new
   2541 -    docid = @docids[m.id] || assign_docid(m, truncated_date)
   2542 +    docid = nil
   2543 +    unless doc = find_doc(m.id)
   2544 +      doc = Xapian::Document.new
   2545 +      if not docid = assign_docid(m, truncated_date)
   2546 +        # Could be triggered by spam
   2547 +        Redwood::log "warning: docid underflow, dropping #{m.id.inspect}"
   2548 +        return
   2549 +      end
   2550 +    else
   2551 +      doc.clear_terms
   2552 +      doc.clear_values
   2553 +      docid = doc.docid
   2554 +    end
   2555  
   2556      @term_generator.document = doc
   2557      text.each { |text,prefix| @term_generator.index_text text, 1, prefix }
   2558      terms.each { |term| doc.add_term term if term.length <= MAX_TERM_LENGTH }
   2559 +    doc.add_value MSGID_VALUENO, m.id
   2560 +    doc.add_value THREAD_VALUENO, (thread_ids * ',')
   2561      doc.add_value DATE_VALUENO, date_value
   2562 -    doc.data = m.id
   2563 +    doc.data = Marshal.dump entry
   2564  
   2565      @xapian.replace_document docid, doc
   2566 -    @docids[m.id] = docid
   2567    end
   2568  
   2569    # Construct a Xapian term
   2570 @@ -457,48 +535,13 @@ class XapianIndex < BaseIndex
   2571        PREFIX['source_id'] + args[0].to_s.downcase
   2572      when :attachment_extension
   2573        PREFIX['attachment_extension'] + args[0].to_s.downcase
   2574 +    when :msgid, :ref, :thread
   2575 +      PREFIX[type.to_s] + args[0][0...(MAX_TERM_LENGTH-1)]
   2576      else
   2577        raise "Invalid term type #{type}"
   2578      end
   2579    end
   2580  
   2581 -  # Join all the given message-ids into a single thread
   2582 -  def union_threads ids
   2583 -    seen_threads = Set.new
   2584 -    related = Set.new
   2585 -
   2586 -    # Get all the ids that will be in the new thread
   2587 -    ids.each do |id|
   2588 -      related << id
   2589 -      thread_id = @thread_ids[id]
   2590 -      if thread_id && !seen_threads.member?(thread_id)
   2591 -        thread_members = @thread_members[thread_id]
   2592 -        related.merge thread_members
   2593 -        seen_threads << thread_id
   2594 -      end
   2595 -    end
   2596 -
   2597 -    # Pick a leader and move all the others to its thread
   2598 -    a = related.to_a
   2599 -    best, *rest = a.sort_by { |x| x.hash }
   2600 -    @thread_members[best] = a
   2601 -    @thread_ids[best] = best
   2602 -    rest.each do |x|
   2603 -      @thread_members.delete x
   2604 -      @thread_ids[x] = best
   2605 -    end
   2606 -  end
   2607  end
   2608  
   2609  end
   2610 -
   2611 -class MarshalledGDBM < GDBM
   2612 -  def []= k, v
   2613 -    super k, Marshal.dump(v)
   2614 -  end
   2615 -
   2616 -  def [] k
   2617 -    v = super k
   2618 -    v ? Marshal.load(v) : nil
   2619 -  end
   2620 -end
   2621 -- 
   2622 1.6.4
   2623 
   2624 
   2625 From rlane@club.cc.cmu.edu  Sun Aug 16 15:35:31 2009
   2626 From: rlane@club.cc.cmu.edu (Rich Lane)
   2627 Date: Sun, 16 Aug 2009 12:35:31 -0700
   2628 Subject: [sup-talk] [PATCH 2/2] xapian index format versioning
   2629 In-Reply-To: <1250451331-16070-1-git-send-email-rlane@club.cc.cmu.edu>
   2630 References: <1250451331-16070-1-git-send-email-rlane@club.cc.cmu.edu>
   2631 Message-ID: <1250451331-16070-2-git-send-email-rlane@club.cc.cmu.edu>
   2632 
   2633 ---
   2634  lib/sup/xapian_index.rb |   13 ++++++++++++-
   2635  1 files changed, 12 insertions(+), 1 deletions(-)
   2636 
   2637 diff --git a/lib/sup/xapian_index.rb b/lib/sup/xapian_index.rb
   2638 index 825e7a3..c4989e4 100644
   2639 --- a/lib/sup/xapian_index.rb
   2640 +++ b/lib/sup/xapian_index.rb
   2641 @@ -8,6 +8,7 @@ module Redwood
   2642  # for searching due to precomputing thread membership.
   2643  class XapianIndex < BaseIndex
   2644    STEM_LANGUAGE = "english"
   2645 +  INDEX_VERSION = '1'
   2646  
   2647    ## dates are converted to integers for xapian, and are used for document ids,
   2648    ## so we must ensure they're reasonably valid. this typically only affect
   2649 @@ -22,7 +23,17 @@ class XapianIndex < BaseIndex
   2650    end
   2651  
   2652    def load_index
   2653 -    @xapian = Xapian::WritableDatabase.new(File.join(@dir, "xapian"), Xapian::DB_CREATE_OR_OPEN)
   2654 +    path = File.join(@dir, 'xapian')
   2655 +    if File.exists? path
   2656 +      @xapian = Xapian::WritableDatabase.new(path, Xapian::DB_OPEN)
   2657 +      db_version = @xapian.get_metadata 'version'
   2658 +      if db_version != INDEX_VERSION
   2659 +        fail "Index version #{db_version.inspect} is different than Sup version #{INDEX_VERSION.inspect}"
   2660 +      end
   2661 +    else
   2662 +      @xapian = Xapian::WritableDatabase.new(path, Xapian::DB_CREATE)
   2663 +      @xapian.set_metadata 'version', INDEX_VERSION
   2664 +    end
   2665      @term_generator = Xapian::TermGenerator.new()
   2666      @term_generator.stemmer = Xapian::Stem.new(STEM_LANGUAGE)
   2667      @enquire = Xapian::Enquire.new @xapian
   2668 -- 
   2669 1.6.4
   2670 
   2671 
   2672 From rlane@club.cc.cmu.edu  Sun Aug 16 15:35:59 2009
   2673 From: rlane@club.cc.cmu.edu (Rich Lane)
   2674 Date: Sun, 16 Aug 2009 12:35:59 -0700
   2675 Subject: [sup-talk] [PATCH] skip system buffers when rolling
   2676 Message-ID: <1250451359-16110-1-git-send-email-rlane@club.cc.cmu.edu>
   2677 
   2678 ---
   2679  lib/sup/buffer.rb |   16 +++++++++++-----
   2680  1 files changed, 11 insertions(+), 5 deletions(-)
   2681 
   2682 diff --git a/lib/sup/buffer.rb b/lib/sup/buffer.rb
   2683 index b3a256f..3fd2fe4 100644
   2684 --- a/lib/sup/buffer.rb
   2685 +++ b/lib/sup/buffer.rb
   2686 @@ -237,14 +237,20 @@ EOS
   2687    ## have to change this. but it's not clear that we will ever actually
   2688    ## do that.
   2689    def roll_buffers
   2690 -    @buffers.last.force_to_top = false
   2691 -    raise_to_front @buffers.first
   2692 +    bufs = rollable_buffers
   2693 +    bufs.last.force_to_top = false
   2694 +    raise_to_front bufs.first
   2695    end
   2696  
   2697    def roll_buffers_backwards
   2698 -    return unless @buffers.length > 1
   2699 -    @buffers.last.force_to_top = false
   2700 -    raise_to_front @buffers[@buffers.length - 2]
   2701 +    bufs = rollable_buffers
   2702 +    return unless bufs.length > 1
   2703 +    bufs.last.force_to_top = false
   2704 +    raise_to_front bufs[bufs.length - 2]
   2705 +  end
   2706 +
   2707 +  def rollable_buffers
   2708 +    @buffers.select { |b| !b.system? || @buffers.last == b }
   2709    end
   2710  
   2711    def handle_input c
   2712 -- 
   2713 1.6.4
   2714 
   2715 
   2716 From rlane@club.cc.cmu.edu  Sun Aug 16 15:36:08 2009
   2717 From: rlane@club.cc.cmu.edu (Rich Lane)
   2718 Date: Sun, 16 Aug 2009 12:36:08 -0700
   2719 Subject: [sup-talk] [PATCH] add 'I' keybinding to raise Inbox buffer
   2720 Message-ID: <1250451368-16150-1-git-send-email-rlane@club.cc.cmu.edu>
   2721 
   2722 ---
   2723  bin/sup |    3 +++
   2724  1 files changed, 3 insertions(+), 0 deletions(-)
   2725 
   2726 diff --git a/bin/sup b/bin/sup
   2727 index a9f0b95..d1eb163 100755
   2728 --- a/bin/sup
   2729 +++ b/bin/sup
   2730 @@ -78,6 +78,7 @@ global_keymap = Keymap.new do |k|
   2731    k.add :compose, "Compose new message", 'm', 'c'
   2732    k.add :nothing, "Do nothing", :ctrl_g
   2733    k.add :recall_draft, "Edit most recent draft message", 'R'
   2734 +  k.add :show_inbox, "Show the Inbox buffer", 'I'
   2735  end
   2736  
   2737  ## the following magic enables wide characters when used with a ruby
   2738 @@ -286,6 +287,8 @@ begin
   2739          b, new = BufferManager.spawn_unless_exists("All drafts") { LabelSearchResultsMode.new [:draft] }
   2740          b.mode.load_threads :num => b.content_height if new
   2741        end
   2742 +    when :show_inbox
   2743 +      BufferManager.raise_to_front ibuf
   2744      when :nothing, InputSequenceAborted
   2745      when :redraw
   2746        bm.completely_redraw_screen
   2747 -- 
   2748 1.6.4
   2749 
   2750 
   2751 From dato@net.com.org.es  Sun Aug 16 16:01:16 2009
   2752 From: dato@net.com.org.es (Adeodato =?utf-8?B?U2ltw7M=?=)
   2753 Date: Sun, 16 Aug 2009 21:01:16 +0100
   2754 Subject: [sup-talk] [PATCH 2/2] xapian index format versioning
   2755 In-Reply-To: <1250451331-16070-2-git-send-email-rlane@club.cc.cmu.edu>
   2756 References: <1250451331-16070-1-git-send-email-rlane@club.cc.cmu.edu>
   2757 	<1250451331-16070-2-git-send-email-rlane@club.cc.cmu.edu>
   2758 Message-ID: <20090816200116.GA17272@chistera.yi.org>
   2759 
   2760 + Rich Lane (Sun, 16 Aug 2009 12:35:31 -0700):
   2761 
   2762 > + fail "Index version #{db_version.inspect} is different than Sup
   2763 > version #{INDEX_VERSION.inspect}"
   2764 
   2765 The second part of the sentence seems to refer to Sup's version itself,
   2766 rather than what it really means (the index version expected by the
   2767 running version of Sup).
   2768 
   2769 Maybe the following wording could work better?
   2770 
   2771   | This Sup version expects a v#{INDEX_VERSION.inspect} index, whereas
   2772   | v#{db_version.inspect} is in the filesystem.
   2773 
   2774 (And, perhaps, suggesting what to do next would be grea too.)
   2775 
   2776 HTH,
   2777 
   2778 -- 
   2779 - Are you sure we're good?
   2780 - Always.
   2781         -- Rory and Lorelai
   2782 
   2783 
   2784 From rlane@club.cc.cmu.edu  Sun Aug 16 16:28:56 2009
   2785 From: rlane@club.cc.cmu.edu (Rich Lane)
   2786 Date: Sun, 16 Aug 2009 16:28:56 -0400
   2787 Subject: [sup-talk] [PATCH 2/2] xapian index format versioning
   2788 In-Reply-To: <20090816200116.GA17272@chistera.yi.org>
   2789 References: <1250451331-16070-1-git-send-email-rlane@club.cc.cmu.edu>
   2790 	<1250451331-16070-2-git-send-email-rlane@club.cc.cmu.edu>
   2791 	<20090816200116.GA17272@chistera.yi.org>
   2792 Message-ID: <1250453934-sup-9651@zyrg.net>
   2793 
   2794 ---
   2795 How's this wording?
   2796 
   2797 I've been thinking about a label log that would store every label
   2798 modification along with the timestamp, etc. This would make the awkward
   2799 downgrade-dump-upgrade step unnecessary. We could also flush it to disk
   2800 more often than the full index.
   2801 
   2802  lib/sup/xapian_index.rb |   14 +++++++++++++-
   2803  1 files changed, 13 insertions(+), 1 deletions(-)
   2804 
   2805 diff --git a/lib/sup/xapian_index.rb b/lib/sup/xapian_index.rb
   2806 index 825e7a3..18b5050 100644
   2807 --- a/lib/sup/xapian_index.rb
   2808 +++ b/lib/sup/xapian_index.rb
   2809 @@ -8,6 +8,7 @@ module Redwood
   2810  # for searching due to precomputing thread membership.
   2811  class XapianIndex < BaseIndex
   2812    STEM_LANGUAGE = "english"
   2813 +  INDEX_VERSION = '1'
   2814  
   2815    ## dates are converted to integers for xapian, and are used for document ids,
   2816    ## so we must ensure they're reasonably valid. this typically only affect
   2817 @@ -22,7 +23,18 @@ class XapianIndex < BaseIndex
   2818    end
   2819  
   2820    def load_index
   2821 -    @xapian = Xapian::WritableDatabase.new(File.join(@dir, "xapian"), Xapian::DB_CREATE_OR_OPEN)
   2822 +    path = File.join(@dir, 'xapian')
   2823 +    if File.exists? path
   2824 +      @xapian = Xapian::WritableDatabase.new(path, Xapian::DB_OPEN)
   2825 +      db_version = @xapian.get_metadata 'version'
   2826 +      db_version = '0' if db_version.empty?
   2827 +      if db_version != INDEX_VERSION
   2828 +        fail "This Sup version expects a v#{INDEX_VERSION} index, but you have an existing v#{db_version} index. Please downgrade to your previous version and dump your labels before upgrading to this version (then run sup-sync --restore)."
   2829 +      end
   2830 +    else
   2831 +      @xapian = Xapian::WritableDatabase.new(path, Xapian::DB_CREATE)
   2832 +      @xapian.set_metadata 'version', INDEX_VERSION
   2833 +    end
   2834      @term_generator = Xapian::TermGenerator.new()
   2835      @term_generator.stemmer = Xapian::Stem.new(STEM_LANGUAGE)
   2836      @enquire = Xapian::Enquire.new @xapian
   2837 -- 
   2838 1.6.4
   2839 
   2840 From wmorgan-sup@masanjin.net  Sun Aug 16 17:22:56 2009
   2841 From: wmorgan-sup@masanjin.net (William Morgan)
   2842 Date: Sun, 16 Aug 2009 14:22:56 -0700
   2843 Subject: [sup-talk] Introduction, thanks, and a small patch
   2844 In-Reply-To: <1250331013-sup-3083@xps>
   2845 References: <20090815041446.GA1249@yoom.home.cworth.org>
   2846 	<1250331013-sup-3083@xps>
   2847 Message-ID: <1250456575-sup-4326@masanjin.net>
   2848 
   2849 Reformatted excerpts from Igor Brkic's message of 2009-08-15:
   2850 > Solution that worked for me is to comment out line "Time.parse time,
   2851 > 0" in mbox.rb file. This is not good solution, more like a hack, but
   2852 > for some reason it works for me. Try it out.
   2853 
   2854 I've think I've fixed this in master. Thanks for your log; that was
   2855 helpful. The problem was that Sup was producing the date component of
   2856 the From_ lines in the sent mail mbox using the current locale, and
   2857 later on wouldn't necessarily recognize that as a date. (Particularly
   2858 for people with "funny locales".)
   2859 
   2860 You will have to manually edit your ~/.sup/sent.mbox file and change all
   2861 the From_ line dates that are not in UTC to UTC. If there are just a
   2862 couple, you should be able to copy and paste from the Date: header a few
   2863 lines below.
   2864 
   2865 Removing the Time.parse line you mention will work, but it has the side
   2866 effect of potentially splitting mbox files in mid-message. E.g. if you
   2867 ever have a line of text like "From xxx yyy\n", Sup will consider that
   2868 a message delimiter. This is fallout from the great mbox From_ line
   2869 misdesign of 1972.
   2870 
   2871 Please let me know if it works for you.
   2872 -- 
   2873 William <wmorgan-sup at masanjin.net>
   2874 
   2875 From wmorgan-sup@masanjin.net  Sun Aug 16 17:38:31 2009
   2876 From: wmorgan-sup@masanjin.net (William Morgan)
   2877 Date: Sun, 16 Aug 2009 14:38:31 -0700
   2878 Subject: [sup-talk] Introduction, thanks, and a small patch
   2879 In-Reply-To: <20090815041446.GA1249@yoom.home.cworth.org>
   2880 References: <20090815041446.GA1249@yoom.home.cworth.org>
   2881 Message-ID: <1250457809-sup-6784@masanjin.net>
   2882 
   2883 Reformatted excerpts from Carl Worth's message of 2009-08-14:
   2884 > Hi. My name's Carl, and I've uh, been collecting email for 12 years.
   2885 
   2886 Hi Carl! Welcome.
   2887 
   2888 > 1. Most text is white-on-white (invisible) if the default terminal
   2889 >    background color is white. I would suggest that the default
   2890 >    background color be changed from "default" to "black" to avoid
   2891 >    this trap.
   2892 
   2893 Complaining about the colors already? You're fitting right in around
   2894 here.
   2895 
   2896 We recently changed it from black to default in order to make it work
   2897 for people with transparent terminals. Since there's clearly not a
   2898 setting that works for everyone, I think the best solution is your
   2899 suggestion in a later email: provide a few reasonable color schemes
   2900 directly in sup-sync.
   2901 
   2902 > I've attached a patch to fix this second issue, (a single-character
   2903 > change).
   2904 
   2905 Great, thanks. The patch looks good but I think you left a debugging
   2906 puts call in there. If you want to resubmit,  I will apply this.
   2907 
   2908 > I love the NewUserGuide, but I've needed a ReferenceManual for various
   2909 > issues already, (configuring colors, configuring SMTP, understanding
   2910 > the sources.yaml file well enough to be able to re-process mail that
   2911 > was mis-labelled the first time, etc.).
   2912 
   2913 Agree. This would be very valuable and is currently a sore spot, IMO.
   2914 
   2915 > One potential issue is that I don't see any explicit license terms on
   2916 > the wiki. Can I assume that any text on the wiki is suitable for
   2917 > putting into a document to be contributed to and distributed with sup?
   2918 
   2919 I think it's fair to assume that anyone contributing to a wiki for an
   2920 open-source product knows what they're getting into. So, yes.
   2921 
   2922 Of course, if anyone objects to their wiki content being distributed as
   2923 part of Sup (which is currently distributed under GPL v2), please speak
   2924 now!
   2925 
   2926 > I really like the ideas William has posted on his blog about
   2927 > separating the interface from the guts of sup, (to make the new STS).
   2928 > I'd be happy to help with that as well if possible.
   2929 
   2930 Although it's been over a year of vaporware promises, this is slowly
   2931 happening. I have a protocol defined and a simple server written. Recent
   2932 work on replacing Ferret with Xapian has actually been helpful in terms
   2933 of moving us away from Ferretisms. Expect something "soon".
   2934 
   2935 > NoMethodError from thread: main
   2936 > undefined method `to_indexable_s' for nil:NilClass
   2937 
   2938 This should now be fixed in git master; see my previous email in this
   2939 thread. (You will have to manually edit your sent.mbox a bit.)
   2940 -- 
   2941 William <wmorgan-sup at masanjin.net>
   2942 
   2943 From wmorgan-sup@masanjin.net  Sun Aug 16 17:43:03 2009
   2944 From: wmorgan-sup@masanjin.net (William Morgan)
   2945 Date: Sun, 16 Aug 2009 14:43:03 -0700
   2946 Subject: [sup-talk] Stack overflow in regexp matcher
   2947 In-Reply-To: <92457f310908120145n453d6639mf22fe68b62054392@mail.gmail.com>
   2948 References: <92457f310908030116k146a901aleee95a09db907d97@mail.gmail.com>
   2949 	<1250021966-sup-933@masanjin.net>
   2950 	<92457f310908120145n453d6639mf22fe68b62054392@mail.gmail.com>
   2951 Message-ID: <1250458792-sup-9177@masanjin.net>
   2952 
   2953 Reformatted excerpts from Mark Drayton's message of 2009-08-12:
   2954 > The line it's choking on is 284058 bytes long and contains ~6400
   2955 > addresses. (gotta love mail from "internal communications").
   2956 
   2957 Wow!
   2958 
   2959 > If I halve the number of addresses it works, so perhaps this isn't
   2960 > worth fixing at all. If you do want to tackle it I'm happy to help
   2961 > off-list.
   2962 
   2963 Well... it's clearly a weird case, but it would be nice to do something
   2964 besides barf. I suppose we could detect very long lines, emit a warning,
   2965 and just parse the first few kb. What do you think?
   2966 -- 
   2967 William <wmorgan-sup at masanjin.net>
   2968 
   2969 From wmorgan-sup@masanjin.net  Sun Aug 16 17:44:49 2009
   2970 From: wmorgan-sup@masanjin.net (William Morgan)
   2971 Date: Sun, 16 Aug 2009 14:44:49 -0700
   2972 Subject: [sup-talk] some internal api refactors
   2973 In-Reply-To: <1250054282-sup-9053@pion.club.cc.cmu.edu>
   2974 References: <1250021119-sup-4253@masanjin.net>
   2975 	<1250054282-sup-9053@pion.club.cc.cmu.edu>
   2976 Message-ID: <1250459019-sup-6390@masanjin.net>
   2977 
   2978 Reformatted excerpts from Rich Lane's message of 2009-08-11:
   2979 > It's worth noting that update_message_state needs to handle modified
   2980 > refs and snippets as well as labels. Maybe add a comment about this in
   2981 > BaseIndex?
   2982 
   2983 Different snippet, definitely. Good point. Modified refs: I'm tempted to
   2984 replace this with another API call, since we don't really care about the
   2985 refs; we just want the index to thread the messages together. Thoughts?
   2986 -- 
   2987 William <wmorgan-sup at masanjin.net>
   2988 
   2989 From wmorgan-sup@masanjin.net  Sun Aug 16 18:00:50 2009
   2990 From: wmorgan-sup@masanjin.net (William Morgan)
   2991 Date: Sun, 16 Aug 2009 15:00:50 -0700
   2992 Subject: [sup-talk] [PATCH] Restore keypad mode after we force ncurses
   2993 	to refresh the whole screen.
   2994 In-Reply-To: <1250291137-sup-2796@localdomain>
   2995 References: <1250022259-sup-8328@masanjin.net>
   2996 	<1250028581-15826-2-git-send-email-benoit.pierre@gmail.com>
   2997 	<1250281039-sup-2788@masanjin.net>
   2998 	<1250289386-sup-7331@localdomain> <1250291137-sup-2796@localdomain>
   2999 Message-ID: <1250460036-sup-9343@masanjin.net>
   3000 
   3001 Reformatted excerpts from Beno?t PIERRE's message of 2009-08-14:
   3002 > This also happen to fix a regression after a call to run-mailcap,
   3003 > since for some reason a screen resize event is triggered when we get
   3004 > control back...
   3005 
   3006 Applied to ncurses-fixes, merged into next. Thanks!
   3007 -- 
   3008 William <wmorgan-sup at masanjin.net>
   3009 
   3010 From kevinr@free-dissociation.com  Sun Aug 16 17:47:09 2009
   3011 From: kevinr@free-dissociation.com (Kevin Riggle)
   3012 Date: Sun, 16 Aug 2009 17:47:09 -0400
   3013 Subject: [sup-talk] [PATCH] Add an after-add-message hook
   3014 Message-ID: <1250459229-4500-1-git-send-email-kevinr@free-dissociation.com>
   3015 
   3016 From: Kevin Riggle <kevinr at black-opal.mit.edu>
   3017 
   3018 I want to do some unrelated processing on each message I receive, but I
   3019 don't want to block the message being added to the index.  This patch
   3020 adds a hook which runs /after/ the message is added to the index.
   3021 ---
   3022  lib/sup/poll.rb |    7 +++++++
   3023  1 files changed, 7 insertions(+), 0 deletions(-)
   3024 
   3025 diff --git a/lib/sup/poll.rb b/lib/sup/poll.rb
   3026 index 8a9d218..e4b7e02 100644
   3027 --- a/lib/sup/poll.rb
   3028 +++ b/lib/sup/poll.rb
   3029 @@ -11,6 +11,12 @@ Variables:
   3030    message: the new message
   3031  EOS
   3032  
   3033 +  HookManager.register "after-add-message", <<EOS
   3034 +Executes after a message is added to the index.
   3035 +Variables:
   3036 +  message: the new message
   3037 +EOS
   3038 +
   3039    HookManager.register "before-poll", <<EOS
   3040  Executes immediately before a poll for new messages commences.
   3041  No variables.
   3042 @@ -156,6 +162,7 @@ EOS
   3043          m_ret = yield(m_old, m_new, offset) or next if block_given?
   3044          Index.sync_message m_ret, opts
   3045          UpdateManager.relay self, :added, m_ret unless m_old
   3046 +        HookManager.run "after-add-message", :message => m_new
   3047        end
   3048      rescue SourceError => e
   3049        Redwood::log "problem getting messages from #{source}: #{e.message}"
   3050 -- 
   3051 1.6.0.4
   3052 
   3053 
   3054 From rlane@club.cc.cmu.edu  Sun Aug 16 18:49:24 2009
   3055 From: rlane@club.cc.cmu.edu (Rich Lane)
   3056 Date: Sun, 16 Aug 2009 18:49:24 -0400
   3057 Subject: [sup-talk] some internal api refactors
   3058 In-Reply-To: <1250459019-sup-6390@masanjin.net>
   3059 References: <1250021119-sup-4253@masanjin.net>
   3060 	<1250054282-sup-9053@pion.club.cc.cmu.edu>
   3061 	<1250459019-sup-6390@masanjin.net>
   3062 Message-ID: <1250461358-sup-7209@zyrg.net>
   3063 
   3064 Excerpts from William Morgan's message of Sun Aug 16 17:44:49 -0400 2009:
   3065 > Reformatted excerpts from Rich Lane's message of 2009-08-11:
   3066 > > It's worth noting that update_message_state needs to handle modified
   3067 > > refs and snippets as well as labels. Maybe add a comment about this in
   3068 > > BaseIndex?
   3069 > 
   3070 > Different snippet, definitely. Good point. Modified refs: I'm tempted to
   3071 > replace this with another API call, since we don't really care about the
   3072 > refs; we just want the index to thread the messages together. Thoughts?
   3073 
   3074 The ThreadSet still needs the ref to do the UI-level threading, right?
   3075 Making it another API call is good as long as that's still taken care of.
   3076 
   3077 From igor.brkic@fer.hr  Sun Aug 16 19:18:22 2009
   3078 From: igor.brkic@fer.hr (Igor Brkic)
   3079 Date: Mon, 17 Aug 2009 01:18:22 +0200
   3080 Subject: [sup-talk] Introduction, thanks, and a small patch
   3081 In-Reply-To: <1250456575-sup-4326@masanjin.net>
   3082 References: <20090815041446.GA1249@yoom.home.cworth.org>
   3083 	<1250331013-sup-3083@xps> <1250456575-sup-4326@masanjin.net>
   3084 Message-ID: <1250464611-sup-5505@xps>
   3085 
   3086 Excerpts from William Morgan's message of Sun Aug 16 23:22:56 +0200 2009:
   3087 > I've think I've fixed this in master. Thanks for your log; that was
   3088 > helpful. The problem was that Sup was producing the date component of
   3089 > the From_ lines in the sent mail mbox using the current locale, and
   3090 > later on wouldn't necessarily recognize that as a date. (Particularly
   3091 > for people with "funny locales".)
   3092 > 
   3093 > ...
   3094 > 
   3095 > Please let me know if it works for you.
   3096 
   3097 I've made changes and for now it works like a charm. Thanks!
   3098 
   3099 Igor
   3100 
   3101 From rlane@club.cc.cmu.edu  Mon Aug 17 02:38:43 2009
   3102 From: rlane@club.cc.cmu.edu (Rich Lane)
   3103 Date: Sun, 16 Aug 2009 23:38:43 -0700
   3104 Subject: [sup-talk] [PATCH] index log
   3105 Message-ID: <1250491123-19240-1-git-send-email-rlane@club.cc.cmu.edu>
   3106 
   3107 Add a YAML logfile that records changes to the index and modify sup-dump to use
   3108 this rather than the normal database. The log is index format/version agnostic
   3109 so that users can switch between incompatible Sup versions without running
   3110 sup-dump first.
   3111 
   3112 This should also make automated backups easier.
   3113 ---
   3114  bin/sup-dump            |   19 +++++++++++++------
   3115  lib/sup/ferret_index.rb |    7 +++++++
   3116  lib/sup/index.rb        |   22 ++++++++++++++++++++++
   3117  lib/sup/xapian_index.rb |    7 ++++++-
   3118  lib/sup/yaml_log.rb     |   25 +++++++++++++++++++++++++
   3119  5 files changed, 73 insertions(+), 7 deletions(-)
   3120  create mode 100644 lib/sup/yaml_log.rb
   3121 
   3122 diff --git a/bin/sup-dump b/bin/sup-dump
   3123 index ba36b21..531a30a 100755
   3124 --- a/bin/sup-dump
   3125 +++ b/bin/sup-dump
   3126 @@ -2,7 +2,8 @@
   3127  
   3128  require 'rubygems'
   3129  require 'trollop'
   3130 -require "sup"
   3131 +require 'sup' # Redwood::VERSION, Redwood::BASE_DIR
   3132 +require "sup/yaml_log"
   3133  
   3134  $opts = Trollop::options do
   3135    version "sup-dump (sup #{Redwood::VERSION})"
   3136 @@ -21,10 +22,16 @@ No options.
   3137  EOS
   3138  end
   3139  
   3140 -index = Redwood::Index.new
   3141 -Redwood::SourceManager.new
   3142 -index.load
   3143 +labels = {}
   3144  
   3145 -index.each_message :load_spam => true, :load_deleted => true, :load_killed => true do |m|
   3146 -  puts "#{m.id} (#{m.labels * ' '})"
   3147 +Redwood::log "processing index log"
   3148 +index_log = YamlLogReader.new File.join(Redwood::BASE_DIR, 'index_log.yaml')
   3149 +index_log.each do |h| 
   3150 +  case h['type']
   3151 +  when 'add_message', 'update_message_state'
   3152 +    labels[h['id']] = h['labels']
   3153 +  end
   3154  end
   3155 +
   3156 +Redwood::log "dumping labels"
   3157 +labels.each { |msgid,labels| puts "#{msgid} (#{labels * ' '})" }
   3158 diff --git a/lib/sup/ferret_index.rb b/lib/sup/ferret_index.rb
   3159 index 98ea9b5..2cb9759 100644
   3160 --- a/lib/sup/ferret_index.rb
   3161 +++ b/lib/sup/ferret_index.rb
   3162 @@ -57,6 +57,7 @@ EOS
   3163  
   3164    def sync_message m, opts={}
   3165      entry = @index[m.id]
   3166 +    existed = !entry.nil?
   3167  
   3168      raise "no source info for message #{m.id}" unless m.source && m.source_info
   3169  
   3170 @@ -131,6 +132,12 @@ EOS
   3171      }
   3172  
   3173      @index_mutex.synchronize do
   3174 +      if existed
   3175 +        @log.update_message_state m.id, m.labels
   3176 +      else
   3177 +        @log.add_message m.id, m.labels
   3178 +      end
   3179 +
   3180        @index.delete m.id
   3181        @index.add_document d
   3182      end
   3183 diff --git a/lib/sup/index.rb b/lib/sup/index.rb
   3184 index 54ec843..7360cf5 100644
   3185 --- a/lib/sup/index.rb
   3186 +++ b/lib/sup/index.rb
   3187 @@ -1,6 +1,7 @@
   3188  ## Index interface, subclassed by Ferret indexer.
   3189  
   3190  require 'fileutils'
   3191 +require 'sup/yaml_log'
   3192  
   3193  begin
   3194    require 'chronic'
   3195 @@ -65,6 +66,7 @@ class BaseIndex
   3196  
   3197    def load
   3198      SourceManager.load_sources
   3199 +    @log = IndexLogWriter.new File.join(@dir, 'index_log.yaml')
   3200      load_index
   3201    end
   3202  
   3203 @@ -176,6 +178,26 @@ class BaseIndex
   3204    def parse_query s
   3205      unimplemented
   3206    end
   3207 +
   3208 +  private
   3209 +
   3210 +  class IndexLogWriter < YamlLogWriter
   3211 +    def update_message_state id, labels
   3212 +      write_entry 'update_message_state', 'id' => id, 'labels' => labels.map { |x| x.to_s }
   3213 +    end
   3214 +
   3215 +    def add_message id, labels
   3216 +      write_entry 'add_message', 'id' => id, 'labels' => labels.map { |x| x.to_s }
   3217 +    end
   3218 +
   3219 +    def remove_message id
   3220 +      write_entry 'remove_message', 'id' => id
   3221 +    end
   3222 +
   3223 +    def write_entry type, hash
   3224 +      self << hash.merge('type' => type, 'time' => Time.now)
   3225 +    end
   3226 +  end
   3227  end
   3228  
   3229  index_name = ENV['SUP_INDEX'] || $config[:index] || DEFAULT_INDEX
   3230 diff --git a/lib/sup/xapian_index.rb b/lib/sup/xapian_index.rb
   3231 index 18b5050..c4dbc5f 100644
   3232 --- a/lib/sup/xapian_index.rb
   3233 +++ b/lib/sup/xapian_index.rb
   3234 @@ -61,7 +61,10 @@ class XapianIndex < BaseIndex
   3235    end
   3236  
   3237    def delete id
   3238 -    synchronize { @xapian.delete_document mkterm(:msgid, id) }
   3239 +    synchronize do
   3240 +      @log.remove_message id
   3241 +      @xapian.delete_document mkterm(:msgid, id)
   3242 +    end
   3243    end
   3244  
   3245    def build_message id
   3246 @@ -510,10 +513,12 @@ class XapianIndex < BaseIndex
   3247          Redwood::log "warning: docid underflow, dropping #{m.id.inspect}"
   3248          return
   3249        end
   3250 +      @log.add_message m.id, m.labels
   3251      else
   3252        doc.clear_terms
   3253        doc.clear_values
   3254        docid = doc.docid
   3255 +      @log.update_message_state m.id, m.labels
   3256      end
   3257  
   3258      @term_generator.document = doc
   3259 diff --git a/lib/sup/yaml_log.rb b/lib/sup/yaml_log.rb
   3260 new file mode 100644
   3261 index 0000000..325cca9
   3262 --- /dev/null
   3263 +++ b/lib/sup/yaml_log.rb
   3264 @@ -0,0 +1,25 @@
   3265 +class YamlLogReader
   3266 +  include Enumerable
   3267 +
   3268 +  def initialize filename
   3269 +    @io = File.open(filename, 'r+')
   3270 +  end
   3271 +
   3272 +  def each &b
   3273 +    @io.rewind
   3274 +    YAML.each_document @io, &b
   3275 +  end
   3276 +end
   3277 +
   3278 +class YamlLogWriter
   3279 +  def initialize filename
   3280 +    @io = File.open(filename, 'a')
   3281 +  end
   3282 +
   3283 +  def <<(o)
   3284 +    YAML.dump o, @io
   3285 +
   3286 +    ## This only flushes to the OS. We may want to fsync occasionally too.
   3287 +    @io.flush
   3288 +  end
   3289 +end
   3290 -- 
   3291 1.6.4
   3292 
   3293 
   3294 From rlane@club.cc.cmu.edu  Mon Aug 17 02:39:11 2009
   3295 From: rlane@club.cc.cmu.edu (Rich Lane)
   3296 Date: Sun, 16 Aug 2009 23:39:11 -0700
   3297 Subject: [sup-talk] [PATCH 1/5] console mode
   3298 Message-ID: <1250491155-19281-1-git-send-email-rlane@club.cc.cmu.edu>
   3299 
   3300 ---
   3301  bin/sup                       |    4 +++
   3302  lib/sup.rb                    |    1 +
   3303  lib/sup/modes/console-mode.rb |   42 +++++++++++++++++++++++++++++++++++++++++
   3304  3 files changed, 47 insertions(+), 0 deletions(-)
   3305  create mode 100644 lib/sup/modes/console-mode.rb
   3306 
   3307 diff --git a/bin/sup b/bin/sup
   3308 index a9f0b95..1dc322a 100755
   3309 --- a/bin/sup
   3310 +++ b/bin/sup
   3311 @@ -78,6 +78,7 @@ global_keymap = Keymap.new do |k|
   3312    k.add :compose, "Compose new message", 'm', 'c'
   3313    k.add :nothing, "Do nothing", :ctrl_g
   3314    k.add :recall_draft, "Edit most recent draft message", 'R'
   3315 +  k.add :show_console, "Show the Console buffer", '~'
   3316  end
   3317  
   3318  ## the following magic enables wide characters when used with a ruby
   3319 @@ -286,6 +287,9 @@ begin
   3320          b, new = BufferManager.spawn_unless_exists("All drafts") { LabelSearchResultsMode.new [:draft] }
   3321          b.mode.load_threads :num => b.content_height if new
   3322        end
   3323 +    when :show_console
   3324 +      b, new = bm.spawn_unless_exists("Console", :system => true) { ConsoleMode.new }
   3325 +      b.mode.run
   3326      when :nothing, InputSequenceAborted
   3327      when :redraw
   3328        bm.completely_redraw_screen
   3329 diff --git a/lib/sup.rb b/lib/sup.rb
   3330 index cfa93fc..9e0c33a 100644
   3331 --- a/lib/sup.rb
   3332 +++ b/lib/sup.rb
   3333 @@ -295,6 +295,7 @@ require "sup/modes/buffer-list-mode"
   3334  require "sup/modes/poll-mode"
   3335  require "sup/modes/file-browser-mode"
   3336  require "sup/modes/completion-mode"
   3337 +require "sup/modes/console-mode"
   3338  require "sup/sent"
   3339  
   3340  $:.each do |base|
   3341 diff --git a/lib/sup/modes/console-mode.rb b/lib/sup/modes/console-mode.rb
   3342 new file mode 100644
   3343 index 0000000..d06d37b
   3344 --- /dev/null
   3345 +++ b/lib/sup/modes/console-mode.rb
   3346 @@ -0,0 +1,42 @@
   3347 +require 'pp'
   3348 +
   3349 +module Redwood
   3350 +
   3351 +class Console
   3352 +  def initialize mode
   3353 +    @mode = mode
   3354 +  end
   3355 +end
   3356 +
   3357 +class ConsoleMode < LogMode
   3358 +  def initialize
   3359 +    super
   3360 +    @binding = Console.new(self).instance_eval { binding }
   3361 +  end
   3362 +
   3363 +  def execute cmd
   3364 +    begin
   3365 +      self << ">> #{cmd}\n"
   3366 +      ret = eval cmd, @binding
   3367 +      self << "=> #{ret.pretty_inspect}\n"
   3368 +    rescue Exception
   3369 +      self << "#{$!.class}: #{$!.message}\n"
   3370 +      clean_backtrace = []
   3371 +      $!.backtrace.each { |l| break if l =~ /console-mode/; clean_backtrace << l }
   3372 +      clean_backtrace.each { |l| self << "#{l}\n" }
   3373 +    end
   3374 +  end
   3375 +
   3376 +  def prompt
   3377 +    BufferManager.ask :console, "eval: "
   3378 +  end
   3379 +
   3380 +  def run
   3381 +    while true
   3382 +      cmd = prompt or return
   3383 +      execute cmd
   3384 +    end
   3385 +  end
   3386 +end
   3387 +
   3388 +end
   3389 -- 
   3390 1.6.4
   3391 
   3392 
   3393 From rlane@club.cc.cmu.edu  Mon Aug 17 02:39:13 2009
   3394 From: rlane@club.cc.cmu.edu (Rich Lane)
   3395 Date: Sun, 16 Aug 2009 23:39:13 -0700
   3396 Subject: [sup-talk] [PATCH 3/5] console: index internals accessor
   3397 In-Reply-To: <1250491155-19281-2-git-send-email-rlane@club.cc.cmu.edu>
   3398 References: <1250491155-19281-1-git-send-email-rlane@club.cc.cmu.edu>
   3399 	<1250491155-19281-2-git-send-email-rlane@club.cc.cmu.edu>
   3400 Message-ID: <1250491155-19281-3-git-send-email-rlane@club.cc.cmu.edu>
   3401 
   3402 ---
   3403  lib/sup/modes/console-mode.rb |    3 +++
   3404  1 files changed, 3 insertions(+), 0 deletions(-)
   3405 
   3406 diff --git a/lib/sup/modes/console-mode.rb b/lib/sup/modes/console-mode.rb
   3407 index a91bbbf..c794a4c 100644
   3408 --- a/lib/sup/modes/console-mode.rb
   3409 +++ b/lib/sup/modes/console-mode.rb
   3410 @@ -18,6 +18,9 @@ class Console
   3411    def remove_labels(query, *labels)
   3412      query(query).each { |m| m.labels -= labels; m.save Index }
   3413    end
   3414 +
   3415 +  def xapian; Index.instance.instance_variable_get :@xapian; end
   3416 +  def ferret; Index.instance.instance_variable_get :@index; end
   3417  end
   3418  
   3419  class ConsoleMode < LogMode
   3420 -- 
   3421 1.6.4
   3422 
   3423 
   3424 From rlane@club.cc.cmu.edu  Mon Aug 17 02:39:12 2009
   3425 From: rlane@club.cc.cmu.edu (Rich Lane)
   3426 Date: Sun, 16 Aug 2009 23:39:12 -0700
   3427 Subject: [sup-talk] [PATCH 2/5] console: add/remove labels
   3428 In-Reply-To: <1250491155-19281-1-git-send-email-rlane@club.cc.cmu.edu>
   3429 References: <1250491155-19281-1-git-send-email-rlane@club.cc.cmu.edu>
   3430 Message-ID: <1250491155-19281-2-git-send-email-rlane@club.cc.cmu.edu>
   3431 
   3432 ---
   3433  lib/sup/modes/console-mode.rb |   12 ++++++++++++
   3434  1 files changed, 12 insertions(+), 0 deletions(-)
   3435 
   3436 diff --git a/lib/sup/modes/console-mode.rb b/lib/sup/modes/console-mode.rb
   3437 index d06d37b..a91bbbf 100644
   3438 --- a/lib/sup/modes/console-mode.rb
   3439 +++ b/lib/sup/modes/console-mode.rb
   3440 @@ -6,6 +6,18 @@ class Console
   3441    def initialize mode
   3442      @mode = mode
   3443    end
   3444 +
   3445 +  def query(query)
   3446 +    Enumerable::Enumerator.new(Index, :each_message, Index.parse_query(query))
   3447 +  end
   3448 +
   3449 +  def add_labels(query, *labels)
   3450 +    query(query).each { |m| m.labels += labels; m.save Index }
   3451 +  end
   3452 +
   3453 +  def remove_labels(query, *labels)
   3454 +    query(query).each { |m| m.labels -= labels; m.save Index }
   3455 +  end
   3456  end
   3457  
   3458  class ConsoleMode < LogMode
   3459 -- 
   3460 1.6.4
   3461 
   3462 
   3463 From rlane@club.cc.cmu.edu  Mon Aug 17 02:39:14 2009
   3464 From: rlane@club.cc.cmu.edu (Rich Lane)
   3465 Date: Sun, 16 Aug 2009 23:39:14 -0700
   3466 Subject: [sup-talk] [PATCH 4/5] console: reload
   3467 In-Reply-To: <1250491155-19281-3-git-send-email-rlane@club.cc.cmu.edu>
   3468 References: <1250491155-19281-1-git-send-email-rlane@club.cc.cmu.edu>
   3469 	<1250491155-19281-2-git-send-email-rlane@club.cc.cmu.edu>
   3470 	<1250491155-19281-3-git-send-email-rlane@club.cc.cmu.edu>
   3471 Message-ID: <1250491155-19281-4-git-send-email-rlane@club.cc.cmu.edu>
   3472 
   3473 ---
   3474  lib/sup/modes/console-mode.rb |   30 ++++++++++++++++++++++++++++++
   3475  1 files changed, 30 insertions(+), 0 deletions(-)
   3476 
   3477 diff --git a/lib/sup/modes/console-mode.rb b/lib/sup/modes/console-mode.rb
   3478 index c794a4c..c344fa6 100644
   3479 --- a/lib/sup/modes/console-mode.rb
   3480 +++ b/lib/sup/modes/console-mode.rb
   3481 @@ -21,6 +21,36 @@ class Console
   3482  
   3483    def xapian; Index.instance.instance_variable_get :@xapian; end
   3484    def ferret; Index.instance.instance_variable_get :@index; end
   3485 +
   3486 +  ## files that won't cause problems when reloaded
   3487 +  ## TODO expand this list / convert to blacklist
   3488 +  RELOAD_WHITELIST = %w(sup/xapian_index.rb sup/modes/console-mode.rb)
   3489 +
   3490 +  def reload
   3491 +    old_verbose = $VERBOSE
   3492 +    $VERBOSE = nil
   3493 +    old_features = $".dup
   3494 +    begin
   3495 +      fs = $".grep(/^sup\//)
   3496 +      fs.reject! { |f| not RELOAD_WHITELIST.member? f }
   3497 +      fs.each { |f| $".delete f }
   3498 +      fs.each do |f|
   3499 +        @mode << "reloading #{f}\n"
   3500 +        begin
   3501 +          require f
   3502 +        rescue LoadError => e
   3503 +          raise unless e.message =~ /no such file to load/
   3504 +        end
   3505 +      end
   3506 +    rescue Exception
   3507 +      $".clear
   3508 +      $".concat old_features
   3509 +      raise
   3510 +    ensure
   3511 +      $VERBOSE = old_verbose
   3512 +    end
   3513 +    true
   3514 +  end
   3515  end
   3516  
   3517  class ConsoleMode < LogMode
   3518 -- 
   3519 1.6.4
   3520 
   3521 
   3522 From rlane@club.cc.cmu.edu  Mon Aug 17 02:39:15 2009
   3523 From: rlane@club.cc.cmu.edu (Rich Lane)
   3524 Date: Sun, 16 Aug 2009 23:39:15 -0700
   3525 Subject: [sup-talk] [PATCH 5/5] console: clear_hooks
   3526 In-Reply-To: <1250491155-19281-4-git-send-email-rlane@club.cc.cmu.edu>
   3527 References: <1250491155-19281-1-git-send-email-rlane@club.cc.cmu.edu>
   3528 	<1250491155-19281-2-git-send-email-rlane@club.cc.cmu.edu>
   3529 	<1250491155-19281-3-git-send-email-rlane@club.cc.cmu.edu>
   3530 	<1250491155-19281-4-git-send-email-rlane@club.cc.cmu.edu>
   3531 Message-ID: <1250491155-19281-5-git-send-email-rlane@club.cc.cmu.edu>
   3532 
   3533 ---
   3534  lib/sup/hook.rb               |    2 ++
   3535  lib/sup/modes/console-mode.rb |    5 +++++
   3536  2 files changed, 7 insertions(+), 0 deletions(-)
   3537 
   3538 diff --git a/lib/sup/hook.rb b/lib/sup/hook.rb
   3539 index 33a97b2..099158d 100644
   3540 --- a/lib/sup/hook.rb
   3541 +++ b/lib/sup/hook.rb
   3542 @@ -130,6 +130,8 @@ EOS
   3543  
   3544    def enabled? name; !hook_for(name).nil? end
   3545  
   3546 +  def clear; @hooks.clear; end
   3547 +
   3548  private
   3549  
   3550    def hook_for name
   3551 diff --git a/lib/sup/modes/console-mode.rb b/lib/sup/modes/console-mode.rb
   3552 index c344fa6..372a466 100644
   3553 --- a/lib/sup/modes/console-mode.rb
   3554 +++ b/lib/sup/modes/console-mode.rb
   3555 @@ -51,6 +51,11 @@ class Console
   3556      end
   3557      true
   3558    end
   3559 +
   3560 +  def clear_hooks
   3561 +    HookManager.clear
   3562 +    nil
   3563 +  end
   3564  end
   3565  
   3566  class ConsoleMode < LogMode
   3567 -- 
   3568 1.6.4
   3569 
   3570 
   3571 From rlane@club.cc.cmu.edu  Mon Aug 17 02:39:32 2009
   3572 From: rlane@club.cc.cmu.edu (Rich Lane)
   3573 Date: Sun, 16 Aug 2009 23:39:32 -0700
   3574 Subject: [sup-talk] [PATCH] cache results of Person.from_address
   3575 Message-ID: <1250491172-19317-1-git-send-email-rlane@club.cc.cmu.edu>
   3576 
   3577 The regexes in this function are very expensive, so caching improves
   3578 performance significantly for queries and slightly for indexing.
   3579 ---
   3580  lib/sup/cache.rb  |   46 ++++++++++++++++++++++++++++++++++++++++++++++
   3581  lib/sup/person.rb |    7 ++++++-
   3582  2 files changed, 52 insertions(+), 1 deletions(-)
   3583  create mode 100644 lib/sup/cache.rb
   3584 
   3585 diff --git a/lib/sup/cache.rb b/lib/sup/cache.rb
   3586 new file mode 100644
   3587 index 0000000..0836dbd
   3588 --- /dev/null
   3589 +++ b/lib/sup/cache.rb
   3590 @@ -0,0 +1,46 @@
   3591 +class Cache
   3592 +  def initialize n=128, i=3
   3593 +    @n = n
   3594 +    @i = i
   3595 +    @values = {}
   3596 +    @marks = {}
   3597 +    @delete_stack = []
   3598 +  end
   3599 +
   3600 +  def [](k)
   3601 +    if @values.member? k
   3602 +      @marks[k] = @i
   3603 +      @values[k]
   3604 +    else
   3605 +      nil
   3606 +    end
   3607 +  end
   3608 +
   3609 +  def []=(k,v)
   3610 +    if @values.size < @n
   3611 +      @values[k] = v
   3612 +      @marks[k] = @i
   3613 +    else
   3614 +      if @delete_stack.empty?
   3615 +        sweep
   3616 +      else
   3617 +        k2 = @delete_stack.pop
   3618 +        @values.delete k2
   3619 +        @marks.delete k2
   3620 +        self[k] = v
   3621 +      end
   3622 +    end
   3623 +  end
   3624 +
   3625 +  def sweep
   3626 +    @marks.each do |k,v|
   3627 +      v -= 1
   3628 +      if v == 0
   3629 +        @delete_stack.push k
   3630 +        @marks.delete k
   3631 +      else
   3632 +        @marks[k] = v
   3633 +      end
   3634 +    end
   3635 +  end
   3636 +end
   3637 diff --git a/lib/sup/person.rb b/lib/sup/person.rb
   3638 index c4f40a5..046eedc 100644
   3639 --- a/lib/sup/person.rb
   3640 +++ b/lib/sup/person.rb
   3641 @@ -1,3 +1,5 @@
   3642 +require 'sup/cache'
   3643 +
   3644  module Redwood
   3645  
   3646  class Person 
   3647 @@ -73,8 +75,11 @@ class Person
   3648      end.downcase
   3649    end
   3650  
   3651 +  ## This method is expensive, so memoize it.
   3652 +  @from_address_cache = Cache.new
   3653    def self.from_address s
   3654      return nil if s.nil?
   3655 +    @from_address_cache[s].tap { |x| return x if x }
   3656  
   3657      ## try and parse an email address and name
   3658      name, email = case s
   3659 @@ -102,7 +107,7 @@ class Person
   3660          [nil, s]
   3661        end
   3662  
   3663 -    Person.new name, email
   3664 +    @from_address_cache[s] = Person.new name, email
   3665    end
   3666  
   3667    def self.from_address_list ss
   3668 -- 
   3669 1.6.4
   3670 
   3671 
   3672 From taruti@taruti.net  Mon Aug 17 03:22:35 2009
   3673 From: taruti@taruti.net (Taru Karttunen)
   3674 Date: Mon, 17 Aug 2009 10:22:35 +0300
   3675 Subject: [sup-talk] Sup crashing
   3676 In-Reply-To: 1250281208-sup-4199 <1250281208-sup-4199@masanjin.net>
   3677 References: <1250148617-sup-6053@oz.taruti.net>
   3678 	<1250281208-sup-4199@masanjin.net>
   3679 Message-ID: <1250493725-sup-5683@oz.taruti.net>
   3680 
   3681 Excerpts from William Morgan's message of Fri Aug 14 23:20:28 +0300 2009:
   3682 > 
   3683 > Weird. Does sup-sync --optimize fix anything?
   3684 
   3685 Made things work again. Thanks.
   3686 
   3687 - Taru Karttunen
   3688 
   3689 From garoth@gmail.com  Mon Aug 17 09:07:25 2009
   3690 From: garoth@gmail.com (Andrei Thorp)
   3691 Date: Mon, 17 Aug 2009 09:07:25 -0400
   3692 Subject: [sup-talk] [PATCH] cache results of Person.from_address
   3693 In-Reply-To: <1250491172-19317-1-git-send-email-rlane@club.cc.cmu.edu>
   3694 References: <1250491172-19317-1-git-send-email-rlane@club.cc.cmu.edu>
   3695 Message-ID: <1250514421-sup-7564@Longbow>
   3696 
   3697 Just want to say thanks again for your seemingly unending amount of good
   3698 work to improve Sup.
   3699 -- 
   3700 Andrei Thorp, Developer: Xandros Corp. (http://www.xandros.com)
   3701 
   3702 From wmorgan-sup@masanjin.net  Mon Aug 17 10:01:10 2009
   3703 From: wmorgan-sup@masanjin.net (William Morgan)
   3704 Date: Mon, 17 Aug 2009 07:01:10 -0700
   3705 Subject: [sup-talk] Sup crashing
   3706 In-Reply-To: <1250493725-sup-5683@oz.taruti.net>
   3707 References: <1250148617-sup-6053@oz.taruti.net>
   3708 	<1250281208-sup-4199@masanjin.net>
   3709 	<1250493725-sup-5683@oz.taruti.net>
   3710 Message-ID: <1250517574-sup-940@masanjin.net>
   3711 
   3712 Reformatted excerpts from Taru Karttunen's message of 2009-08-17:
   3713 > Made things work again. Thanks.
   3714 
   3715 Good.  Let me know if it happens again. I'm not sure what would cause it
   3716 to get in that state.
   3717 -- 
   3718 William <wmorgan-sup at masanjin.net>
   3719 
   3720 From dato@net.com.org.es  Mon Aug 17 12:08:57 2009
   3721 From: dato@net.com.org.es (Adeodato =?utf-8?B?U2ltw7M=?=)
   3722 Date: Mon, 17 Aug 2009 17:08:57 +0100
   3723 Subject: [sup-talk] [PATCH 2/2] xapian index format versioning
   3724 In-Reply-To: <1250453934-sup-9651@zyrg.net>
   3725 References: <1250451331-16070-1-git-send-email-rlane@club.cc.cmu.edu>
   3726 	<1250451331-16070-2-git-send-email-rlane@club.cc.cmu.edu>
   3727 	<20090816200116.GA17272@chistera.yi.org>
   3728 	<1250453934-sup-9651@zyrg.net>
   3729 Message-ID: <20090817160857.GA2496@chistera.yi.org>
   3730 
   3731 + Rich Lane (Sun, 16 Aug 2009 16:28:56 -0400):
   3732 
   3733 > How's this wording?
   3734 
   3735 > + fail "This Sup version expects a v#{INDEX_VERSION} index, but you
   3736 > have an existing v#{db_version} index. Please downgrade to your
   3737 > previous version and dump your labels before upgrading to this version
   3738 > (then run sup-sync --restore)."
   3739 
   3740 Sounds much better, thanks!
   3741 
   3742 -- 
   3743 - Are you sure we're good?
   3744 - Always.
   3745         -- Rory and Lorelai
   3746 
   3747 
   3748 From wmorgan-sup@masanjin.net  Mon Aug 17 15:39:57 2009
   3749 From: wmorgan-sup@masanjin.net (William Morgan)
   3750 Date: Mon, 17 Aug 2009 12:39:57 -0700
   3751 Subject: [sup-talk] some internal api refactors
   3752 In-Reply-To: <1250461358-sup-7209@zyrg.net>
   3753 References: <1250021119-sup-4253@masanjin.net>
   3754 	<1250054282-sup-9053@pion.club.cc.cmu.edu>
   3755 	<1250459019-sup-6390@masanjin.net> <1250461358-sup-7209@zyrg.net>
   3756 Message-ID: <1250537445-sup-4504@masanjin.net>
   3757 
   3758 Reformatted excerpts from Rich Lane's message of 2009-08-16:
   3759 > The ThreadSet still needs the ref to do the UI-level threading, right?
   3760 > Making it another API call is good as long as that's still taken care
   3761 > of.
   3762 
   3763 I'm thinking about moving in the direction where the index is also
   3764 responsible for threading (so maybe "index" is not the right term
   3765 anymore), so the ThreadSet would just be a static representation of the
   3766 thread structure of a set of messages as returned by the index. We'll
   3767 see how it develops.
   3768 -- 
   3769 William <wmorgan-sup at masanjin.net>
   3770 
   3771 From wmorgan-sup@masanjin.net  Mon Aug 17 15:50:52 2009
   3772 From: wmorgan-sup@masanjin.net (William Morgan)
   3773 Date: Mon, 17 Aug 2009 12:50:52 -0700
   3774 Subject: [sup-talk] logging and internal API changes in next
   3775 Message-ID: <1250538107-sup-7121@masanjin.net>
   3776 
   3777 Dear Suppers,
   3778 
   3779 I've merged the aforementioned internal API changes, and a pretty big
   3780 rewrite of the logging system (branch "logging"), into next. It works
   3781 for me, but please report any problems you see.
   3782 
   3783 All logging messages are now categorized by level (debug, info, warn,
   3784 error) and will only be output when the global logging level is <= the
   3785 message level. The global logging level is determined by the environment
   3786 variable SUP_LOG_LEVEL; when unset, the default is "info". You'll notice
   3787 that the majority of the messages you saw before are now "debug"
   3788 messages, so the log buffer is much quieter.
   3789 
   3790 This change also applies to the various sup-* scripts.
   3791 
   3792 If you use this code and then switch to a branch without these changes,
   3793 you may encounter errors because labels are now represented on disk as
   3794 Sets instead of arrays. The solution is to edit your sources.yaml file
   3795 and manually change the Sets back to arrays; it should be obvious how to
   3796 do this. I don't anticipate this affecting too many people. If it does,
   3797 we can transform labels to arrays before storing to make this easier,
   3798 but hopefully it's just a temporary issue.
   3799 
   3800 I would like to merge these changes down to master sooner rather than
   3801 later, because they're so far-reaching.
   3802 -- 
   3803 William <wmorgan-sup at masanjin.net>
   3804 
   3805 From ezyang@MIT.EDU  Mon Aug 17 15:54:45 2009
   3806 From: ezyang@MIT.EDU (Edward Z. Yang)
   3807 Date: Mon, 17 Aug 2009 15:54:45 -0400
   3808 Subject: [sup-talk] ncurses hack
   3809 Message-ID: <1250538875-sup-2195@javelin>
   3810 
   3811 Today, I decided to throw in the towel and patch my copy of ncurses
   3812 to have the appropriate fix for international characters + tabs.  Does
   3813 anyone know of a list of instructions for carrying this out?
   3814 
   3815 Cheers,
   3816 Edward
   3817 
   3818 From garoth@gmail.com  Mon Aug 17 16:31:22 2009
   3819 From: garoth@gmail.com (Andrei Thorp)
   3820 Date: Mon, 17 Aug 2009 16:31:22 -0400
   3821 Subject: [sup-talk] logging and internal API changes in next
   3822 In-Reply-To: <1250538107-sup-7121@masanjin.net>
   3823 References: <1250538107-sup-7121@masanjin.net>
   3824 Message-ID: <1250541071-sup-7690@Longbow>
   3825 
   3826 Excerpts from William Morgan's message of Mon Aug 17 15:50:52 -0400 2009:
   3827 > Dear Suppers,
   3828 > 
   3829 > I've merged the aforementioned internal API changes, and a pretty big
   3830 > rewrite of the logging system (branch "logging"), into next. It works
   3831 > for me, but please report any problems you see.
   3832 > 
   3833 > All logging messages are now categorized by level (debug, info, warn,
   3834 > error) and will only be output when the global logging level is <= the
   3835 > message level. The global logging level is determined by the environment
   3836 > variable SUP_LOG_LEVEL; when unset, the default is "info". You'll notice
   3837 > that the majority of the messages you saw before are now "debug"
   3838 > messages, so the log buffer is much quieter.
   3839 > 
   3840 > This change also applies to the various sup-* scripts.
   3841 > 
   3842 > If you use this code and then switch to a branch without these changes,
   3843 > you may encounter errors because labels are now represented on disk as
   3844 > Sets instead of arrays. The solution is to edit your sources.yaml file
   3845 > and manually change the Sets back to arrays; it should be obvious how to
   3846 > do this. I don't anticipate this affecting too many people. If it does,
   3847 > we can transform labels to arrays before storing to make this easier,
   3848 > but hopefully it's just a temporary issue.
   3849 > 
   3850 > I would like to merge these changes down to master sooner rather than
   3851 > later, because they're so far-reaching.
   3852 
   3853 Looking forward to it, thanks.
   3854 -- 
   3855 Andrei Thorp, Developer: Xandros Corp. (http://www.xandros.com)
   3856 
   3857 From wmorgan-sup@masanjin.net  Mon Aug 17 22:43:18 2009
   3858 From: wmorgan-sup@masanjin.net (William Morgan)
   3859 Date: Mon, 17 Aug 2009 19:43:18 -0700
   3860 Subject: [sup-talk] ncurses hack
   3861 In-Reply-To: <1250538875-sup-2195@javelin>
   3862 References: <1250538875-sup-2195@javelin>
   3863 Message-ID: <1250563136-sup-432@masanjin.net>
   3864 
   3865 Reformatted excerpts from Edward Z. Yang's message of 2009-08-17:
   3866 > Today, I decided to throw in the towel and patch my copy of ncurses to
   3867 > have the appropriate fix for international characters + tabs.  Does
   3868 > anyone know of a list of instructions for carrying this out?
   3869 
   3870 Try http://sup.rubyforge.org/wiki/wiki.pl?UTF8. If you're running Sup
   3871 git, I've made a nice branch for this:
   3872 
   3873   $ git branch --track ncursesw origin/ncursesw
   3874   $ git checkout ncursesw
   3875   $ cd ncurses-0.9.1/
   3876   $ ./run-this-for-sup.sh
   3877 
   3878 Which will generate an ncurses.so file in lib/. You can then switch back
   3879 to master or next and it should pick it up.
   3880 
   3881 This should fix many wide-character issues but it won't fix all of them,
   3882 because there's still no way of determining the display width of a
   3883 unicode character (e.g. Chinese characters take two columns to display).
   3884 So the display still ends up funny.
   3885 
   3886 Ruby 1.9 has better encoding support but I don't know if it fixes this.
   3887 -- 
   3888 William <wmorgan-sup at masanjin.net>
   3889 
   3890 From ef_dva@yahoo.com  Tue Aug 18 03:42:48 2009
   3891 From: ef_dva@yahoo.com (Dusan)
   3892 Date: Tue, 18 Aug 2009 09:42:48 +0200
   3893 Subject: [sup-talk] ncurses hack
   3894 In-Reply-To: <1250563136-sup-432@masanjin.net>
   3895 References: <1250538875-sup-2195@javelin> <1250563136-sup-432@masanjin.net>
   3896 Message-ID: <1250580593-sup-1346@archpc>
   3897 
   3898 Excerpts from William Morgan's message of Tue Aug 18 04:43:18 +0200 2009:
   3899 > Reformatted excerpts from Edward Z. Yang's message of 2009-08-17:
   3900 > > Today, I decided to throw in the towel and patch my copy of ncurses to
   3901 > > have the appropriate fix for international characters + tabs.  Does
   3902 > > anyone know of a list of instructions for carrying this out?
   3903 > 
   3904 > Try http://sup.rubyforge.org/wiki/wiki.pl?UTF8. If you're running Sup
   3905 > git, I've made a nice branch for this:
   3906 > 
   3907 >   $ git branch --track ncursesw origin/ncursesw
   3908 >   $ git checkout ncursesw
   3909 >   $ cd ncurses-0.9.1/
   3910 >   $ ./run-this-for-sup.sh
   3911 > 
   3912 > Which will generate an ncurses.so file in lib/. You can then switch back
   3913 > to master or next and it should pick it up.
   3914 > 
   3915 > This should fix many wide-character issues but it won't fix all of them,
   3916 > because there's still no way of determining the display width of a
   3917 > unicode character (e.g. Chinese characters take two columns to display).
   3918 > So the display still ends up funny.
   3919 > 
   3920 > Ruby 1.9 has better encoding support but I don't know if it fixes this.
   3921 
   3922 I am new sup user and love it very much.
   3923 
   3924 Not being able to fix search/save and other edits is huge show-stopper.
   3925 I do what I read somewhere:
   3926 
   3927 -start search, get garbage results
   3928 -kill that buffer with 'x'
   3929 -start another search but instead of typing search term again first
   3930 repeat: press up, delete search garbage, press up, delete search
   3931 garbage, repeat until there is nothing to delete
   3932 -type another search term and search now works 100%
   3933 
   3934 This works for searches but edits like save still fail (or save X((%^1X file
   3935 so if you can find it you can rename it).
   3936 
   3937 Looks like fixable bug to simulate what I did for searches? Repeat in
   3938 code ten times 'up arrow', '50 x delete char'? Sorry if I am wrong.
   3939 
   3940 Using sup and not being able to properly search or save is too wrong.
   3941 
   3942 If there is any config/version I should report to get this fixed just
   3943 let me know. Without waiting for new ruby of course -- I do have proper
   3944 results when I repeat deleting ritual.
   3945 
   3946 Thanks
   3947 
   3948 From bwalton@artsci.utoronto.ca  Tue Aug 18 12:58:57 2009
   3949 From: bwalton@artsci.utoronto.ca (Ben Walton)
   3950 Date: Tue, 18 Aug 2009 12:58:57 -0400
   3951 Subject: [sup-talk] xapian rpms
   3952 Message-ID: <1250614640-sup-8983@ntdws12.chass.utoronto.ca>
   3953 
   3954 
   3955 Hi All,
   3956 
   3957 I've built a set of rpms for xapian (1.0.14) for rhel5.  If you're
   3958 interested in them, I'll share.  I have both 32 and 64 bit versions.
   3959 The xapian site rpm collection doesn't offer the ruby bindings.
   3960 
   3961 Thanks
   3962 -Ben
   3963 -- 
   3964 Ben Walton
   3965 Systems Programmer - CHASS
   3966 University of Toronto
   3967 C:416.407.5610 | W:416.978.4302
   3968 
   3969 GPG Key Id: 8E89F6D2; Key Server: pgp.mit.edu
   3970 Contact me to arrange for a CAcert assurance meeting.
   3971 -------------- next part --------------
   3972 A non-text attachment was scrubbed...
   3973 Name: signature.asc
   3974 Type: application/pgp-signature
   3975 Size: 189 bytes
   3976 Desc: not available
   3977 URL: <http://rubyforge.org/pipermail/sup-talk/attachments/20090818/aa04491f/attachment.bin>
   3978 
   3979 From wmorgan-sup@masanjin.net  Tue Aug 18 13:33:33 2009
   3980 From: wmorgan-sup@masanjin.net (William Morgan)
   3981 Date: Tue, 18 Aug 2009 10:33:33 -0700
   3982 Subject: [sup-talk] [PATCH] maildir: Allow ',
   3983 	' in the unique-name portion of a maildir filename.
   3984 In-Reply-To: <20090815042943.GA2414@yoom.home.cworth.org>
   3985 References: <20090815042943.GA2414@yoom.home.cworth.org>
   3986 Message-ID: <1250616640-sup-2613@masanjin.net>
   3987 
   3988 Reformatted excerpts from Carl Worth's message of 2009-08-14:
   3989 > A unique name can be anything that doesn't contain a colon (or slash)
   3990 > and doesn't start with a dot.
   3991 
   3992 I've applied this patch directly to master. (The one I complained about
   3993 was attached to your original email; I just noticed this one was
   3994 different now.)
   3995 
   3996 > Argh! What's worse than Forgotten Attachment Syndrome (FAS),
   3997 > (especially on my first post to a list)?
   3998 
   3999 Since Sup should now work for you, you'll be happy to know that it warns
   4000 you if you use the word "attachment" without attaching anything. :)
   4001 -- 
   4002 William <wmorgan-sup at masanjin.net>
   4003 
   4004 From bwalton@artsci.utoronto.ca  Tue Aug 18 13:35:35 2009
   4005 From: bwalton@artsci.utoronto.ca (Ben Walton)
   4006 Date: Tue, 18 Aug 2009 13:35:35 -0400
   4007 Subject: [sup-talk] crash when sup-syncing to xapian
   4008 Message-ID: <1250616603-sup-5612@ntdws12.chass.utoronto.ca>
   4009 
   4010 
   4011 I just tried to import my index to xapian and it crashed part way
   4012 through the import.  I then discovered that I couldn't use ferret
   4013 either.  There is something wonky with label handling, as per attached
   4014 exception log.  I haven't had a chance to look at the code yet, but
   4015 I'll poke at it tonight.
   4016 
   4017 Thanks
   4018 -Ben
   4019 -- 
   4020 Ben Walton
   4021 Systems Programmer - CHASS
   4022 University of Toronto
   4023 C:416.407.5610 | W:416.978.4302
   4024 
   4025 GPG Key Id: 8E89F6D2; Key Server: pgp.mit.edu
   4026 Contact me to arrange for a CAcert assurance meeting.
   4027 -------------- next part --------------
   4028 An embedded and charset-unspecified text was scrubbed...
   4029 Name: sup-exception-log.txt
   4030 URL: <http://rubyforge.org/pipermail/sup-talk/attachments/20090818/28bccae3/attachment.txt>
   4031 
   4032 From wmorgan-sup@masanjin.net  Tue Aug 18 13:36:27 2009
   4033 From: wmorgan-sup@masanjin.net (William Morgan)
   4034 Date: Tue, 18 Aug 2009 10:36:27 -0700
   4035 Subject: [sup-talk] [PATCH] skip system buffers when rolling
   4036 In-Reply-To: <1250451359-16110-1-git-send-email-rlane@club.cc.cmu.edu>
   4037 References: <1250451359-16110-1-git-send-email-rlane@club.cc.cmu.edu>
   4038 Message-ID: <1250616971-sup-7888@masanjin.net>
   4039 
   4040 Nice idea. Branch buffer-rolling, merged into next.
   4041 -- 
   4042 William <wmorgan-sup at masanjin.net>
   4043 
   4044 From wmorgan-sup@masanjin.net  Tue Aug 18 13:38:58 2009
   4045 From: wmorgan-sup@masanjin.net (William Morgan)
   4046 Date: Tue, 18 Aug 2009 10:38:58 -0700
   4047 Subject: [sup-talk] [PATCH] add 'I' keybinding to raise Inbox buffer
   4048 In-Reply-To: <1250451368-16150-1-git-send-email-rlane@club.cc.cmu.edu>
   4049 References: <1250451368-16150-1-git-send-email-rlane@club.cc.cmu.edu>
   4050 Message-ID: <1250617129-sup-4194@masanjin.net>
   4051 
   4052 Applied to master, thanks!
   4053 -- 
   4054 William <wmorgan-sup at masanjin.net>
   4055 
   4056 From cworth@cworth.org  Tue Aug 18 13:49:05 2009
   4057 From: cworth@cworth.org (Carl Worth)
   4058 Date: Tue, 18 Aug 2009 10:49:05 -0700
   4059 Subject: [sup-talk] [PATCH] maildir: Allow ',
   4060 	' in the unique-name portion of a maildir filename.
   4061 In-Reply-To: <1250616640-sup-2613@masanjin.net>
   4062 References: <20090815042943.GA2414@yoom.home.cworth.org>
   4063 	<1250616640-sup-2613@masanjin.net>
   4064 Message-ID: <1250617174-sup-2755@yoom>
   4065 
   4066 Excerpts from William Morgan's message of Tue Aug 18 10:33:33 -0700 2009:
   4067 > I've applied this patch directly to master. (The one I complained about
   4068 > was attached to your original email; I just noticed this one was
   4069 > different now.)
   4070 
   4071 Thanks for catching this.
   4072 
   4073 > > Argh! What's worse than Forgotten Attachment Syndrome (FAS),
   4074 > > (especially on my first post to a list)?
   4075 > 
   4076 > Since Sup should now work for you, you'll be happy to know that it warns
   4077 > you if you use the word "attachment" without attaching anything. :)
   4078 
   4079 If it's just the word "attachment" I don't think it will affect me at
   4080 all. The wording I generally use is something like:
   4081 
   4082 	I've attached a test case to demonstrate the bug.
   4083 
   4084 But in general this should be a nice feature, (except for a mail like
   4085 this one that will cause a false warning from the check). ;-)
   4086 
   4087 Thanks again for all your work on sup,
   4088 
   4089 -Carl
   4090 -------------- next part --------------
   4091 A non-text attachment was scrubbed...
   4092 Name: signature.asc
   4093 Type: application/pgp-signature
   4094 Size: 189 bytes
   4095 Desc: not available
   4096 URL: <http://rubyforge.org/pipermail/sup-talk/attachments/20090818/26c6e1c6/attachment.bin>
   4097 
   4098 From wmorgan-sup@masanjin.net  Tue Aug 18 13:54:20 2009
   4099 From: wmorgan-sup@masanjin.net (William Morgan)
   4100 Date: Tue, 18 Aug 2009 10:54:20 -0700
   4101 Subject: [sup-talk] [PATCH] maildir: Allow ',
   4102 	' in the unique-name portion of a maildir filename.
   4103 In-Reply-To: <1250617174-sup-2755@yoom>
   4104 References: <20090815042943.GA2414@yoom.home.cworth.org>
   4105 	<1250616640-sup-2613@masanjin.net> <1250617174-sup-2755@yoom>
   4106 Message-ID: <1250617985-sup-2416@masanjin.net>
   4107 
   4108 Reformatted excerpts from Carl Worth's message of 2009-08-18:
   4109 > If it's just the word "attachment" I don't think it will affect me at
   4110 > all.
   4111 
   4112 Don't worry, Sup uses sophisticated natural language technology to
   4113 induce message semantics.
   4114 -- 
   4115 William <wmorgan-sup at masanjin.net>
   4116 
   4117 From wmorgan-sup@masanjin.net  Tue Aug 18 13:56:15 2009
   4118 From: wmorgan-sup@masanjin.net (William Morgan)
   4119 Date: Tue, 18 Aug 2009 10:56:15 -0700
   4120 Subject: [sup-talk] [PATCH] Add an after-add-message hook
   4121 In-Reply-To: <1250459229-4500-1-git-send-email-kevinr@free-dissociation.com>
   4122 References: <1250459229-4500-1-git-send-email-kevinr@free-dissociation.com>
   4123 Message-ID: <1250618123-sup-8797@masanjin.net>
   4124 
   4125 Reformatted excerpts from Kevin Riggle's message of 2009-08-16:
   4126 > I want to do some unrelated processing on each message I receive, but
   4127 > I don't want to block the message being added to the index.  This
   4128 > patch adds a hook which runs /after/ the message is added to the
   4129 > index.
   4130 
   4131 Won't this block subsequent emails from being added to the index, when
   4132 Sup gets multiple new emails during a poll?
   4133 -- 
   4134 William <wmorgan-sup at masanjin.net>
   4135 
   4136 From benoit.pierre@gmail.com  Tue Aug 18 14:20:41 2009
   4137 From: benoit.pierre@gmail.com (=?utf-8?q?Beno=C3=AEt_PIERRE?=)
   4138 Date: Tue, 18 Aug 2009 20:20:41 +0200
   4139 Subject: [sup-talk] crash when sup-syncing to xapian
   4140 In-Reply-To: <1250616603-sup-5612@ntdws12.chass.utoronto.ca>
   4141 References: <1250616603-sup-5612@ntdws12.chass.utoronto.ca>
   4142 Message-ID: <1250619511-sup-2827@localdomain>
   4143 
   4144 Excerpts from Ben Walton's message of Tue Aug 18 19:35:35 +0200 2009:
   4145 > 
   4146 > I just tried to import my index to xapian and it crashed part way
   4147 > through the import.  I then discovered that I couldn't use ferret
   4148 > either.  There is something wonky with label handling, as per attached
   4149 > exception log.  I haven't had a chance to look at the code yet, but
   4150 > I'll poke at it tonight.
   4151 
   4152 I think I just ran into the same problem! For now I fixed it with
   4153 the following small patch:
   4154 
   4155 diff --git a/lib/sup/label.rb b/lib/sup/label.rb
   4156 index 67474c2..59c0c0f 100644
   4157 --- a/lib/sup/label.rb
   4158 +++ b/lib/sup/label.rb
   4159 @@ -61,6 +61,7 @@ class LabelManager
   4160    end
   4161 
   4162    def << t
   4163 +    t = t.to_sym if t.is_a? String
   4164      raise ArgumentError, "expecting a symbol" unless t.is_a? Symbol
   4165      unless @labels.member?(t) || RESERVED_LABELS.member?(t)
   4166        @labels[t] = true
   4167 
   4168 -- 
   4169 A: Because it destroys the flow of conversation.
   4170 Q: Why is top posting dumb?
   4171 -------------- next part --------------
   4172 A non-text attachment was scrubbed...
   4173 Name: signature.asc
   4174 Type: application/pgp-signature
   4175 Size: 289 bytes
   4176 Desc: not available
   4177 URL: <http://rubyforge.org/pipermail/sup-talk/attachments/20090818/4a4ab3f7/attachment.bin>
   4178 
   4179 From benoit.pierre@gmail.com  Tue Aug 18 14:24:45 2009
   4180 From: benoit.pierre@gmail.com (=?utf-8?q?Beno=C3=AEt_PIERRE?=)
   4181 Date: Tue, 18 Aug 2009 20:24:45 +0200
   4182 Subject: [sup-talk] ncurses hack
   4183 In-Reply-To: <1250580593-sup-1346@archpc>
   4184 References: <1250538875-sup-2195@javelin> <1250563136-sup-432@masanjin.net>
   4185 	<1250580593-sup-1346@archpc>
   4186 Message-ID: <1250619721-sup-91@localdomain>
   4187 
   4188 Excerpts from Dusan's message of Tue Aug 18 09:42:48 +0200 2009:
   4189 >
   4190 > [...]
   4191 > 
   4192 > Not being able to fix search/save and other edits is huge show-stopper.
   4193 > I do what I read somewhere:
   4194 > 
   4195 > -start search, get garbage results
   4196 > -kill that buffer with 'x'
   4197 > -start another search but instead of typing search term again first
   4198 > repeat: press up, delete search garbage, press up, delete search
   4199 > garbage, repeat until there is nothing to delete
   4200 > -type another search term and search now works 100%
   4201 > 
   4202 > This works for searches but edits like save still fail (or save X((%^1X file
   4203 > so if you can find it you can rename it).
   4204 > 
   4205 > Looks like fixable bug to simulate what I did for searches? Repeat in
   4206 > code ten times 'up arrow', '50 x delete char'? Sorry if I am wrong.
   4207 > 
   4208 > Using sup and not being able to properly search or save is too wrong.
   4209 > 
   4210 > If there is any config/version I should report to get this fixed just
   4211 > let me know. Without waiting for new ruby of course -- I do have proper
   4212 > results when I repeat deleting ritual.
   4213 
   4214 Hi, can you try the following patch and tell me if it fix the problem?
   4215 
   4216 diff --git a/lib/sup/textfield.rb b/lib/sup/textfield.rb
   4217 index b8dec59..ccc8533 100644
   4218 --- a/lib/sup/textfield.rb
   4219 +++ b/lib/sup/textfield.rb
   4220 @@ -36,8 +36,9 @@ class TextField
   4221      @field = Ncurses::Form.new_field 1, @width - question.length, @y,
   4222 @x + question.length, 256, 0
   4223      @form = Ncurses::Form.new_form [@field]
   4224      @value = default
   4225 +    @value ||= ''
   4226      Ncurses::Form.post_form @form
   4227 -    set_cursed_value default if default
   4228 +    set_cursed_value @value
   4229    end
   4230 
   4231    def position_cursor
   4232 
   4233 -- 
   4234 A: Because it destroys the flow of conversation.
   4235 Q: Why is top posting dumb?
   4236 
   4237 From alex@chmrr.net  Tue Aug 18 14:30:00 2009
   4238 From: alex@chmrr.net (Alex Vandiver)
   4239 Date: Tue, 18 Aug 2009 14:30:00 -0400
   4240 Subject: [sup-talk] [PATCH] Fix a thread merging bug introduced by
   4241 	refactoring in 59f8fc2
   4242 Message-ID: <1250620200-24319-1-git-send-email-alex@chmrr.net>
   4243 
   4244 
   4245 Signed-off-by: Alex Vandiver <alex at chmrr.net>
   4246 ---
   4247  lib/sup/thread.rb |    2 +-
   4248  1 files changed, 1 insertions(+), 1 deletions(-)
   4249 
   4250 diff --git a/lib/sup/thread.rb b/lib/sup/thread.rb
   4251 index d395c35..3ff4e7f 100644
   4252 --- a/lib/sup/thread.rb
   4253 +++ b/lib/sup/thread.rb
   4254 @@ -357,7 +357,7 @@ class ThreadSet
   4255      return if threads.size < 2
   4256  
   4257      containers = threads.map do |t|
   4258 -      c = @messages.member?(c) ? @messages[t.first.id] : nil
   4259 +      c = @messages.member?(t.first.id) ? @messages[t.first.id] : nil
   4260        raise "not in threadset: #{t.first.id}" unless c && c.message
   4261        c
   4262      end
   4263 -- 
   4264 1.6.3.3
   4265 
   4266 
   4267 From wmorgan-sup@masanjin.net  Tue Aug 18 14:37:38 2009
   4268 From: wmorgan-sup@masanjin.net (William Morgan)
   4269 Date: Tue, 18 Aug 2009 11:37:38 -0700
   4270 Subject: [sup-talk] [PATCH 1/5] console mode
   4271 In-Reply-To: <1250491155-19281-1-git-send-email-rlane@club.cc.cmu.edu>
   4272 References: <1250491155-19281-1-git-send-email-rlane@club.cc.cmu.edu>
   4273 Message-ID: <1250620017-sup-3445@masanjin.net>
   4274 
   4275 Cool idea. Branch console-mode, merged into next.
   4276 -- 
   4277 William <wmorgan-sup at masanjin.net>
   4278 
   4279 From rlane@club.cc.cmu.edu  Tue Aug 18 14:42:13 2009
   4280 From: rlane@club.cc.cmu.edu (Rich Lane)
   4281 Date: Tue, 18 Aug 2009 14:42:13 -0400
   4282 Subject: [sup-talk] crash when sup-syncing to xapian
   4283 In-Reply-To: <1250619511-sup-2827@localdomain>
   4284 References: <1250616603-sup-5612@ntdws12.chass.utoronto.ca>
   4285 	<1250619511-sup-2827@localdomain>
   4286 Message-ID: <1250620771-sup-1373@zyrg.net>
   4287 
   4288 Excerpts from Beno?t PIERRE's message of Tue Aug 18 14:20:41 -0400 2009:
   4289 > Excerpts from Ben Walton's message of Tue Aug 18 19:35:35 +0200 2009:
   4290 > > 
   4291 > > I just tried to import my index to xapian and it crashed part way
   4292 > > through the import.  I then discovered that I couldn't use ferret
   4293 > > either.  There is something wonky with label handling, as per attached
   4294 > > exception log.  I haven't had a chance to look at the code yet, but
   4295 > > I'll poke at it tonight.
   4296 > 
   4297 > I think I just ran into the same problem! For now I fixed it with
   4298 > the following small patch:
   4299 
   4300 That's odd because the Xapian code passes the labels straight through
   4301 from the message to LabelManager. Try instrumenting Message#labels= to
   4302 raise an exception if any member of the set is not a Symbol.
   4303 
   4304 From ef_dva@yahoo.com  Tue Aug 18 14:46:52 2009
   4305 From: ef_dva@yahoo.com (Dusan)
   4306 Date: Tue, 18 Aug 2009 20:46:52 +0200
   4307 Subject: [sup-talk] ncurses hack
   4308 In-Reply-To: <1250619721-sup-91@localdomain>
   4309 References: <1250538875-sup-2195@javelin> <1250563136-sup-432@masanjin.net>
   4310 	<1250580593-sup-1346@archpc> <1250619721-sup-91@localdomain>
   4311 Message-ID: <1250620908-sup-7463@archpc>
   4312 
   4313 Excerpts from Beno?t PIERRE's message of Tue Aug 18 20:24:45 +0200 2009:
   4314 > Excerpts from Dusan's message of Tue Aug 18 09:42:48 +0200 2009:
   4315 > >
   4316 > > [...]
   4317 > > 
   4318 > > Not being able to fix search/save and other edits is huge show-stopper.
   4319 > > I do what I read somewhere:
   4320 > > 
   4321 > > -start search, get garbage results
   4322 > > -kill that buffer with 'x'
   4323 > > -start another search but instead of typing search term again first
   4324 > > repeat: press up, delete search garbage, press up, delete search
   4325 > > garbage, repeat until there is nothing to delete
   4326 > > -type another search term and search now works 100%
   4327 > > 
   4328 > > This works for searches but edits like save still fail (or save X((%^1X file
   4329 > > so if you can find it you can rename it).
   4330 > > 
   4331 > > Looks like fixable bug to simulate what I did for searches? Repeat in
   4332 > > code ten times 'up arrow', '50 x delete char'? Sorry if I am wrong.
   4333 > > 
   4334 > > Using sup and not being able to properly search or save is too wrong.
   4335 > > 
   4336 > > If there is any config/version I should report to get this fixed just
   4337 > > let me know. Without waiting for new ruby of course -- I do have proper
   4338 > > results when I repeat deleting ritual.
   4339 > 
   4340 > Hi, can you try the following patch and tell me if it fix the problem?
   4341 > 
   4342 > diff --git a/lib/sup/textfield.rb b/lib/sup/textfield.rb
   4343 > index b8dec59..ccc8533 100644
   4344 > --- a/lib/sup/textfield.rb
   4345 > +++ b/lib/sup/textfield.rb
   4346 > @@ -36,8 +36,9 @@ class TextField
   4347 >      @field = Ncurses::Form.new_field 1, @width - question.length, @y,
   4348 > @x + question.length, 256, 0
   4349 >      @form = Ncurses::Form.new_form [@field]
   4350 >      @value = default
   4351 > +    @value ||= ''
   4352 >      Ncurses::Form.post_form @form
   4353 > -    set_cursed_value default if default
   4354 > +    set_cursed_value @value
   4355 >    end
   4356 > 
   4357 >    def position_cursor
   4358 
   4359 I will, just give me day or two. I am using gem version, not svn or git.
   4360 I did some stuff with them but never with ruby. Can you give me two
   4361 lines help what to install and where? Latest svn?
   4362 
   4363 Sorry I am not _that_ helpful but ruby is new thing to me. I should be
   4364 able to test this soon enough with some help.
   4365 
   4366 Thanks,
   4367 Dusan
   4368 
   4369 From benoit.pierre@gmail.com  Tue Aug 18 14:59:20 2009
   4370 From: benoit.pierre@gmail.com (=?utf-8?q?Beno=C3=AEt_PIERRE?=)
   4371 Date: Tue, 18 Aug 2009 20:59:20 +0200
   4372 Subject: [sup-talk] ncurses hack
   4373 In-Reply-To: <1250620908-sup-7463@archpc>
   4374 References: <1250538875-sup-2195@javelin> <1250563136-sup-432@masanjin.net>
   4375 	<1250580593-sup-1346@archpc> <1250619721-sup-91@localdomain>
   4376 	<1250620908-sup-7463@archpc>
   4377 Message-ID: <1250621614-sup-5683@localdomain>
   4378 
   4379 Excerpts from Dusan's message of Tue Aug 18 20:46:52 +0200 2009:
   4380 > Excerpts from Beno?t PIERRE's message of Tue Aug 18 20:24:45 +0200 2009:
   4381 > > Excerpts from Dusan's message of Tue Aug 18 09:42:48 +0200 2009:
   4382 >
   4383 > [...]
   4384 > 
   4385 > I will, just give me day or two. I am using gem version, not svn or git.
   4386 > I did some stuff with them but never with ruby. Can you give me two
   4387 > lines help what to install and where? Latest svn?
   4388 
   4389 You can probably directly patch the sources in the gem. For example on
   4390 Ubuntu, the sources should be somewhere in /var/lib/gems/1.8/gems/sup-xxx.
   4391 
   4392 Use 'gem environment' to get the installation directory.
   4393 
   4394 Another option is to follow the wiki to get the latest git version:
   4395 http://sup.rubyforge.org/wiki/wiki.pl?Contributing
   4396 -- 
   4397 A: Because it destroys the flow of conversation.
   4398 Q: Why is top posting dumb?
   4399 -------------- next part --------------
   4400 A non-text attachment was scrubbed...
   4401 Name: signature.asc
   4402 Type: application/pgp-signature
   4403 Size: 197 bytes
   4404 Desc: not available
   4405 URL: <http://rubyforge.org/pipermail/sup-talk/attachments/20090818/302eaeb0/attachment.bin>
   4406 
   4407 From ef_dva@yahoo.com  Tue Aug 18 15:04:16 2009
   4408 From: ef_dva@yahoo.com (Dusan)
   4409 Date: Tue, 18 Aug 2009 21:04:16 +0200
   4410 Subject: [sup-talk] ncurses hack
   4411 In-Reply-To: <1250621614-sup-5683@localdomain>
   4412 References: <1250538875-sup-2195@javelin> <1250563136-sup-432@masanjin.net>
   4413 	<1250580593-sup-1346@archpc> <1250619721-sup-91@localdomain>
   4414 	<1250620908-sup-7463@archpc> <1250621614-sup-5683@localdomain>
   4415 Message-ID: <1250622060-sup-324@archpc>
   4416 
   4417 Excerpts from Beno?t PIERRE's message of Tue Aug 18 20:59:20 +0200 2009:
   4418 > Excerpts from Dusan's message of Tue Aug 18 20:46:52 +0200 2009:
   4419 > > Excerpts from Beno?t PIERRE's message of Tue Aug 18 20:24:45 +0200 2009:
   4420 > > > Excerpts from Dusan's message of Tue Aug 18 09:42:48 +0200 2009:
   4421 > >
   4422 > > [...]
   4423 > > 
   4424 > > I will, just give me day or two. I am using gem version, not svn or git.
   4425 > > I did some stuff with them but never with ruby. Can you give me two
   4426 > > lines help what to install and where? Latest svn?
   4427 > 
   4428 > You can probably directly patch the sources in the gem. For example on
   4429 > Ubuntu, the sources should be somewhere in /var/lib/gems/1.8/gems/sup-xxx.
   4430 > 
   4431 > Use 'gem environment' to get the installation directory.
   4432 > 
   4433 > Another option is to follow the wiki to get the latest git version:
   4434 > http://sup.rubyforge.org/wiki/wiki.pl?Contributing
   4435 
   4436 Everything but git, thanks :)
   4437 Of course, ruby is interpreter, I keep forgetting that.
   4438 I am using ArchLinux and should be fairly skilled to do some changing. Reporting
   4439 back tomorrow.
   4440 
   4441 From benoit.pierre@gmail.com  Tue Aug 18 15:17:03 2009
   4442 From: benoit.pierre@gmail.com (=?utf-8?q?Beno=C3=AEt_PIERRE?=)
   4443 Date: Tue, 18 Aug 2009 21:17:03 +0200
   4444 Subject: [sup-talk] crash when sup-syncing to xapian
   4445 In-Reply-To: <1250620771-sup-1373@zyrg.net>
   4446 References: <1250616603-sup-5612@ntdws12.chass.utoronto.ca>
   4447 	<1250619511-sup-2827@localdomain> <1250620771-sup-1373@zyrg.net>
   4448 Message-ID: <1250622911-sup-2815@localdomain>
   4449 
   4450 Excerpts from Rich Lane's message of Tue Aug 18 20:42:13 +0200 2009:
   4451 > Excerpts from Beno?t PIERRE's message of Tue Aug 18 14:20:41 -0400 2009:
   4452 > > Excerpts from Ben Walton's message of Tue Aug 18 19:35:35 +0200 2009:
   4453 > > > 
   4454 > > > I just tried to import my index to xapian and it crashed part way
   4455 > > > through the import.  I then discovered that I couldn't use ferret
   4456 > > > either.  There is something wonky with label handling, as per attached
   4457 > > > exception log.  I haven't had a chance to look at the code yet, but
   4458 > > > I'll poke at it tonight.
   4459 > > 
   4460 > > I think I just ran into the same problem! For now I fixed it with
   4461 > > the following small patch:
   4462 > 
   4463 > That's odd because the Xapian code passes the labels straight through
   4464 > from the message to LabelManager. Try instrumenting Message#labels= to
   4465 > raise an exception if any member of the set is not a Symbol.
   4466 
   4467 I applied the following patch:
   4468 
   4469 diff --git a/lib/sup/message.rb b/lib/sup/message.rb
   4470 index 965c10e..9156c02 100644
   4471 --- a/lib/sup/message.rb
   4472 +++ b/lib/sup/message.rb
   4473 @@ -1,4 +1,5 @@
   4474  require 'time'
   4475 +require 'pp'
   4476 
   4477  module Redwood
   4478 
   4479 @@ -183,6 +184,7 @@ class Message
   4480    def labels= l
   4481      raise ArgumentError, "not a set" unless l.is_a?(Set)
   4482      return if @labels == l
   4483 +    warn "labels=#{l.pretty_inspect}"
   4484      @labels = l
   4485      @dirty = true
   4486    end
   4487 
   4488 And get this in the logs:
   4489 
   4490 [Tue Aug 18 21:12:39 +0200 2009] WARNING: labels=#<Set: {:inbox, :unread, "aquarius", "music"}>
   4491 [Tue Aug 18 21:12:39 +0200 2009] WARNING: labels=#<Set: {:inbox, :unread, "metalblade", "music"}>
   4492 
   4493 -- 
   4494 A: Because it destroys the flow of conversation.
   4495 Q: Why is top posting dumb?
   4496 -------------- next part --------------
   4497 A non-text attachment was scrubbed...
   4498 Name: signature.asc
   4499 Type: application/pgp-signature
   4500 Size: 197 bytes
   4501 Desc: not available
   4502 URL: <http://rubyforge.org/pipermail/sup-talk/attachments/20090818/721494a9/attachment.bin>
   4503 
   4504 From ef_dva@yahoo.com  Tue Aug 18 15:24:44 2009
   4505 From: ef_dva@yahoo.com (Dusan)
   4506 Date: Tue, 18 Aug 2009 21:24:44 +0200
   4507 Subject: [sup-talk] ncurses hack
   4508 In-Reply-To: <1250621614-sup-5683@localdomain>
   4509 References: <1250538875-sup-2195@javelin> <1250563136-sup-432@masanjin.net>
   4510 	<1250580593-sup-1346@archpc> <1250619721-sup-91@localdomain>
   4511 	<1250620908-sup-7463@archpc> <1250621614-sup-5683@localdomain>
   4512 Message-ID: <1250623031-sup-6731@archpc>
   4513 
   4514 Excerpts from Beno?t PIERRE's message of Tue Aug 18 20:59:20 +0200 2009:
   4515 > Excerpts from Dusan's message of Tue Aug 18 20:46:52 +0200 2009:
   4516 > > Excerpts from Beno?t PIERRE's message of Tue Aug 18 20:24:45 +0200 2009:
   4517 > > > Excerpts from Dusan's message of Tue Aug 18 09:42:48 +0200 2009:
   4518 > >
   4519 > > [...]
   4520 > > 
   4521 > > I will, just give me day or two. I am using gem version, not svn or git.
   4522 > > I did some stuff with them but never with ruby. Can you give me two
   4523 > > lines help what to install and where? Latest svn?
   4524 > 
   4525 > You can probably directly patch the sources in the gem. For example on
   4526 > Ubuntu, the sources should be somewhere in /var/lib/gems/1.8/gems/sup-xxx.
   4527 > 
   4528 > Use 'gem environment' to get the installation directory.
   4529 > 
   4530 > Another option is to follow the wiki to get the latest git version:
   4531 > http://sup.rubyforge.org/wiki/wiki.pl?Contributing
   4532 
   4533 Bah, I could not wait till tomorrow and it's not _that_ late...
   4534 
   4535 This fix WORKS :) Every time so far. Please include this into release
   4536 asap, this is what prevents a lot of people from using sup.
   4537 
   4538 I patched source with vim, diff is too automatic :)
   4539 
   4540 Here is func that works:
   4541 
   4542   activate window, y, x, width, question, default=nil, &block
   4543     @w, @y, @x, @width = window, y, x, width
   4544     @question = question
   4545     @completion_block = block
   4546     @field = Ncurses::Form.new_field 1, @width - question.length, @y, @x
   4547 + question.length, 256, 0
   4548     @form = Ncurses::Form.new_form [@field]
   4549     @value = default
   4550     @value ||= ''
   4551     Ncurses::Form.post_form @form
   4552     # set_cursed_value default if default
   4553     set_cursed_value @value
   4554   end 
   4555 
   4556 Probably @value=default can go too, not sure since I don't know ruby?
   4557 
   4558 Thanks a lot!
   4559 
   4560 From bachjh@googlemail.com  Tue Aug 18 15:31:35 2009
   4561 From: bachjh@googlemail.com (=?UTF-8?B?SsO2cmctSGVuZHJpayBCYWNo?=)
   4562 Date: Tue, 18 Aug 2009 21:31:35 +0200
   4563 Subject: [sup-talk] ncurses hack
   4564 In-Reply-To: <1250619721-sup-91@localdomain>
   4565 References: <1250538875-sup-2195@javelin> <1250563136-sup-432@masanjin.net>
   4566 	<1250580593-sup-1346@archpc> <1250619721-sup-91@localdomain>
   4567 Message-ID: <91de50e10908181231h2f8f4cbdr6ab546aa4a3466ca@mail.gmail.com>
   4568 
   4569 2009/8/18 Beno?t PIERRE <benoit.pierre at gmail.com>:
   4570 > Hi, can you try the following patch and tell me if it fix the problem?
   4571 >
   4572 > diff --git a/lib/sup/textfield.rb b/lib/sup/textfield.rb
   4573 > index b8dec59..ccc8533 100644
   4574 > --- a/lib/sup/textfield.rb
   4575 > +++ b/lib/sup/textfield.rb
   4576 > @@ -36,8 +36,9 @@ class TextField
   4577 > ? ? @field = Ncurses::Form.new_field 1, @width - question.length, @y,
   4578 > @x + question.length, 256, 0
   4579 > ? ? @form = Ncurses::Form.new_form [@field]
   4580 > ? ? @value = default
   4581 > + ? ?@value ||= ''
   4582 > ? ? Ncurses::Form.post_form @form
   4583 > - ? ?set_cursed_value default if default
   4584 > + ? ?set_cursed_value @value
   4585 > ? end
   4586 >
   4587 > ? def position_cursor
   4588 
   4589 Thanks a lot. I don't know what this does exactly, but the first added
   4590 line of that patch was sufficient to get searches with utf-8 running
   4591 well from startup, without the need to go for a dummy search each time
   4592 i restarted sup.
   4593 
   4594 The full patch (including the replacement at line 41) broke searching
   4595 altogether, on hitting '\' it throws:
   4596 
   4597 --- TypeError from thread: main
   4598 can't convert nil into String
   4599 /usr/lib/ruby/gems/1.8/gems/sup-0.8.1/lib/sup/textfield.rb:159:in
   4600 `set_field_buffer'
   4601 /usr/lib/ruby/gems/1.8/gems/sup-0.8.1/lib/sup/textfield.rb:159:in
   4602 `set_cursed_value'
   4603 /usr/lib/ruby/gems/1.8/gems/sup-0.8.1/lib/sup/textfield.rb:42:in `activate'
   4604 /usr/lib/ruby/gems/1.8/gems/sup-0.8.1/lib/sup/buffer.rb:537:in `ask'
   4605 /usr/lib/ruby/gems/1.8/gems/sup-0.8.1/lib/sup/buffer.rb:26:in `synchronize'
   4606 /usr/lib/ruby/gems/1.8/gems/sup-0.8.1/lib/sup/buffer.rb:26:in `sync'
   4607 /usr/lib/ruby/gems/1.8/gems/sup-0.8.1/lib/sup/buffer.rb:536:in `ask'
   4608 /usr/lib/ruby/gems/1.8/gems/sup-0.8.1/lib/sup/util.rb:513:in `send'
   4609 /usr/lib/ruby/gems/1.8/gems/sup-0.8.1/lib/sup/util.rb:513:in `method_missing'
   4610 /usr/lib/ruby/gems/1.8/gems/sup-0.8.1/bin/sup:268
   4611 /usr/bin/sup:19:in `load'
   4612 /usr/bin/sup:19
   4613 
   4614 
   4615 
   4616 - J?rg-Hendrik
   4617 
   4618 From rlane@club.cc.cmu.edu  Tue Aug 18 15:52:12 2009
   4619 From: rlane@club.cc.cmu.edu (Rich Lane)
   4620 Date: Tue, 18 Aug 2009 15:52:12 -0400
   4621 Subject: [sup-talk] crash when sup-syncing to xapian
   4622 In-Reply-To: <1250622911-sup-2815@localdomain>
   4623 References: <1250616603-sup-5612@ntdws12.chass.utoronto.ca>
   4624 	<1250619511-sup-2827@localdomain> <1250620771-sup-1373@zyrg.net>
   4625 	<1250622911-sup-2815@localdomain>
   4626 Message-ID: <1250624577-sup-4801@zyrg.net>
   4627 
   4628 Excerpts from Beno?t PIERRE's message of Tue Aug 18 15:17:03 -0400 2009:
   4629 > Excerpts from Rich Lane's message of Tue Aug 18 20:42:13 +0200 2009:
   4630 > > Excerpts from Beno?t PIERRE's message of Tue Aug 18 14:20:41 -0400 2009:
   4631 > > > Excerpts from Ben Walton's message of Tue Aug 18 19:35:35 +0200 2009:
   4632 > > > > 
   4633 > > > > I just tried to import my index to xapian and it crashed part way
   4634 > > > > through the import.  I then discovered that I couldn't use ferret
   4635 > > > > either.  There is something wonky with label handling, as per attached
   4636 > > > > exception log.  I haven't had a chance to look at the code yet, but
   4637 > > > > I'll poke at it tonight.
   4638 > > > 
   4639 > > > I think I just ran into the same problem! For now I fixed it with
   4640 > > > the following small patch:
   4641 > > 
   4642 > > That's odd because the Xapian code passes the labels straight through
   4643 > > from the message to LabelManager. Try instrumenting Message#labels= to
   4644 > > raise an exception if any member of the set is not a Symbol.
   4645 > 
   4646 > I applied the following patch:
   4647 > 
   4648 > diff --git a/lib/sup/message.rb b/lib/sup/message.rb
   4649 > index 965c10e..9156c02 100644
   4650 > --- a/lib/sup/message.rb
   4651 > +++ b/lib/sup/message.rb
   4652 > @@ -1,4 +1,5 @@
   4653 >  require 'time'
   4654 > +require 'pp'
   4655 > 
   4656 >  module Redwood
   4657 > 
   4658 > @@ -183,6 +184,7 @@ class Message
   4659 >    def labels= l
   4660 >      raise ArgumentError, "not a set" unless l.is_a?(Set)
   4661 >      return if @labels == l
   4662 > +    warn "labels=#{l.pretty_inspect}"
   4663 >      @labels = l
   4664 >      @dirty = true
   4665 >    end
   4666 > 
   4667 > And get this in the logs:
   4668 > 
   4669 > [Tue Aug 18 21:12:39 +0200 2009] WARNING: labels=#<Set: {:inbox, :unread,
   4670 > "aquarius", "music"}>
   4671 > [Tue Aug 18 21:12:39 +0200 2009] WARNING: labels=#<Set: {:inbox, :unread,
   4672 > "metalblade", "music"}>
   4673 > 
   4674 
   4675 It'd be nice to get a backtrace including the offending caller. I'd just
   4676 replace the warn with a fail.
   4677 
   4678 From benoit.pierre@gmail.com  Tue Aug 18 16:14:49 2009
   4679 From: benoit.pierre@gmail.com (=?utf-8?q?Beno=C3=AEt_PIERRE?=)
   4680 Date: Tue, 18 Aug 2009 22:14:49 +0200
   4681 Subject: [sup-talk] crash when sup-syncing to xapian
   4682 In-Reply-To: <1250624577-sup-4801@zyrg.net>
   4683 References: <1250616603-sup-5612@ntdws12.chass.utoronto.ca>
   4684 	<1250619511-sup-2827@localdomain> <1250620771-sup-1373@zyrg.net>
   4685 	<1250622911-sup-2815@localdomain> <1250624577-sup-4801@zyrg.net>
   4686 Message-ID: <1250626302-sup-2408@localdomain>
   4687 
   4688 Excerpts from Rich Lane's message of Tue Aug 18 21:52:12 +0200 2009:
   4689 > Excerpts from Beno?t PIERRE's message of Tue Aug 18 15:17:03 -0400 2009:
   4690 >
   4691 > [...]
   4692 > 
   4693 > It'd be nice to get a backtrace including the offending caller. I'd just
   4694 > replace the warn with a fail.
   4695 
   4696 The problem comes from my ~/.sup/sources.yaml file, the labels for a source
   4697 are not symbols:
   4698 
   4699     hash: 
   4700       relapse: true
   4701       music: true
   4702 
   4703 After converting them to symbols it works:
   4704 
   4705     hash: 
   4706       :relapse: true
   4707       :music: true
   4708 -- 
   4709 A: Because it destroys the flow of conversation.
   4710 Q: Why is top posting dumb?
   4711 -------------- next part --------------
   4712 A non-text attachment was scrubbed...
   4713 Name: signature.asc
   4714 Type: application/pgp-signature
   4715 Size: 197 bytes
   4716 Desc: not available
   4717 URL: <http://rubyforge.org/pipermail/sup-talk/attachments/20090818/94c721f9/attachment.bin>
   4718 
   4719 From cworth@cworth.org  Tue Aug 18 17:02:05 2009
   4720 From: cworth@cworth.org (Carl Worth)
   4721 Date: Tue, 18 Aug 2009 14:02:05 -0700
   4722 Subject: [sup-talk] What's your sup workflow (and a spew of ideas)
   4723 Message-ID: <1250629282-sup-8521@yoom>
   4724 
   4725 I'm now a few days into using sup, and it's clearly helped me to be
   4726 more productive at processing mail, (inbox is down to 0 from *lots* of
   4727 messages), so thanks!
   4728 
   4729 However, I still don't feel like I'm experiencing the zen of sup
   4730 yet. So I'm interested in hearing from others:
   4731 
   4732     What is your typical workflow with sup? That is:
   4733 
   4734     What different modes of task do you find yourself doing with sup?
   4735     Precisely what keystrokes do you use for those tasks?
   4736     Where, if anywhere, does sup get in your way rather than help?
   4737 
   4738 What follows is my (rather long) answer to those questions, and more
   4739 or less a todo list of things I'd like to help improve in sup.
   4740 
   4741 My desired workflow
   4742 ===================
   4743 I think there's a basic two-level approach I take to processing new
   4744 email. Fortunately, these two modes correspond well with sup's
   4745 inbox-mode and thread-view-mode. Here's what I'd like to do:
   4746 
   4747 Identify "unimportant" threads (no need to read)
   4748 ------------------------------------------------
   4749 This is a quick scan of the thread titles in my inbox. The goal here
   4750 is to identify as quickly as possible threads that I will never need
   4751 to read at all, (so that they can be immediately removed from my
   4752 inbox). Ideally, I will make a decision in one or two seconds, and
   4753 issue a single character command to indicate the decision.
   4754 
   4755 Dealing with remaining "important" threads
   4756 ------------------------------------------
   4757 After having eliminated as many threads as possible during the scan of
   4758 the inbox, I now switch to a mode where I'm actually looking at mail
   4759 messages. The goal here is to identify whether I need to do anything,
   4760 and how much time that will take. There are three possible outcomes:
   4761 
   4762     * No action needed
   4763 
   4764     * Quick action, (less than two minutes)
   4765 
   4766     * Longer action required (to assign to some project)
   4767 
   4768 (Any similarity to a method proposed by David Allen in Getting Things
   4769 Done is not accidental, and he deserves credit as such.)   
   4770 
   4771 Regardless of the three results, I will be quickly archiving the
   4772 thread so that it's gone from my inbox. That will be either immediate
   4773 archiving, archiving after a quick action (such as a reply), or
   4774 archiving after tagging the thread with a label for the appropriate
   4775 project.
   4776 
   4777 How sup could support my workflow better
   4778 ========================================
   4779 So sup obviously fits in quite well with the above model---which is
   4780 why I immediately fell in love with it. So first of all I have to
   4781 again say thank you. And I apologize that I will go into more detail
   4782 on the things I'd like to change in sup as opposed to the things that
   4783 already work so well. This isn't a criticism of the tool, just an
   4784 expression of my desire to improve it.
   4785 
   4786 I'll phrase the list below as feature requests. Some of these things
   4787 may already exist in sup, and I just missed them. In such cases, I'll
   4788 be glad to hear pointers to the things I missed. Otherwise, I plan to
   4789 work on developing patches for these, and I'll be glad for any help.
   4790 
   4791 I'll give each feature a name in [square-brackets] for easy reference in followup messages.
   4792 
   4793 inbox-mode
   4794 -----------
   4795 * [black-on-white-color-scheme]
   4796 
   4797   We've talked in another thread about adding support for a
   4798   black-text-on-white-background color scheme to sup-config. Before I
   4799   can write a patch for that, does somebody have an example
   4800   black-on-white color scheme that works well? I've been trying to
   4801   come up with one but I've been unable to find how to change some
   4802   colors, specifically:
   4803 
   4804   + [change-color-of-thread-selector]
   4805 
   4806     The selector for the current thread in thread-mode appears as
   4807     black-foreground-on-cyan right now. I haven't been able to find
   4808     the setting to make that a more easy-to-read background color, and
   4809     this is the only line in the view that isn't bold when unread,
   4810     (which is not ideal since it's the only line I'm trying to read
   4811     and process).
   4812 
   4813   + [change-color-of-tag-markers]
   4814 
   4815     The tag markers are yellow, which is hard to see on white. I also
   4816     couldn't find the setting to change this.
   4817 
   4818 * [import-read-messages-as-archived-from-initial-sup-config-based-sync]
   4819   
   4820   When I very first started using sup, (running sup-config which setup
   4821   sources and ran sup-sync) I was surprised to find my inbox with
   4822   thousands of unread messages in it. Now that I'm using sup more I
   4823   love that sup treats inbox and unread as separate labels, (far too
   4824   many email programs fail to separate those notions). But for that
   4825   initial import, I think it would have been much more useful to have
   4826   only given the inbox tag to unread messages.
   4827 
   4828 * [sort-priority-labels-before-date]
   4829  
   4830   The default sorting for the inbox is reverse-chronological which is
   4831   a reasonable-enough default, (and works fine for me when I keep my
   4832   inbox small). But when I get behind and my inbox gets large, (say
   4833   after a few days away from email), I do have some tags that I would
   4834   like to be sorted to the top, regardless of date. How about support
   4835   for a configurable list of "priority" tags that would provide a
   4836   primary sort before the date-based sort?
   4837 
   4838 * [save-all-state-changes-immediately]
   4839 
   4840   The 'a' and 'd' commands do almost exactly what I expect, (by
   4841   immediately making the current thread disappear and advancing the
   4842   selector to the next thread). That's perfect for fast
   4843   processing. One thing missing here is that they don't actually save
   4844   this state, (requiring me to hit '$' at some point). Perhaps that
   4845   safety feature was more important before undo was implemented, but
   4846   now that it exists, would immediate state saving make sense?
   4847 
   4848   The two bad side effects I've experienced due to lack of immediate
   4849   saving are: 1. Seeing confusingly inconsistent results after
   4850   processing a bunch of my inbox and then doing a search based on
   4851   label:unread or label:inbox (Why am I seeing all these messages
   4852   again?). 2. Losing a bunch of processing state due to crashes. (The
   4853   crashes have been due to the mbox-processing bug which has since
   4854   been fixed, but being immune to state loss for any future crashes
   4855   would be beneficial.)
   4856 
   4857 search-results-mode
   4858 -------------------
   4859 * [provide-commands-to-refine-the-current-search]
   4860 
   4861   I mentioned above wanting to sort priority labels before
   4862   date. Similarly, when processing a very large email I sometimes want
   4863   to process related messages together, (to reduce mental context
   4864   switches). So I want variants of both "\, F: Search all messages"
   4865   and "L: list labels" search commands that refine the current search
   4866   rather than doing a new global search. That is, the new commands
   4867   would simply append new search terms to the current search rather
   4868   than starting a new search.
   4869 
   4870 * [allow-for-inbox-mode-magic-elsewhere]
   4871 
   4872   Another way to reword this one would be to "eliminate any magic of
   4873   inbox mode". My question is, "What makes inbox-mode different than
   4874   search-results-mode and how can I get the behavior of inbox-mode in
   4875   my searches?".
   4876 
   4877   Without commands to refine the current search as described above,
   4878   I've been trying to achieve results like "inbox refined to
   4879   label:foo" with a search as follows:
   4880 
   4881 	label:inbox -label:killed label:foo
   4882 
   4883   This gives me the set of threads that I want, but now my standard
   4884   processing commands no longer work. For example, the 'a' key still
   4885   removes the inbox label, but it doesn't make the tag then disappear
   4886   immediately.
   4887 
   4888   One approach to fix this would be that when adding the commands to
   4889   refine the inbox search, the new search results would also be in
   4890   inbox-mode with all necessary magic.
   4891 
   4892   A more general fix would be to process the current thread after any
   4893   changes, (such as the addition or removal of a label), and removing
   4894   it from the current search results if it no longer meets those
   4895   criteria.
   4896 
   4897 * [fix-handling-of-kill-thread-outside-inbox]
   4898 
   4899   The handling of the "&: kill thread" command when applied outside of
   4900   the inbox, (such as in search-results-mode), is currently very
   4901   confusing. What it currently seems to do is to add the killed label
   4902   and make the thread disappear from the current view. But then,
   4903   running "@: Refresh view" will make it reappear, (whereupon one can
   4904   make it disappear again with &, ad infinitum). The removal of the
   4905   thread from the current view seems to be magic associated with the
   4906   kill-thread command, (leading to inconsistent behavior). I would
   4907   again suggest to instead implement the general fix described above,
   4908   (always reprocessing a thread after label changes to see if it still
   4909   meets the current search). That way, trying to kill a thread without
   4910   -label:killed in the current search would simply add the "killed"
   4911   label and the user would learn to add the necessary search terms,
   4912   (or to do searches based on refining the searches of existing views
   4913   to inherit this term).
   4914 
   4915 thread-view-mode
   4916 ----------------
   4917 * [override-arrow-keys-to-jump-to-next-actionable-line]
   4918 
   4919   In thread-view-mode the up and down arrows currently advance a
   4920   selector by one line at a time, (inherited from line-cursor-mode),
   4921   all the way into message bodies. As far as I can tell, this is not a
   4922   useful behavior. I propose that the down arrow key should instead
   4923   advance the selector to the next line which would cause a context
   4924   change for the various operations that can be performed based on the
   4925   selector, (or scroll to the next page if there are no such lines on
   4926   the current or next page).
   4927 
   4928 * [be-less-overzealous-in-moving-text-to-the-left-column]
   4929 
   4930   I tend to use sup in a very wide terminal, (200+ columns). And I'm
   4931   glad to see that the inbox-mode takes advantage of this by showing a
   4932   preview of the message body (that's a nice touch!) where many
   4933   console-based clients just cut things off at 80 columns.
   4934 
   4935   However, in thread-view-mode, sup always pushes the current message
   4936   all the way over to the left-hand column. This does mean that the
   4937   "current" message is visible, but I have a tendency to read much
   4938   more than the current message, (even before advancing), and
   4939   subsequent messages are often scrolled such that the first several
   4940   columns of text are scrolled off to the left. Meanwhile, I have
   4941   acres of terminal real-estate to the right that sup isn't using.
   4942 
   4943   I would propose that messages only be scrolled to the left if
   4944   necessary to avoid the 80th column of the message body not being
   4945   visible, (assuming the terminal is at least 80 columns wide).
   4946 
   4947 compose-mode
   4948 ------------
   4949 * [repeated-postponing-shouldnt-make-additional-drafts]
   4950 
   4951   I find that while composing a message I often want to go look at
   4952   some other messages for reference. This is currently quite awkward
   4953   with sup. It would be easier if sup could be run multiple times. It
   4954   would also be easier if sup could somehow fire off an editor as an
   4955   external process, while still allowing for sup to be operated.
   4956 
   4957   As it stands, instead, I have to save and quit from my editor,
   4958   postpone the message within sup, and then later come back to edit it
   4959   again, and find where I was in the editor. It's an expensive context
   4960   switch with a lot of keystrokes and lost state, (such as where point
   4961   was inside emacs, my kill ring, etc.). I'm currently finding myself
   4962   sometimes just drafting messages in emacs sessions unrelated to sup,
   4963   and then doing "M-x insert-file" once sup has launched emacs for
   4964   me. (This does relate a bit to the point I made in a previous thread
   4965   where I would love to find a way to keep all the mail-composition
   4966   tasks very separate from sup, but not lose things like replied-to
   4967   bits.)
   4968 
   4969   Anyway, the current misfeature I'm hitting is that if I do postpone
   4970   a draft, then return to edit it more, then postpone it again,
   4971   etc. eventually when I send the message I'll have several
   4972   partially-composed drafts in various states that I need to go and
   4973   manually clean up. It seems like most email programs avoid this
   4974   problem by removing the draft as soon as its selected for editing
   4975   again, and I propose that sup do the same.
   4976 
   4977 Anyway, I've probably run into several other little things that I
   4978 didn't capture in this email, but I'll hopefully remember them
   4979 later. If anyone has feedback on any of the above, (and actually read
   4980 this far!), then I'll appreciate getting it.
   4981 
   4982 Otherwise, like I said, I hope to start trying to implement some of
   4983 these ideas, and when I do, I'll of course come back with separate new
   4984 threads for each.
   4985 
   4986 -Carl
   4987 
   4988 -------------- next part --------------
   4989 A non-text attachment was scrubbed...
   4990 Name: signature.asc
   4991 Type: application/pgp-signature
   4992 Size: 189 bytes
   4993 Desc: not available
   4994 URL: <http://rubyforge.org/pipermail/sup-talk/attachments/20090818/43f15a25/attachment.bin>
   4995 
   4996 From pioto@pioto.org  Tue Aug 18 13:30:34 2009
   4997 From: pioto@pioto.org (Mike Kelly)
   4998 Date: Tue, 18 Aug 2009 13:30:34 -0400
   4999 Subject: [sup-talk] Crash w/ current 'next'
   5000 Message-ID: <aeb4682e1581f7534cb1c81bd143dbc6@pioto.org>
   5001 
   5002 Hi,
   5003 
   5004 I just built from the current next branch, and now whenever I load sup, it
   5005 gives me the attached crash.
   5006 
   5007 I'm guessing this is related to the Set thing William mentioned, but I have
   5008 just gone from an older 'next' to a newer one, which I thought was supposed
   5009 to not have this problem.
   5010 
   5011 Any suggestions?
   5012 
   5013 -- 
   5014 Mike Kelly
   5015 -------------- next part --------------
   5016 --- ArgumentError from thread: poll after loading inbox
   5017 expecting a symbol
   5018 /usr/home/staff/mike/lib/ruby/gems/1.8/gems/sup-999/lib/sup/label.rb:64:in `<<'
   5019 /usr/home/staff/mike/lib/ruby/gems/1.8/gems/sup-999/lib/sup/util.rb:520:in `send'
   5020 /usr/home/staff/mike/lib/ruby/gems/1.8/gems/sup-999/lib/sup/util.rb:520:in `method_missing'
   5021 /usr/home/staff/mike/lib/ruby/gems/1.8/gems/sup-999/lib/sup/poll.rb:149:in `each_message_from'
   5022 /usr/local/lib/ruby/1.8/set.rb:195:in `each'
   5023 /usr/local/lib/ruby/1.8/set.rb:195:in `each_key'
   5024 /usr/local/lib/ruby/1.8/set.rb:195:in `each'
   5025 /usr/home/staff/mike/lib/ruby/gems/1.8/gems/sup-999/lib/sup/poll.rb:149:in `each_message_from'
   5026 /usr/home/staff/mike/lib/ruby/gems/1.8/gems/sup-999/lib/sup/source.rb:104:in `each'
   5027 /usr/home/staff/mike/lib/ruby/gems/1.8/gems/sup-999/lib/sup/util.rb:560:in `send'
   5028 /usr/home/staff/mike/lib/ruby/gems/1.8/gems/sup-999/lib/sup/util.rb:560:in `__pass'
   5029 /usr/home/staff/mike/lib/ruby/gems/1.8/gems/sup-999/lib/sup/util.rb:547:in `method_missing'
   5030 /usr/home/staff/mike/lib/ruby/gems/1.8/gems/sup-999/lib/sup/poll.rb:140:in `each_message_from'
   5031 /usr/home/staff/mike/lib/ruby/gems/1.8/gems/sup-999/lib/sup/poll.rb:93:in `do_poll'
   5032 /usr/home/staff/mike/lib/ruby/gems/1.8/gems/sup-999/lib/sup/poll.rb:81:in `each'
   5033 /usr/home/staff/mike/lib/ruby/gems/1.8/gems/sup-999/lib/sup/poll.rb:81:in `do_poll'
   5034 /usr/home/staff/mike/lib/ruby/gems/1.8/gems/sup-999/lib/sup/poll.rb:80:in `synchronize'
   5035 /usr/home/staff/mike/lib/ruby/gems/1.8/gems/sup-999/lib/sup/poll.rb:80:in `do_poll'
   5036 /usr/home/staff/mike/lib/ruby/gems/1.8/gems/sup-999/lib/sup/util.rb:520:in `send'
   5037 /usr/home/staff/mike/lib/ruby/gems/1.8/gems/sup-999/lib/sup/util.rb:520:in `method_missing'
   5038 /usr/home/staff/mike/lib/ruby/gems/1.8/gems/sup-999/lib/sup/modes/poll-mode.rb:15:in `poll'
   5039 /usr/home/staff/mike/lib/ruby/gems/1.8/gems/sup-999/lib/sup/poll.rb:48:in `poll'
   5040 /usr/home/staff/mike/lib/ruby/gems/1.8/gems/sup-999/lib/sup/util.rb:520:in `send'
   5041 /usr/home/staff/mike/lib/ruby/gems/1.8/gems/sup-999/lib/sup/util.rb:520:in `method_missing'
   5042 /usr/home/staff/mike/lib/ruby/gems/1.8/gems/sup-999/bin/sup:190
   5043 /usr/home/staff/mike/lib/ruby/gems/1.8/gems/sup-999/lib/sup.rb:77:in `reporting_thread'
   5044 /usr/home/staff/mike/lib/ruby/gems/1.8/gems/sup-999/lib/sup.rb:75:in `initialize'
   5045 /usr/home/staff/mike/lib/ruby/gems/1.8/gems/sup-999/lib/sup.rb:75:in `new'
   5046 /usr/home/staff/mike/lib/ruby/gems/1.8/gems/sup-999/lib/sup.rb:75:in `reporting_thread'
   5047 /usr/home/staff/mike/lib/ruby/gems/1.8/gems/sup-999/bin/sup:190
   5048 /usr/home/staff/mike/lib/ruby/gems/1.8/gems/sup-999/lib/sup/modes/thread-index-mode.rb:666:in `call'
   5049 /usr/home/staff/mike/lib/ruby/gems/1.8/gems/sup-999/lib/sup/modes/thread-index-mode.rb:666:in `__unprotected_load_threads'
   5050 /usr/home/staff/mike/lib/ruby/gems/1.8/gems/sup-999/lib/sup/modes/thread-index-mode.rb:608:in `call'
   5051 /usr/home/staff/mike/lib/ruby/gems/1.8/gems/sup-999/lib/sup/modes/thread-index-mode.rb:608:in `load_n_threads_background'
   5052 /usr/home/staff/mike/lib/ruby/gems/1.8/gems/sup-999/lib/sup.rb:77:in `reporting_thread'
   5053 /usr/home/staff/mike/lib/ruby/gems/1.8/gems/sup-999/lib/sup.rb:75:in `initialize'
   5054 /usr/home/staff/mike/lib/ruby/gems/1.8/gems/sup-999/lib/sup.rb:75:in `new'
   5055 /usr/home/staff/mike/lib/ruby/gems/1.8/gems/sup-999/lib/sup.rb:75:in `reporting_thread'
   5056 /usr/home/staff/mike/lib/ruby/gems/1.8/gems/sup-999/lib/sup/modes/thread-index-mode.rb:606:in `load_n_threads_background'
   5057 /usr/home/staff/mike/lib/ruby/gems/1.8/gems/sup-999/lib/sup/modes/thread-index-mode.rb:676:in `__unprotected_load_threads'
   5058 (eval):12:in `load_threads'
   5059 /usr/home/staff/mike/lib/ruby/gems/1.8/gems/sup-999/bin/sup:190
   5060 /usr/home/staff/mike/lib/ruby/gems/1.8/bin/sup:19:in `load'
   5061 /usr/home/staff/mike/lib/ruby/gems/1.8/bin/sup:19
   5062 
   5063 From cworth@cworth.org  Tue Aug 18 17:46:41 2009
   5064 From: cworth@cworth.org (Carl Worth)
   5065 Date: Tue, 18 Aug 2009 14:46:41 -0700
   5066 Subject: [sup-talk] What's your sup workflow (and a spew of ideas)
   5067 In-Reply-To: <1250629282-sup-8521@yoom>
   5068 References: <1250629282-sup-8521@yoom>
   5069 Message-ID: <1250631221-sup-8993@yoom>
   5070 
   5071 Excerpts from Carl Worth's message of Tue Aug 18 14:02:05 -0700 2009:
   5072 > Anyway, I've probably run into several other little things that I
   5073 > didn't capture in this email, but I'll hopefully remember them
   5074 > later.
   5075 
   5076 And of course, here are a few:
   5077 
   5078 inbox-mode
   5079 ----------
   5080  * [dont-perturb-selected-thread-when-new-mail-arrives]
   5081 
   5082    I think I just saw the following race condition:
   5083 
   5084 	1. I have the top-most thread selected and I identify it as spam
   5085 	2. I start moving to press the d key to delete it
   5086 	3. Before I get their, new mail arrives and becomes selected
   5087 	4. I delete mail I really care about
   5088 
   5089    I propose that new mail arriving should not cause the selector to
   5090    move from the thread currently selected.
   5091 
   5092 label-list-mode
   5093 ---------------
   5094  * [allow-for-limiting-to-interesting-labels]
   5095 
   5096    In the workflow I described earlier, I process all mail mercilessly
   5097    and get it archived and out of my inbox as quickly as possible. But
   5098    some of those threads I identified as needing some significant time
   5099    to deal with, so I labelled them to assign them to a particular
   5100    "project".
   5101 
   5102    So, later, I'd like to look at my list of projects, choose one, and
   5103    then choose the first task to be done.
   5104 
   5105    The label-list-mode is *almost* the perfect thing for this. The
   5106    only problem is that it displays several labels, (with *lots* of
   5107    messages each) that are not interesting to me at all in this
   5108    sense. For example, killed and unread, for example, as well as
   5109    several other labels that I use in ways other than my "project"
   5110    labels.
   5111 
   5112    What I'd like here is a feature much like 'u' which toggles to
   5113    display of only labels with unread messages, but insteads toggles
   5114    to display only the labels that I've somehow marked as my "project"
   5115    labels. (I'm not sure exactly how to name this feature for general
   5116    use. The "project" sense is something personal to my usage. Maybe,
   5117    "todo" or something?)
   5118 
   5119 inbox-mode/search-result-mode
   5120 -----------------------------
   5121 * [display-number-of-unread-messages]
   5122 
   5123   In my ruthless scan while processing new messages, I want to be able
   5124   to make split-second, yet accurate, decisions on whether I need to
   5125   read messages, (and if so, how much time it will take). The current
   5126   thread display shows a total number of messages within a thread, but
   5127   that leads to me making an inaccurate estimate of how "expensive" it
   5128   would be to read a thread. I'd much rather see the number of unread
   5129   messages in the thread. Perhaps best would be to diplay both numbers
   5130   such as: (1/64) with the 1 in bold to indicate that a thread with 64
   5131   total messages has 1 unread message.
   5132 
   5133 -Carl
   5134 -------------- next part --------------
   5135 A non-text attachment was scrubbed...
   5136 Name: signature.asc
   5137 Type: application/pgp-signature
   5138 Size: 189 bytes
   5139 Desc: not available
   5140 URL: <http://rubyforge.org/pipermail/sup-talk/attachments/20090818/5f65c5b3/attachment.bin>
   5141 
   5142 From garoth@gmail.com  Tue Aug 18 18:07:28 2009
   5143 From: garoth@gmail.com (Andrei Thorp)
   5144 Date: Tue, 18 Aug 2009 18:07:28 -0400
   5145 Subject: [sup-talk] What's your sup workflow (and a spew of ideas)
   5146 In-Reply-To: <1250629282-sup-8521@yoom>
   5147 References: <1250629282-sup-8521@yoom>
   5148 Message-ID: <1250632714-sup-9910@Longbow>
   5149 
   5150 Excerpts from Carl Worth's message of Tue Aug 18 17:02:05 -0400 2009:
   5151 > * [sort-priority-labels-before-date]
   5152 >  
   5153 >   The default sorting for the inbox is reverse-chronological which is
   5154 >   a reasonable-enough default, (and works fine for me when I keep my
   5155 >   inbox small). But when I get behind and my inbox gets large, (say
   5156 >   after a few days away from email), I do have some tags that I would
   5157 >   like to be sorted to the top, regardless of date. How about support
   5158 >   for a configurable list of "priority" tags that would provide a
   5159 >   primary sort before the date-based sort?
   5160 
   5161 Yeah, I'd really really like this also. This has been discussed, and in
   5162 general, it'd be lovely to be able to sort by hook or something. I think
   5163 grouping by labels first and then by time would be a good default.
   5164 
   5165 > * [save-all-state-changes-immediately]
   5166 > 
   5167 >   The 'a' and 'd' commands do almost exactly what I expect, (by
   5168 >   immediately making the current thread disappear and advancing the
   5169 >   selector to the next thread). That's perfect for fast
   5170 >   processing. One thing missing here is that they don't actually save
   5171 >   this state, (requiring me to hit '$' at some point). Perhaps that
   5172 >   safety feature was more important before undo was implemented, but
   5173 >   now that it exists, would immediate state saving make sense?
   5174 > 
   5175 >   The two bad side effects I've experienced due to lack of immediate
   5176 >   saving are: 1. Seeing confusingly inconsistent results after
   5177 >   processing a bunch of my inbox and then doing a search based on
   5178 >   label:unread or label:inbox (Why am I seeing all these messages
   5179 >   again?). 2. Losing a bunch of processing state due to crashes. (The
   5180 >   crashes have been due to the mbox-processing bug which has since
   5181 >   been fixed, but being immune to state loss for any future crashes
   5182 >   would be beneficial.)
   5183 
   5184 I assume here that part of the problem is the time it takes to write
   5185 changes. If I read all my morning e-mails and then press $, it usually
   5186 takes a few seconds for this to finish. If it's just one e-mail, there
   5187 is still usually a noticeable-ish delay.
   5188 
   5189 However, perhaps Xapian will improve this speed also, and if this is the
   5190 case, I'd love an "autosave" option at least in the config.
   5191 > * [repeated-postponing-shouldnt-make-additional-drafts]
   5192 > 
   5193 >   I find that while composing a message I often want to go look at
   5194 >   some other messages for reference. This is currently quite awkward
   5195 >   with sup. It would be easier if sup could be run multiple times. It
   5196 >   would also be easier if sup could somehow fire off an editor as an
   5197 >   external process, while still allowing for sup to be operated.
   5198 > 
   5199 >   As it stands, instead, I have to save and quit from my editor,
   5200 >   postpone the message within sup, and then later come back to edit it
   5201 >   again, and find where I was in the editor. It's an expensive context
   5202 >   switch with a lot of keystrokes and lost state, (such as where point
   5203 >   was inside emacs, my kill ring, etc.). I'm currently finding myself
   5204 >   sometimes just drafting messages in emacs sessions unrelated to sup,
   5205 >   and then doing "M-x insert-file" once sup has launched emacs for
   5206 >   me. (This does relate a bit to the point I made in a previous thread
   5207 >   where I would love to find a way to keep all the mail-composition
   5208 >   tasks very separate from sup, but not lose things like replied-to
   5209 >   bits.)
   5210 > 
   5211 >   Anyway, the current misfeature I'm hitting is that if I do postpone
   5212 >   a draft, then return to edit it more, then postpone it again,
   5213 >   etc. eventually when I send the message I'll have several
   5214 >   partially-composed drafts in various states that I need to go and
   5215 >   manually clean up. It seems like most email programs avoid this
   5216 >   problem by removing the draft as soon as its selected for editing
   5217 >   again, and I propose that sup do the same.
   5218 
   5219 I think I agree there, and vaguely recall someone attempting to
   5220 implement being able to switch buffers even when an external editor is
   5221 in effect.
   5222 
   5223 Anyway, impressive post there. You seem to really abuse your e-mail
   5224 client and know what you're on about. Good stuff.
   5225 -- 
   5226 Andrei Thorp, Developer: Xandros Corp. (http://www.xandros.com)
   5227 
   5228 From cworth@cworth.org  Tue Aug 18 18:16:08 2009
   5229 From: cworth@cworth.org (Carl Worth)
   5230 Date: Tue, 18 Aug 2009 15:16:08 -0700
   5231 Subject: [sup-talk] What's your sup workflow (and a spew of ideas)
   5232 In-Reply-To: <1250632714-sup-9910@Longbow>
   5233 References: <1250629282-sup-8521@yoom> <1250632714-sup-9910@Longbow>
   5234 Message-ID: <1250633501-sup-3981@yoom>
   5235 
   5236 Excerpts from Andrei Thorp's message of Tue Aug 18 15:07:28 -0700 2009:
   5237 > Excerpts from Carl Worth's message of Tue Aug 18 17:02:05 -0400 2009:
   5238 > >   Anyway, the current misfeature I'm hitting is that if I do postpone
   5239 > >   a draft, then return to edit it more, then postpone it again,
   5240 > >   etc. eventually when I send the message I'll have several
   5241 > >   partially-composed drafts in various states that I need to go and
   5242 > >   manually clean up. It seems like most email programs avoid this
   5243 > >   problem by removing the draft as soon as its selected for editing
   5244 > >   again, and I propose that sup do the same.
   5245 > 
   5246 > I think I agree there, and vaguely recall someone attempting to
   5247 > implement being able to switch buffers even when an external editor is
   5248 > in effect.
   5249 
   5250 That would be nice. In the meantime, I have realized that I don't need
   5251 to actually postpone my messages to do what I want---I can just exit
   5252 the editor and then switch buffers from compose-mode/reply-mode. So
   5253 that at least avoids the multiple-drafts issue, (but still leaves the
   5254 I-lose-my-state-when-I-quit-the-editor issue).
   5255 
   5256 > Anyway, impressive post there. You seem to really abuse your e-mail
   5257 > client and know what you're on about. Good stuff.
   5258 
   5259 Thanks. I have had a lot of ideas cooking for years about what my
   5260 dream email-system would look like. I think the impressive bit is that
   5261 of the half-dozen programs I've used in the last decade, sup is the
   5262 first one to get me to write up a post like that. (All other programs
   5263 were so far away from what I wanted as to make it infeasible to fix
   5264 them incrementally.)
   5265 
   5266 -Carl
   5267 -------------- next part --------------
   5268 A non-text attachment was scrubbed...
   5269 Name: signature.asc
   5270 Type: application/pgp-signature
   5271 Size: 189 bytes
   5272 Desc: not available
   5273 URL: <http://rubyforge.org/pipermail/sup-talk/attachments/20090818/6e240f41/attachment.bin>
   5274 
   5275 From rlane@club.cc.cmu.edu  Tue Aug 18 19:02:01 2009
   5276 From: rlane@club.cc.cmu.edu (Rich Lane)
   5277 Date: Tue, 18 Aug 2009 19:02:01 -0400
   5278 Subject: [sup-talk] What's your sup workflow (and a spew of ideas)
   5279 In-Reply-To: <1250629282-sup-8521@yoom>
   5280 References: <1250629282-sup-8521@yoom>
   5281 Message-ID: <1250634897-sup-4631@zyrg.net>
   5282 
   5283 provide-commands-to-refine-the-current-search:
   5284 
   5285 '|' exists for search-results-mode (and it should be implemented for
   5286 label-results-mode if it doesn't exist there).
   5287 
   5288 
   5289 sort-priority-labels-before-date:
   5290 
   5291 This isn't entirely easy for large numbers of messages. We've optimized
   5292 the index (especially Xapian) for reverse chronological order. You could
   5293 either do the sorting entirely in the UI, but just on the subset of
   5294 results currently loaded, or you could create a new mode that merges and
   5295 prioritizes the results of multiple queries.
   5296 
   5297 
   5298 allow-for-limiting-to-interesting-labels:
   5299 
   5300 I have a hack for this. I reopen Redwood::Mode in the startup hook, then
   5301 add a keybinding to spawn a SearchResultsMode for a set of interesting
   5302 labels. Same for starred messages. A better solution would be good.
   5303 
   5304 
   5305 save-all-state-changes-immediately,
   5306 allow-for-inbox-mode-magic-elsewhere,
   5307 fix-handling-of-kill-thread-outside-inbox:
   5308 
   5309 These are related - saving label changes immediately means we can use
   5310 the index to decide which threads are relevant. The new index api
   5311 methods unblock this, and now that they're in next I plan to implement
   5312 this soon.
   5313 
   5314 
   5315 be-less-overzealous-in-moving-text-to-the-left-column,
   5316 dont-perturb-selected-thread-when-new-mail-arrives:
   5317 
   5318 +1 to these.
   5319 
   5320 From kevinr@free-dissociation.com  Tue Aug 18 19:36:15 2009
   5321 From: kevinr@free-dissociation.com (Kevin Riggle)
   5322 Date: Tue, 18 Aug 2009 19:36:15 -0400
   5323 Subject: [sup-talk] [PATCH] Add an after-add-message hook
   5324 In-Reply-To: <1250618123-sup-8797@masanjin.net>
   5325 References: <1250459229-4500-1-git-send-email-kevinr@free-dissociation.com>
   5326 	<1250618123-sup-8797@masanjin.net>
   5327 Message-ID: <1250638381-sup-2952@black-opal.mit.edu>
   5328 
   5329 Excerpts from William Morgan's message of Tue Aug 18 13:56:15 -0400 2009:
   5330 > Reformatted excerpts from Kevin Riggle's message of 2009-08-16:
   5331 > > I want to do some unrelated processing on each message I receive, but
   5332 > > I don't want to block the message being added to the index.  This
   5333 > > patch adds a hook which runs /after/ the message is added to the
   5334 > > index.
   5335 > 
   5336 > Won't this block subsequent emails from being added to the index, when
   5337 > Sup gets multiple new emails during a poll?
   5338 
   5339 I don't /think/ so, unless I misunderstand the way hooks work.  I assumed
   5340 the hook would execute and then execution of the loop would resume, and
   5341 I don't think I throw anything in the hook which should cause that either.
   5342 
   5343 - Kevin
   5344 -- 
   5345 Kevin Riggle (kevinr at free-dissociation.com) 
   5346 http://free-dissociation.com
   5347 
   5348 From bwalton@artsci.utoronto.ca  Tue Aug 18 20:03:49 2009
   5349 From: bwalton@artsci.utoronto.ca (Ben Walton)
   5350 Date: Tue, 18 Aug 2009 20:03:49 -0400
   5351 Subject: [sup-talk] crash when sup-syncing to xapian
   5352 In-Reply-To: <1250626302-sup-2408@localdomain>
   5353 References: <1250616603-sup-5612@ntdws12.chass.utoronto.ca>
   5354 	<1250619511-sup-2827@localdomain> <1250620771-sup-1373@zyrg.net>
   5355 	<1250622911-sup-2815@localdomain> <1250624577-sup-4801@zyrg.net>
   5356 	<1250626302-sup-2408@localdomain>
   5357 Message-ID: <1250640188-sup-7551@ntdws12.chass.utoronto.ca>
   5358 
   5359 Excerpts from Beno?t PIERRE's message of Tue Aug 18 16:14:49 -0400 2009:
   5360 
   5361 > After converting them to symbols it works:
   5362 > 
   5363 >     hash: 
   5364 >       :relapse: true
   5365 >       :music: true
   5366 
   5367 I have labels setup to import as an array (of strings)...is this not
   5368 the way it's supposed to be?
   5369 
   5370 -Ben
   5371 -- 
   5372 Ben Walton
   5373 Systems Programmer - CHASS
   5374 University of Toronto
   5375 C:416.407.5610 | W:416.978.4302
   5376 
   5377 GPG Key Id: 8E89F6D2; Key Server: pgp.mit.edu
   5378 Contact me to arrange for a CAcert assurance meeting.
   5379 -------------- next part --------------
   5380 A non-text attachment was scrubbed...
   5381 Name: signature.asc
   5382 Type: application/pgp-signature
   5383 Size: 189 bytes
   5384 Desc: not available
   5385 URL: <http://rubyforge.org/pipermail/sup-talk/attachments/20090818/9e8e3a03/attachment.bin>
   5386 
   5387 From cworth@cworth.org  Tue Aug 18 20:49:03 2009
   5388 From: cworth@cworth.org (Carl Worth)
   5389 Date: Tue, 18 Aug 2009 17:49:03 -0700
   5390 Subject: [sup-talk] Exception trying to run git source
   5391 Message-ID: <1250642676-sup-2244@yoom>
   5392 
   5393 Until now I've been running sup 0.8.1 from a Debian package. But in an
   5394 effort to get to where I can actually start implementing some of the
   5395 features I want, (and to get to where I can actually send a message
   5396 without triggering sent.mbox crashes), I'm trying to move to running
   5397 sup from a git checkout. But whenever I try, I get the following
   5398 exception:
   5399 
   5400     --- NoMethodError from thread: main
   5401     undefined method `source_uri' for #<Redwood::SentManager:0xb74f1160 @source=nil, @fn="sup://sent">
   5402     ./lib/sup/util.rb:519:in `send'
   5403     ./lib/sup/util.rb:519:in `method_missing'
   5404     bin/sup:171
   5405 
   5406 I bisected this down to the following commit:
   5407 
   5408     commit 5057149d9c3b57c6b5c4d0964a0aae9d490aaa38
   5409     Author: Ben Walton <bwalton at artsci.utoronto.ca>
   5410     Date:   Wed May 6 22:44:24 2009 -0400
   5411     
   5412         SentManager: rework handling to allow for user specified source
   5413 
   5414 That looks like an awfully nice commit since I'd like my sent messages
   5415 to go into a maildir anyway. So I tried configuring this by adding a
   5416 line to my ~/.sup/config.yaml as follows:
   5417 
   5418     :sent_source: maildir:/home/cworth/mail/sent
   5419 
   5420 That didn't actually help too much, it just changed the stack trace
   5421 slightly:
   5422 
   5423     --- NoMethodError from thread: main
   5424     undefined method `source_uri' for #<Redwood::SentManager:0xb73ce404>
   5425     ./lib/sup/util.rb:519:in `send'
   5426     ./lib/sup/util.rb:519:in `method_missing'
   5427     bin/sup:171
   5428 
   5429 So what am I actually missing here?
   5430 
   5431 -Carl
   5432 -------------- next part --------------
   5433 A non-text attachment was scrubbed...
   5434 Name: signature.asc
   5435 Type: application/pgp-signature
   5436 Size: 189 bytes
   5437 Desc: not available
   5438 URL: <http://rubyforge.org/pipermail/sup-talk/attachments/20090818/a004f5e4/attachment.bin>
   5439 
   5440 From cworth@cworth.org  Tue Aug 18 21:58:55 2009
   5441 From: cworth@cworth.org (Carl Worth)
   5442 Date: Tue, 18 Aug 2009 18:58:55 -0700
   5443 Subject: [sup-talk] What's your sup workflow (and a spew of ideas)
   5444 In-Reply-To: <1250634897-sup-4631@zyrg.net>
   5445 References: <1250629282-sup-8521@yoom> <1250634897-sup-4631@zyrg.net>
   5446 Message-ID: <1250646478-sup-4064@yoom>
   5447 
   5448 Excerpts from Rich Lane's message of Tue Aug 18 16:02:01 -0700 2009:
   5449 > provide-commands-to-refine-the-current-search:
   5450 > 
   5451 > '|' exists for search-results-mode (and it should be implemented for
   5452 > label-results-mode if it doesn't exist there).
   5453 
   5454 Ah, thanks for pointing this out. I totally missed it somehow.
   5455 
   5456 This doesn't exist for inbox-mode, which is where I think I would like
   5457 it the most. And conceptually, the inbox is just a search, right? It
   5458 seems to me that inbox-mode should be at most a very slight tweak of
   5459 search-results-mode. I'll go digging in the code to see how far away
   5460 that would be.
   5461 
   5462 For what it's worth, | doesn't exist for search-results mode.
   5463 
   5464 And also, the shortcuts to refine the search by adding a label would
   5465 be nice too, (so one wouldn't need to type "label:"). So now I at
   5466 least know what already exists.
   5467 
   5468 > sort-priority-labels-before-date:
   5469 > 
   5470 > This isn't entirely easy for large numbers of messages. We've optimized
   5471 > the index (especially Xapian) for reverse chronological order. You could
   5472 > either do the sorting entirely in the UI, but just on the subset of
   5473 > results currently loaded, or you could create a new mode that merges and
   5474 > prioritizes the results of multiple queries.
   5475 
   5476 I think the former would be fine. The UI encourages only a small number of
   5477 results to be loaded already, so just sorting there should work find I
   5478 thin.
   5479 
   5480 > allow-for-limiting-to-interesting-labels:
   5481 > 
   5482 > I have a hack for this. I reopen Redwood::Mode in the startup hook, then
   5483 > add a keybinding to spawn a SearchResultsMode for a set of interesting
   5484 > labels. Same for starred messages. A better solution would be good.
   5485 
   5486 While waiting for a better solution, would you mind sharing your code
   5487 for this? I'm quite new to ruby, so even if what you described should
   5488 be trivial for me to replicate, it's not yet. :-)
   5489 
   5490 Maybe a page on the wiki?
   5491 
   5492 > save-all-state-changes-immediately,
   5493 > allow-for-inbox-mode-magic-elsewhere,
   5494 > fix-handling-of-kill-thread-outside-inbox:
   5495 > 
   5496 > These are related - saving label changes immediately means we can use
   5497 > the index to decide which threads are relevant. The new index api
   5498 > methods unblock this, and now that they're in next I plan to implement
   5499 > this soon.
   5500 
   5501 Excellent. It did seem that things were moving this direction, and I'm
   5502 glad to hear that they are.
   5503 
   5504 > be-less-overzealous-in-moving-text-to-the-left-column,
   5505 > dont-perturb-selected-thread-when-new-mail-arrives:
   5506 > 
   5507 > +1 to these.
   5508 
   5509 Great. And those don't sound too complicated, so maybe I'll try
   5510 cutting my teeth on those first.
   5511 
   5512 Meanwhile, I thought of another race condition. If new mail arrives
   5513 for the current thread when in thread-view-mode, does it get added to
   5514 the view? It might seem nice for it to show up, but it might also lead
   5515 to it getting accidentally archived away if I "knew" that there were
   5516 only 4 messages, say, when I entered the thread view, then I hit ".a"
   5517 and archived away 5 messages.
   5518 
   5519 It seems a silly thing, but it's the kind of thing that makes me start
   5520 distrusting ".a" and instead using "x", double-checking, then "a"
   5521 which is obviously less efficient. (Oh, and there's another place
   5522 where the current selector needs to not be perturbed. After I hit "x"
   5523 from thread-view-mode I find that a different thread can be selected
   5524 than the one I was just viewing if new mail arrived.)
   5525 
   5526 -Carl
   5527 -------------- next part --------------
   5528 A non-text attachment was scrubbed...
   5529 Name: signature.asc
   5530 Type: application/pgp-signature
   5531 Size: 189 bytes
   5532 Desc: not available
   5533 URL: <http://rubyforge.org/pipermail/sup-talk/attachments/20090818/ab65d341/attachment.bin>
   5534 
   5535 From bwalton@artsci.utoronto.ca  Tue Aug 18 22:47:40 2009
   5536 From: bwalton@artsci.utoronto.ca (Ben Walton)
   5537 Date: Tue, 18 Aug 2009 22:47:40 -0400
   5538 Subject: [sup-talk] Exception trying to run git source
   5539 In-Reply-To: <1250642676-sup-2244@yoom>
   5540 References: <1250642676-sup-2244@yoom>
   5541 Message-ID: <1250649988-sup-9079@ntdws12.chass.utoronto.ca>
   5542 
   5543 Excerpts from Carl Worth's message of Tue Aug 18 20:49:03 -0400 2009:
   5544 > 
   5545 >     --- NoMethodError from thread: main
   5546 >     undefined method `source_uri' for #<Redwood::SentManager:0xb74f1160
   5547 > @source=nil, @fn="sup://sent">
   5548 >     ./lib/sup/util.rb:519:in `send'
   5549 >     ./lib/sup/util.rb:519:in `method_missing'
   5550 >     bin/sup:171
   5551 
   5552 Hmm...I think that's likely an easy fix.  I'll look tomorrow morning.
   5553 
   5554 -Ben
   5555 -- 
   5556 Ben Walton
   5557 Systems Programmer - CHASS
   5558 University of Toronto
   5559 C:416.407.5610 | W:416.978.4302
   5560 
   5561 GPG Key Id: 8E89F6D2; Key Server: pgp.mit.edu
   5562 Contact me to arrange for a CAcert assurance meeting.
   5563 -------------- next part --------------
   5564 A non-text attachment was scrubbed...
   5565 Name: signature.asc
   5566 Type: application/pgp-signature
   5567 Size: 189 bytes
   5568 Desc: not available
   5569 URL: <http://rubyforge.org/pipermail/sup-talk/attachments/20090818/2ef0d45e/attachment.bin>
   5570 
   5571 From rlane@club.cc.cmu.edu  Tue Aug 18 23:02:57 2009
   5572 From: rlane@club.cc.cmu.edu (Rich Lane)
   5573 Date: Tue, 18 Aug 2009 23:02:57 -0400
   5574 Subject: [sup-talk] What's your sup workflow (and a spew of ideas)
   5575 In-Reply-To: <1250646478-sup-4064@yoom>
   5576 References: <1250629282-sup-8521@yoom> <1250634897-sup-4631@zyrg.net>
   5577 	<1250646478-sup-4064@yoom>
   5578 Message-ID: <1250649270-sup-2166@zyrg.net>
   5579 
   5580 Excerpts from Carl Worth's message of Tue Aug 18 21:58:55 -0400 2009:
   5581 > > allow-for-limiting-to-interesting-labels:
   5582 > > 
   5583 > > I have a hack for this. I reopen Redwood::Mode in the startup hook, then
   5584 > > add a keybinding to spawn a SearchResultsMode for a set of interesting
   5585 > > labels. Same for starred messages. A better solution would be good.
   5586 > 
   5587 > While waiting for a better solution, would you mind sharing your code
   5588 > for this? I'm quite new to ruby, so even if what you described should
   5589 > be trivial for me to replicate, it's not yet. :-)
   5590 > 
   5591 > Maybe a page on the wiki?
   5592 
   5593 Sure, I added an example to the end of the Hooks page.
   5594 
   5595 > Meanwhile, I thought of another race condition. If new mail arrives
   5596 > for the current thread when in thread-view-mode, does it get added to
   5597 > the view? It might seem nice for it to show up, but it might also lead
   5598 > to it getting accidentally archived away if I "knew" that there were
   5599 > only 4 messages, say, when I entered the thread view, then I hit ".a"
   5600 > and archived away 5 messages.
   5601 > 
   5602 > It seems a silly thing, but it's the kind of thing that makes me start
   5603 > distrusting ".a" and instead using "x", double-checking, then "a"
   5604 > which is obviously less efficient. (Oh, and there's another place
   5605 > where the current selector needs to not be perturbed. After I hit "x"
   5606 > from thread-view-mode I find that a different thread can be selected
   5607 > than the one I was just viewing if new mail arrived.)
   5608 
   5609 I'm glad to know there are other people annoyed by UI race conditions :).
   5610 Even after a quick look at the code I'm not sure what ThreadViewMode
   5611 will do when a thread is added to. It might actually archive/read/etc
   5612 new messages but not display them.
   5613 
   5614 I'd like a keybinding to reload/redisplay the thread and a status bar
   5615 note if there are new messages. Any label changes should only affect
   5616 messages that have been displayed. What do you think?
   5617 
   5618 From garoth@gmail.com  Wed Aug 19 10:03:49 2009
   5619 From: garoth@gmail.com (Andrei Thorp)
   5620 Date: Wed, 19 Aug 2009 10:03:49 -0400
   5621 Subject: [sup-talk] What's your sup workflow (and a spew of ideas)
   5622 In-Reply-To: <1250649270-sup-2166@zyrg.net>
   5623 References: <1250629282-sup-8521@yoom> <1250634897-sup-4631@zyrg.net>
   5624 	<1250646478-sup-4064@yoom> <1250649270-sup-2166@zyrg.net>
   5625 Message-ID: <1250690604-sup-4154@Longbow>
   5626 
   5627 Excerpts from Rich Lane's message of Tue Aug 18 23:02:57 -0400 2009:
   5628 > I'm glad to know there are other people annoyed by UI race conditions :).
   5629 > Even after a quick look at the code I'm not sure what ThreadViewMode
   5630 > will do when a thread is added to. It might actually archive/read/etc
   5631 > new messages but not display them.
   5632 > 
   5633 > I'd like a keybinding to reload/redisplay the thread and a status bar
   5634 > note if there are new messages. Any label changes should only affect
   5635 > messages that have been displayed. What do you think?
   5636 
   5637 Ooh, I like it. I guess gmail does this.
   5638 -- 
   5639 Andrei Thorp, Developer: Xandros Corp. (http://www.xandros.com)
   5640 
   5641 From bwalton@artsci.utoronto.ca  Wed Aug 19 11:59:12 2009
   5642 From: bwalton@artsci.utoronto.ca (Ben Walton)
   5643 Date: Wed, 19 Aug 2009 11:59:12 -0400
   5644 Subject: [sup-talk] Exception trying to run git source
   5645 In-Reply-To: <1250642676-sup-2244@yoom>
   5646 References: <1250642676-sup-2244@yoom>
   5647 Message-ID: <1250697503-sup-1083@ntdws12.chass.utoronto.ca>
   5648 
   5649 Excerpts from Carl Worth's message of Tue Aug 18 20:49:03 -0400 2009:
   5650 > line to my ~/.sup/config.yaml as follows:
   5651 > 
   5652 >     :sent_source: maildir:/home/cworth/mail/sent
   5653 
   5654 Here is my configuration:
   5655 
   5656 maildir:///u/bwalton/Maildir/.sent-mail/
   5657 
   5658 I think you just need to fix the URI.  I'm looking into the code
   5659 though to see why it bombed out on you.
   5660 
   5661 Thanks
   5662 -Ben
   5663 -- 
   5664 Ben Walton
   5665 Systems Programmer - CHASS
   5666 University of Toronto
   5667 C:416.407.5610 | W:416.978.4302
   5668 
   5669 GPG Key Id: 8E89F6D2; Key Server: pgp.mit.edu
   5670 Contact me to arrange for a CAcert assurance meeting.
   5671 -------------- next part --------------
   5672 A non-text attachment was scrubbed...
   5673 Name: signature.asc
   5674 Type: application/pgp-signature
   5675 Size: 189 bytes
   5676 Desc: not available
   5677 URL: <http://rubyforge.org/pipermail/sup-talk/attachments/20090819/f9f554ee/attachment.bin>
   5678 
   5679 From wmorgan-sup@masanjin.net  Wed Aug 19 12:19:44 2009
   5680 From: wmorgan-sup@masanjin.net (William Morgan)
   5681 Date: Wed, 19 Aug 2009 09:19:44 -0700
   5682 Subject: [sup-talk] Exception trying to run git source
   5683 In-Reply-To: <1250642676-sup-2244@yoom>
   5684 References: <1250642676-sup-2244@yoom>
   5685 Message-ID: <1250698636-sup-6732@masanjin.net>
   5686 
   5687 Reformatted excerpts from Carl Worth's message of 2009-08-18:
   5688 >     --- NoMethodError from thread: main
   5689 >     undefined method `source_uri' for #<Redwood::SentManager:0xb74f1160
   5690 > @source=nil, @fn="sup://sent">
   5691 
   5692 Very curious. SentManager most definitely has a source_uri method. If
   5693 you look at lib/sup/sent.rb, does it include the line "attr_reader
   5694 :source, :source_uri"? If so, is there a line in the log that says
   5695 "SentManager initialized with source uri: xxx"?
   5696 -- 
   5697 William <wmorgan-sup at masanjin.net>
   5698 
   5699 From cworth@cworth.org  Wed Aug 19 12:33:10 2009
   5700 From: cworth@cworth.org (Carl Worth)
   5701 Date: Wed, 19 Aug 2009 09:33:10 -0700
   5702 Subject: [sup-talk] Exception trying to run git source
   5703 In-Reply-To: <1250698636-sup-6732@masanjin.net>
   5704 References: <1250642676-sup-2244@yoom> <1250698636-sup-6732@masanjin.net>
   5705 Message-ID: <1250699408-sup-9579@yoom>
   5706 
   5707 Excerpts from William Morgan's message of Wed Aug 19 09:19:44 -0700 2009:
   5708 > Reformatted excerpts from Carl Worth's message of 2009-08-18:
   5709 > >     --- NoMethodError from thread: main
   5710 > >     undefined method `source_uri' for #<Redwood::SentManager:0xb74f1160
   5711 > > @source=nil, @fn="sup://sent">
   5712 > 
   5713 > Very curious. SentManager most definitely has a source_uri method. If
   5714 > you look at lib/sup/sent.rb, does it include the line "attr_reader
   5715 > :source, :source_uri"?
   5716 
   5717 Yes, that is there.
   5718 
   5719 >                         If so, is there a line in the log that says
   5720 > "SentManager initialized with source uri: xxx"?
   5721 
   5722 No, I don't think so. At least, that is, if I'm looking at the right
   5723 place. Is the "log" anything other than the output on stdout/err when
   5724 I run sup? Do I need to turn on any additional verbosity somehow?
   5725 
   5726 Below you can see the entire output I get when running sup from git
   5727 master.
   5728 
   5729 -Carl (wishing he had any skills for debugging ruby...)
   5730 
   5731 0:~/src/sup:(master)$ ruby -I lib -w bin/sup
   5732 ./lib/sup/util.rb:8: warning: method redefined; discarding old
   5733 gen_lock_id
   5734 ./lib/sup/util.rb:19: warning: method redefined; discarding old
   5735 dump_lock_id
   5736 [Wed Aug 19 09:22:55 -0700 2009] using character set encoding "UTF-8"
   5737 ./lib/sup/message-chunks.rb:36: warning: method redefined; discarding
   5738 old make_tmpname
   5739 ./lib/sup/imap.rb:117: warning: ambiguous first argument; put
   5740 parentheses or even spaces
   5741 /usr/lib/ruby/1.8/chronic/repeaters/repeater_month_name.rb:13:
   5742 warning: useless use of > in void context
   5743 /usr/lib/ruby/1.8/chronic/repeaters/repeater_month_name.rb:19:
   5744 warning: useless use of > in void context
   5745 /usr/lib/ruby/1.8/chronic/repeaters/repeater_month_name.rb:25:
   5746 warning: useless use of < in void context
   5747 [Wed Aug 19 09:22:55 -0700 2009] using index Redwood::FerretIndex
   5748 Warning: $KCODE is NONE.
   5749 [Wed Aug 19 09:22:55 -0700 2009] dynamically loading setlocale() from
   5750 libc.so.6
   5751 [Wed Aug 19 09:22:55 -0700 2009] setting locale...
   5752 [Wed Aug 19 09:22:55 -0700 2009] locking /home/cworth/.sup/lock...
   5753 [Wed Aug 19 09:22:55 -0700 2009] crypto: detected gpg binary in
   5754 /usr/bin/gpg
   5755 [Wed Aug 19 09:22:55 -0700 2009] loading index...
   5756 [Wed Aug 19 09:22:55 -0700 2009] loaded index of 557361 messages
   5757 ./lib/sup/index.rb:53: warning: instance variable @lock_update_thread
   5758 not initialized
   5759 bin/sup:126: warning: global variable `$cursing' not initialized
   5760 [Wed Aug 19 09:22:55 -0700 2009] stopped cursing
   5761 [Wed Aug 19 09:22:55 -0700 2009] oh crap, an exception
   5762 [Wed Aug 19 09:22:55 -0700 2009] unlocking /home/cworth/.sup/lock...
   5763 ----------------------------------------------------------------
   5764 I'm very sorry. It seems that an error occurred in Sup. Please
   5765 accept my sincere apologies. If you don't mind, please send the
   5766 contents of ~/.sup/exception-log.txt and a brief report of the
   5767 circumstances to sup-talk at rubyforge dot orgs so that I might
   5768 address this problem. Thank you!
   5769 
   5770 Sincerely,
   5771 William
   5772 ----------------------------------------------------------------
   5773 --- NoMethodError from thread: main
   5774 undefined method `source_uri' for #<Redwood::SentManager:0xb75441a8
   5775 @source=nil, @fn="sup://sent">
   5776 ./lib/sup/util.rb:519:in `send'
   5777 ./lib/sup/util.rb:519:in `method_missing'
   5778 bin/sup:171
   5779 -------------- next part --------------
   5780 A non-text attachment was scrubbed...
   5781 Name: signature.asc
   5782 Type: application/pgp-signature
   5783 Size: 189 bytes
   5784 Desc: not available
   5785 URL: <http://rubyforge.org/pipermail/sup-talk/attachments/20090819/9feb1415/attachment.bin>
   5786 
   5787 From bwalton@artsci.utoronto.ca  Wed Aug 19 12:34:09 2009
   5788 From: bwalton@artsci.utoronto.ca (Ben Walton)
   5789 Date: Wed, 19 Aug 2009 12:34:09 -0400
   5790 Subject: [sup-talk] Exception trying to run git source
   5791 In-Reply-To: <1250698636-sup-6732@masanjin.net>
   5792 References: <1250642676-sup-2244@yoom> <1250698636-sup-6732@masanjin.net>
   5793 Message-ID: <1250699596-sup-8133@ntdws12.chass.utoronto.ca>
   5794 
   5795 Excerpts from William Morgan's message of Wed Aug 19 12:19:44 -0400 2009:
   5796 > Reformatted excerpts from Carl Worth's message of 2009-08-18:
   5797 > >     --- NoMethodError from thread: main
   5798 > >     undefined method `source_uri' for #<Redwood::SentManager:0xb74f1160
   5799 > > @source=nil, @fn="sup://sent">
   5800 > 
   5801 > Very curious. SentManager most definitely has a source_uri method. If
   5802 > you look at lib/sup/sent.rb, does it include the line "attr_reader
   5803 > :source, :source_uri"? If so, is there a line in the log that says
   5804 > "SentManager initialized with source uri: xxx"?
   5805 
   5806 Also, is bin/sup part of your git checkout (meaning it lines up with
   5807 the rest of your lib/, etc)?  Are you running from the next branch?
   5808 I'm looking at bin/sup here (5f393122), and the line numbers don't
   5809 "add up."  Line 152 is where I see the call into
   5810 SentManager.source_uri, not 171.
   5811 
   5812 -Ben
   5813 -- 
   5814 Ben Walton
   5815 Systems Programmer - CHASS
   5816 University of Toronto
   5817 C:416.407.5610 | W:416.978.4302
   5818 
   5819 GPG Key Id: 8E89F6D2; Key Server: pgp.mit.edu
   5820 Contact me to arrange for a CAcert assurance meeting.
   5821 -------------- next part --------------
   5822 A non-text attachment was scrubbed...
   5823 Name: signature.asc
   5824 Type: application/pgp-signature
   5825 Size: 189 bytes
   5826 Desc: not available
   5827 URL: <http://rubyforge.org/pipermail/sup-talk/attachments/20090819/4c299b1e/attachment.bin>
   5828 
   5829 From cworth@cworth.org  Wed Aug 19 13:53:54 2009
   5830 From: cworth@cworth.org (Carl Worth)
   5831 Date: Wed, 19 Aug 2009 10:53:54 -0700
   5832 Subject: [sup-talk] Exception trying to run git source
   5833 In-Reply-To: <1250699596-sup-8133@ntdws12.chass.utoronto.ca>
   5834 References: <1250642676-sup-2244@yoom> <1250698636-sup-6732@masanjin.net>
   5835 	<1250699596-sup-8133@ntdws12.chass.utoronto.ca>
   5836 Message-ID: <1250704257-sup-3308@yoom>
   5837 
   5838 Excerpts from Ben Walton's message of Wed Aug 19 09:34:09 -0700 2009:
   5839 > Also, is bin/sup part of your git checkout (meaning it lines up with
   5840 > the rest of your lib/, etc)?
   5841 
   5842 Yes.
   5843 
   5844 >                              Are you running from the next branch?
   5845 > I'm looking at bin/sup here (5f393122), and the line numbers don't
   5846 > "add up."  Line 152 is where I see the call into
   5847 > SentManager.source_uri, not 171.
   5848 
   5849 No, I was running from master, (so line 171 does make sense there).
   5850 
   5851 I tried running from next and got a different failure (see below).  I
   5852 suspected I might have something just broken in my configuration, so I
   5853 moved ~/.sup away for the run below, (which didn't seem to change
   5854 anything).
   5855 
   5856 This new failure seems to be occurring earlier, so I bisected,
   5857 (labelling the previous source_uri exception as "good" and the new
   5858 no-SentManager-instance as "bad"), and that pointed at the following
   5859 commit:
   5860 
   5861 9dd4f50b9f62ab5642241359bf6f7c291ccfa738 is first bad commit
   5862 commit 9dd4f50b9f62ab5642241359bf6f7c291ccfa738
   5863 Author: William Morgan <wmorgan-sup at masanjin.net>
   5864 Date:   Wed Aug 12 13:14:34 2009 -0400
   5865 
   5866     rewrite Singleton to not require i_am_the_instance
   5867     
   5868     The flip side is that you have to use .init instead of .new.
   5869 
   5870 I'm really wondering why I'm getting what appear to be unique crashes
   5871 compared to others. Is it my ruby version:
   5872 
   5873 $ ruby --version
   5874 ruby 1.8.7 (2009-06-12 patchlevel 174) [i486-linux]
   5875 
   5876 Any ideas?
   5877 
   5878 -Carl
   5879 
   5880 0:~/src/sup:(next)$ ruby -I lib -w ./bin/sup
   5881 ./lib/sup/util.rb:9: warning: method redefined; discarding old gen_lock_id
   5882 ./lib/sup/util.rb:20: warning: method redefined; discarding old dump_lock_id
   5883 ./lib/sup/message-chunks.rb:36: warning: method redefined; discarding old make_tmpname
   5884 ./lib/sup/imap.rb:118: warning: ambiguous first argument; put parentheses or even spaces
   5885 /usr/lib/ruby/1.8/chronic/repeaters/repeater_month_name.rb:13: warning: useless use of > in void context
   5886 /usr/lib/ruby/1.8/chronic/repeaters/repeater_month_name.rb:19: warning: useless use of > in void context
   5887 /usr/lib/ruby/1.8/chronic/repeaters/repeater_month_name.rb:25: warning: useless use of < in void context
   5888 [Wed Aug 19 10:26:50 -0700 2009] WARNING: Warning: $KCODE is NONE.
   5889 ./lib/sup/index.rb:54: warning: instance variable @lock_update_thread not initialized
   5890 ./bin/sup:127: warning: global variable `$cursing' not initialized
   5891 ./bin/sup:329: warning: global variable `$die' not initialized
   5892 [Wed Aug 19 10:26:50 -0700 2009] ERROR: oh crap, an exception
   5893 ----------------------------------------------------------------
   5894 I'm very sorry. It seems that an error occurred in Sup. Please
   5895 accept my sincere apologies. If you don't mind, please send the
   5896 contents of ~/.sup/exception-log.txt and a brief report of the
   5897 circumstances to sup-talk at rubyforge dot orgs so that I might
   5898 address this problem. Thank you!
   5899 
   5900 Sincerely,
   5901 William
   5902 ----------------------------------------------------------------
   5903 --- RuntimeError from thread: main
   5904 no Redwood::SentManager instance defined in method call to i_am_the_instance!
   5905 ./lib/sup/util.rb:512:in `method_missing'
   5906 /usr/lib/ruby/1.8/sup/sent.rb:10:in `initialize'
   5907 ./lib/sup/util.rb:524:in `new'
   5908 ./lib/sup/util.rb:524:in `init'
   5909 ./lib/sup.rb:110:in `start'
   5910 ./bin/sup:138
   5911 
   5912 From bwalton@artsci.utoronto.ca  Wed Aug 19 14:08:19 2009
   5913 From: bwalton@artsci.utoronto.ca (Ben Walton)
   5914 Date: Wed, 19 Aug 2009 14:08:19 -0400
   5915 Subject: [sup-talk] Exception trying to run git source
   5916 In-Reply-To: <1250704257-sup-3308@yoom>
   5917 References: <1250642676-sup-2244@yoom> <1250698636-sup-6732@masanjin.net>
   5918 	<1250699596-sup-8133@ntdws12.chass.utoronto.ca>
   5919 	<1250704257-sup-3308@yoom>
   5920 Message-ID: <1250705105-sup-7923@ntdws12.chass.utoronto.ca>
   5921 
   5922 Excerpts from Carl Worth's message of Wed Aug 19 13:53:54 -0400 2009:
   5923 > $ ruby --version
   5924 > ruby 1.8.7 (2009-06-12 patchlevel 174) [i486-linux]
   5925 
   5926 I'm running the (now fossilized):
   5927 $ ruby --version
   5928 ruby 1.8.5 (2006-08-25) [i386-linux]
   5929 
   5930 (as shipped with rhel5).
   5931 
   5932 > Any ideas?
   5933 
   5934 Not right now, but I'll think about it.
   5935 
   5936 Thanks
   5937 -Ben
   5938 -- 
   5939 Ben Walton
   5940 Systems Programmer - CHASS
   5941 University of Toronto
   5942 C:416.407.5610 | W:416.978.4302
   5943 
   5944 GPG Key Id: 8E89F6D2; Key Server: pgp.mit.edu
   5945 Contact me to arrange for a CAcert assurance meeting.
   5946 -------------- next part --------------
   5947 A non-text attachment was scrubbed...
   5948 Name: signature.asc
   5949 Type: application/pgp-signature
   5950 Size: 189 bytes
   5951 Desc: not available
   5952 URL: <http://rubyforge.org/pipermail/sup-talk/attachments/20090819/cd6d7c32/attachment.bin>
   5953 
   5954 From wmorgan-sup@masanjin.net  Wed Aug 19 14:39:56 2009
   5955 From: wmorgan-sup@masanjin.net (William Morgan)
   5956 Date: Wed, 19 Aug 2009 11:39:56 -0700
   5957 Subject: [sup-talk] crash when sup-syncing to xapian
   5958 In-Reply-To: <1250616603-sup-5612@ntdws12.chass.utoronto.ca>
   5959 References: <1250616603-sup-5612@ntdws12.chass.utoronto.ca>
   5960 Message-ID: <1250707129-sup-7698@masanjin.net>
   5961 
   5962 Reformatted excerpts from Ben Walton's message of 2009-08-18:
   5963 > There is something wonky with label handling, as per attached
   5964 > exception log.
   5965 
   5966 This should be fixed in next. It was a result of some of the API
   5967 refactoring I've been doing recently. Everyone's source.yaml should now
   5968 automagically revert to the format from the good ol' days.
   5969 -- 
   5970 William <wmorgan-sup at masanjin.net>
   5971 
   5972 From wmorgan-sup@masanjin.net  Wed Aug 19 14:52:26 2009
   5973 From: wmorgan-sup@masanjin.net (William Morgan)
   5974 Date: Wed, 19 Aug 2009 11:52:26 -0700
   5975 Subject: [sup-talk] Exception trying to run git source
   5976 In-Reply-To: <1250704257-sup-3308@yoom>
   5977 References: <1250642676-sup-2244@yoom> <1250698636-sup-6732@masanjin.net>
   5978 	<1250699596-sup-8133@ntdws12.chass.utoronto.ca>
   5979 	<1250704257-sup-3308@yoom>
   5980 Message-ID: <1250707794-sup-6173@masanjin.net>
   5981 
   5982 Reformatted excerpts from Carl Worth's message of 2009-08-19:
   5983 > ruby 1.8.7 (2009-06-12 patchlevel 174) [i486-linux]
   5984 
   5985 Fine.
   5986 
   5987 > no Redwood::SentManager instance defined in method call to i_am_the_instance!
   5988 > ./lib/sup/util.rb:512:in `method_missing'
   5989 > /usr/lib/ruby/1.8/sup/sent.rb:10:in `initialize'
   5990 > ./lib/sup/util.rb:524:in `new'
   5991 > ./lib/sup/util.rb:524:in `init'
   5992 > ./lib/sup.rb:110:in `start'
   5993 > ./bin/sup:138
   5994 
   5995 Do you get this error in next head, and in the "first bad commit" you
   5996 reported? Neither of those should have any calls to i_am_the_instance!
   5997 anywhere in the code.
   5998 -- 
   5999 William <wmorgan-sup at masanjin.net>
   6000 
   6001 From wmorgan-sup@masanjin.net  Wed Aug 19 14:52:56 2009
   6002 From: wmorgan-sup@masanjin.net (William Morgan)
   6003 Date: Wed, 19 Aug 2009 11:52:56 -0700
   6004 Subject: [sup-talk] Crash w/ current 'next'
   6005 In-Reply-To: <aeb4682e1581f7534cb1c81bd143dbc6@pioto.org>
   6006 References: <aeb4682e1581f7534cb1c81bd143dbc6@pioto.org>
   6007 Message-ID: <1250707961-sup-5229@masanjin.net>
   6008 
   6009 Reformatted excerpts from Mike Kelly's message of 2009-08-18:
   6010 > I just built from the current next branch, and now whenever I load
   6011 > sup, it gives me the attached crash.
   6012 
   6013 Should be fixed. Sorry about that.
   6014 -- 
   6015 William <wmorgan-sup at masanjin.net>
   6016 
   6017 From wmorgan-sup@masanjin.net  Wed Aug 19 14:55:03 2009
   6018 From: wmorgan-sup@masanjin.net (William Morgan)
   6019 Date: Wed, 19 Aug 2009 11:55:03 -0700
   6020 Subject: [sup-talk] [PATCH] Add an after-add-message hook
   6021 In-Reply-To: <1250638381-sup-2952@black-opal.mit.edu>
   6022 References: <1250459229-4500-1-git-send-email-kevinr@free-dissociation.com>
   6023 	<1250618123-sup-8797@masanjin.net>
   6024 	<1250638381-sup-2952@black-opal.mit.edu>
   6025 Message-ID: <1250707991-sup-5429@masanjin.net>
   6026 
   6027 Reformatted excerpts from Kevin Riggle's message of 2009-08-18:
   6028 > I don't /think/ so, unless I misunderstand the way hooks work.  I
   6029 > assumed the hook would execute and then execution of the loop would
   6030 > resume, and I don't think I throw anything in the hook which should
   6031 > cause that either.
   6032 
   6033 What I'm saying is that this hook will execute *after* each message is
   6034 added to the index, so if Sup found several new messages, all except the
   6035 first one will wait on this hook to execute before being added to the
   6036 index. Or do you mean block in some sense besides "wait for completion"?
   6037 -- 
   6038 William <wmorgan-sup at masanjin.net>
   6039 
   6040 From cworth@cworth.org  Wed Aug 19 15:40:15 2009
   6041 From: cworth@cworth.org (Carl Worth)
   6042 Date: Wed, 19 Aug 2009 12:40:15 -0700
   6043 Subject: [sup-talk] Exception trying to run git source
   6044 In-Reply-To: <1250707794-sup-6173@masanjin.net>
   6045 References: <1250642676-sup-2244@yoom> <1250698636-sup-6732@masanjin.net>
   6046 	<1250699596-sup-8133@ntdws12.chass.utoronto.ca>
   6047 	<1250704257-sup-3308@yoom> <1250707794-sup-6173@masanjin.net>
   6048 Message-ID: <1250710221-sup-925@yoom.home.cworth.org>
   6049 
   6050 Excerpts from William Morgan's message of Wed Aug 19 11:52:26 -0700 2009:
   6051 > > no Redwood::SentManager instance defined in method call to i_am_the_instance!
   6052 > > ./lib/sup/util.rb:512:in `method_missing'
   6053 > > /usr/lib/ruby/1.8/sup/sent.rb:10:in `initialize'
   6054 > > ./lib/sup/util.rb:524:in `new'
   6055 > > ./lib/sup/util.rb:524:in `init'
   6056 > > ./lib/sup.rb:110:in `start'
   6057 > > ./bin/sup:138
   6058 > 
   6059 > Do you get this error in next head, and in the "first bad commit" you
   6060 > reported?
   6061 
   6062 Yes.
   6063 
   6064 > Neither of those should have any calls to i_am_the_instance!
   6065 > anywhere in the code.
   6066 
   6067 Thanks. That confirms that I'm not running the code I think I am, and
   6068 the above stack trace makes that obvious, (see
   6069 /usr/lib/ruby/1.8/sup/sent.rb). So I was running some unholy mixture
   6070 of the installed Debian sup and the from-git sup and it worked no
   6071 better than one would expect.
   6072 
   6073 My previously reported crashes didn't happen to fail in a way that
   6074 made /usr/lib show up in the stack trace, but both crashes are fixed
   6075 by just moving /usr/lib/ruby/1.8/sup out of the way.
   6076 
   6077 So I'm glad to have things working now, but I'm still curious to know
   6078 why ruby goes digging into /usr/lib/ruby/1.8 to find sup/sent.rb when
   6079 there's a ./lib/sub/sent.rb present and I've passed a "-I ./lib"
   6080 option to ruby, (and plainly, ruby is interpreting other files from
   6081 ./lib).
   6082 
   6083 And I'd be glad if someone could recommend a ruby-esque way to debug a
   6084 situation like this. I mean, I could obviously have just run ruby
   6085 under strace and looked for the paths of various *.rb files getting
   6086 loaded, but surely there's some more ruby-specific way to list files
   6087 that are being used?
   6088 
   6089 -Carl
   6090 
   6091 PS. I'm intrigued by the following mention:
   6092 
   6093 	You?ve got the same sort of command-line debugger available.
   6094 	[http://www.ruby-lang.org/en/documentation/ruby-from-other-languages/to-ruby-from-c-and-c-/]
   6095 
   6096 so that's clearly something I'm going to have to learn to use.
   6097 
   6098 
   6099 -------------- next part --------------
   6100 A non-text attachment was scrubbed...
   6101 Name: signature.asc
   6102 Type: application/pgp-signature
   6103 Size: 189 bytes
   6104 Desc: not available
   6105 URL: <http://rubyforge.org/pipermail/sup-talk/attachments/20090819/b7de0a71/attachment.bin>
   6106 
   6107 From wmorgan-sup@masanjin.net  Wed Aug 19 16:02:26 2009
   6108 From: wmorgan-sup@masanjin.net (William Morgan)
   6109 Date: Wed, 19 Aug 2009 13:02:26 -0700
   6110 Subject: [sup-talk] Exception trying to run git source
   6111 In-Reply-To: <1250710221-sup-925@yoom.home.cworth.org>
   6112 References: <1250642676-sup-2244@yoom> <1250698636-sup-6732@masanjin.net>
   6113 	<1250699596-sup-8133@ntdws12.chass.utoronto.ca>
   6114 	<1250704257-sup-3308@yoom> <1250707794-sup-6173@masanjin.net>
   6115 	<1250710221-sup-925@yoom.home.cworth.org>
   6116 Message-ID: <1250712045-sup-3506@masanjin.net>
   6117 
   6118 Reformatted excerpts from Carl Worth's message of 2009-08-19:
   6119 > Thanks. That confirms that I'm not running the code I think I am,
   6120 
   6121 Good, that explains a lot.
   6122 
   6123 > So I'm glad to have things working now, but I'm still curious to know
   6124 > why ruby goes digging into /usr/lib/ruby/1.8 to find sup/sent.rb when
   6125 > there's a ./lib/sub/sent.rb present and I've passed a "-I ./lib"
   6126 > option to ruby, (and plainly, ruby is interpreting other files from
   6127 > ./lib).
   6128 
   6129 I find it surprising too. I haven't seen taht behavior before. FWIW, Sup
   6130 does try and detect if bin/sup and lib/sup have mismatched versions, and
   6131 that didn't fire... I wonder if it's just sent.rb that's been loaded.
   6132 Did you somehow delete sent.rb from your git directory, or something
   6133 like that?
   6134 -- 
   6135 William <wmorgan-sup at masanjin.net>
   6136 
   6137 From benoit.pierre@gmail.com  Wed Aug 19 16:56:55 2009
   6138 From: benoit.pierre@gmail.com (=?utf-8?q?Beno=C3=AEt_PIERRE?=)
   6139 Date: Wed, 19 Aug 2009 22:56:55 +0200
   6140 Subject: [sup-talk] [PATCH] fix garbaged text in textfield when using
   6141 	ncursesw
   6142 Message-ID: <1250715278-sup-1941@localdomain>
   6143 
   6144 Apparently, field_buffer content is not initialized to blanks when using
   6145 the wide-character version of ncurses. Forcing a call to
   6146 set_field_buffer fix the problem.
   6147 ---
   6148  lib/sup/textfield.rb |    4 ++--
   6149  1 files changed, 2 insertions(+), 2 deletions(-)
   6150 
   6151 diff --git a/lib/sup/textfield.rb b/lib/sup/textfield.rb
   6152 index b8dec59..76803bf 100644
   6153 --- a/lib/sup/textfield.rb
   6154 +++ b/lib/sup/textfield.rb
   6155 @@ -35,9 +35,9 @@ class TextField
   6156      @completion_block = block
   6157      @field = Ncurses::Form.new_field 1, @width - question.length, @y, @x + question.length, 256, 0
   6158      @form = Ncurses::Form.new_form [@field]
   6159 -    @value = default
   6160 +    @value = default || ''
   6161      Ncurses::Form.post_form @form
   6162 -    set_cursed_value default if default
   6163 +    set_cursed_value @value
   6164    end
   6165  
   6166    def position_cursor
   6167 -- 
   6168 1.6.3.3
   6169 -- 
   6170 A: Because it destroys the flow of conversation.
   6171 Q: Why is top posting dumb?
   6172 -------------- next part --------------
   6173 A non-text attachment was scrubbed...
   6174 Name: signature.asc
   6175 Type: application/pgp-signature
   6176 Size: 197 bytes
   6177 Desc: not available
   6178 URL: <http://rubyforge.org/pipermail/sup-talk/attachments/20090819/95de5c6f/attachment.bin>
   6179 
   6180 From dato@net.com.org.es  Wed Aug 19 17:22:09 2009
   6181 From: dato@net.com.org.es (Adeodato =?utf-8?B?U2ltw7M=?=)
   6182 Date: Wed, 19 Aug 2009 22:22:09 +0100
   6183 Subject: [sup-talk] [PATCH] mime-decode hook: provide a "charset"
   6184  variable with the attachment charset
   6185 In-Reply-To: <20090730155656.GA20442@chistera.yi.org>
   6186 References: <6fc2e5dd8aa2b0b8547375d77b1776d779f85817.1247238014.git.dato@net.com.org.es>
   6187 	<20090723093543.GA2265@chistera.yi.org> <1248713434-sup-4961@entry>
   6188 	<20090730155656.GA20442@chistera.yi.org>
   6189 Message-ID: <20090819212209.GA10883@chistera.yi.org>
   6190 
   6191 Ping?
   6192 
   6193 + Adeodato Sim? (Thu, 30 Jul 2009 17:56:56 +0200):
   6194 
   6195 > + William Morgan (Mon, 27 Jul 2009 09:51:17 -0700):
   6196 
   6197 > > Reformatted excerpts from Adeodato Sim?'s message of 2009-07-23:
   6198 > > > + Adeodato Sim? (Fri, 10 Jul 2009 17:00:29 +0200):
   6199 > > > > +                          :charset => encoded_content.charset,
   6200 
   6201 > > > Hm, so apparently encoded_content doesn't always have a charset
   6202 > > > member...
   6203 
   6204 > > In which case that value of that variable is nil, right? Is that a
   6205 > > problem? The patch still seems useful.
   6206 
   6207 > Yes, I took a closer look and you're right the result of
   6208 > encoded_content.charset is nil in that case. I also saw (I think) where
   6209 > the traceback I was seeing is coming from: apparently it's not possible
   6210 > to pass to HookContext a local that is nil, since then "super" will get
   6211 > called in HookContext::method_missing() as far as I can see.
   6212 
   6213 > So, perhaps, to fix this patch, one could do:
   6214 
   6215 >     :charset => encoded_content.charset || ''
   6216 
   6217 > But then, I think it would be better to fix HookContext to allow for
   6218 > @__locals to contain nil. I'm not very familiar with that class, but it
   6219 > seems easy enough to fix, see upcoming patch (also found in
   6220 > ~dato/sup/sup-dato:fixes at Gitorious, if you prefer that). With it,
   6221 > this improvement to mime-decode seems to work without any further
   6222 > trouble.
   6223 
   6224 > Cheers,
   6225 
   6226 
   6227 -- 
   6228 - Are you sure we're good?
   6229 - Always.
   6230         -- Rory and Lorelai
   6231 
   6232 
   6233 From cworth@cworth.org  Wed Aug 19 17:37:15 2009
   6234 From: cworth@cworth.org (Carl Worth)
   6235 Date: Wed, 19 Aug 2009 14:37:15 -0700
   6236 Subject: [sup-talk] Exception trying to run git source
   6237 In-Reply-To: <1250712045-sup-3506@masanjin.net>
   6238 References: <1250642676-sup-2244@yoom> <1250698636-sup-6732@masanjin.net>
   6239 	<1250699596-sup-8133@ntdws12.chass.utoronto.ca>
   6240 	<1250704257-sup-3308@yoom> <1250707794-sup-6173@masanjin.net>
   6241 	<1250710221-sup-925@yoom.home.cworth.org>
   6242 	<1250712045-sup-3506@masanjin.net>
   6243 Message-ID: <1250717434-sup-4489@yoom.home.cworth.org>
   6244 
   6245 Excerpts from William Morgan's message of Wed Aug 19 13:02:26 -0700 2009:
   6246 > I find it surprising too. I haven't seen taht behavior before. FWIW, Sup
   6247 > does try and detect if bin/sup and lib/sup have mismatched versions, and
   6248 > that didn't fire... I wonder if it's just sent.rb that's been loaded.
   6249 > Did you somehow delete sent.rb from your git directory, or something
   6250 > like that?
   6251 
   6252 Nope. The git checkout is entirely intact, and it was quite a large
   6253 number of modules getting misloaded.
   6254 
   6255 I ran an strace on the ruby process[*] and was able to plainly see
   6256 that modules were being correctly loaded from ./lib until after
   6257 /usr/lib/ruby/1.8/chronic.rb was loaded. After that, ruby would look
   6258 for modules in /usr/lib/ruby/1.8 before ./lib. And sure enough, the
   6259 first line of my chronic.rb has:
   6260 
   6261 $:.unshift File.dirname(__FILE__)     # For use/testing when no gem is installed
   6262 
   6263 I'll go ahead and find the right place to file that bug, but at least
   6264 the mystery is solved now.
   6265 
   6266 -Carl
   6267 
   6268 [*] http://cworth.org/~cworth/tmp/ruby-sup.strace
   6269 -------------- next part --------------
   6270 A non-text attachment was scrubbed...
   6271 Name: signature.asc
   6272 Type: application/pgp-signature
   6273 Size: 189 bytes
   6274 Desc: not available
   6275 URL: <http://rubyforge.org/pipermail/sup-talk/attachments/20090819/5e1ba854/attachment.bin>
   6276 
   6277 From wirtwolff@gmail.com  Wed Aug 19 16:41:54 2009
   6278 From: wirtwolff@gmail.com (Wirt Wolff)
   6279 Date: Wed, 19 Aug 2009 14:41:54 -0600
   6280 Subject: [sup-talk] In next: thread-view-mode labelling No method join for
   6281 	Set
   6282 Message-ID: <1250714501-sup-3033@chigamba>
   6283 
   6284 Lots of great improvements in next. Love the utf8.
   6285 
   6286 When I try to 'l'abel in thread view mode, however, sup crashes with
   6287 
   6288 --- NoMethodError from thread: main
   6289 undefined method `join' for #<Set: {:list, :xm}>
   6290 ./lib/sup/buffer.rb:506:in `ask_for_labels'
   6291 ./lib/sup/util.rb:520:in `send'
   6292 ./lib/sup/util.rb:520:in `method_missing'
   6293 ./lib/sup/modes/thread-view-mode.rb:253:in `edit_labels'
   6294 ./lib/sup/mode.rb:50:in `send'
   6295 ./lib/sup/mode.rb:50:in `handle_input'
   6296 ./lib/sup/buffer.rb:260:in `handle_input'
   6297 
   6298 ----------------------------------------
   6299 
   6300 Most recent commit is
   6301     Merge branch 'various-api-refactors' into next
   6302 commit 3de96fb9b308afe600c7ccfcee75913f039ef4f6
   6303 
   6304 run with % ruby -Ilib bin/sup
   6305 
   6306 ----------------------------------------
   6307 
   6308 Advice how to fix?
   6309 
   6310 thanks,
   6311 
   6312 -- 
   6313 wmw
   6314 
   6315 From cworth@cworth.org  Wed Aug 19 19:21:08 2009
   6316 From: cworth@cworth.org (Carl Worth)
   6317 Date: Wed, 19 Aug 2009 16:21:08 -0700
   6318 Subject: [sup-talk] What's your sup workflow (and a spew of ideas)
   6319 In-Reply-To: <1250649270-sup-2166@zyrg.net>
   6320 References: <1250629282-sup-8521@yoom> <1250634897-sup-4631@zyrg.net>
   6321 	<1250646478-sup-4064@yoom> <1250649270-sup-2166@zyrg.net>
   6322 Message-ID: <1250723746-sup-4632@yoom.home.cworth.org>
   6323 
   6324 Excerpts from Rich Lane's message of Tue Aug 18 20:02:57 -0700 2009:
   6325 > Excerpts from Carl Worth's message of Tue Aug 18 21:58:55 -0400 2009:
   6326 > > Maybe a page on the wiki?
   6327 > 
   6328 > Sure, I added an example to the end of the Hooks page.
   6329 
   6330 Excellent. That looks very helpful.
   6331 
   6332 And looking closer at the hooks wiki page, I see that it shows me how
   6333 to label incoming mail with ruby code, (which I've been wanting to
   6334 switch to instead of using maildrop to deliver mail to different
   6335 maildirs, and sup adding labels based on the source).
   6336 
   6337 The hooks page also shows me how to display the number of unread
   6338 messages in a thread like I wanted, (though I'll still propose that
   6339 for sup itself rather than relying on a user hook for this).
   6340 
   6341 So thanks for the encouragement to take a closer look at this page.
   6342 
   6343 > I'm glad to know there are other people annoyed by UI race conditions :).
   6344 > Even after a quick look at the code I'm not sure what ThreadViewMode
   6345 > will do when a thread is added to. It might actually archive/read/etc
   6346 > new messages but not display them.
   6347 
   6348 That was definitely my fear.
   6349 
   6350 > I'd like a keybinding to reload/redisplay the thread and a status bar
   6351 > note if there are new messages. Any label changes should only affect
   6352 > messages that have been displayed. What do you think?
   6353 
   6354 Only affecting messages that have been displayed is the critical
   6355 piece, yes. Adding a status bar notice would be a nice addition.
   6356 
   6357 -Carl
   6358 -------------- next part --------------
   6359 A non-text attachment was scrubbed...
   6360 Name: signature.asc
   6361 Type: application/pgp-signature
   6362 Size: 189 bytes
   6363 Desc: not available
   6364 URL: <http://rubyforge.org/pipermail/sup-talk/attachments/20090819/62013666/attachment.bin>
   6365 
   6366 From cworth@cworth.org  Wed Aug 19 20:31:12 2009
   6367 From: cworth@cworth.org (Carl Worth)
   6368 Date: Wed, 19 Aug 2009 17:31:12 -0700
   6369 Subject: [sup-talk] In next: thread-view-mode labelling No method join
   6370 	for Set
   6371 In-Reply-To: <1250714501-sup-3033@chigamba>
   6372 References: <1250714501-sup-3033@chigamba>
   6373 Message-ID: <1250727630-sup-3112@yoom.home.cworth.org>
   6374 
   6375 Excerpts from Wirt Wolff's message of Wed Aug 19 13:41:54 -0700 2009:
   6376 > Lots of great improvements in next. Love the utf8.
   6377 
   6378 Agreed. These are very nice.
   6379 
   6380 > When I try to 'l'abel in thread view mode, however, sup crashes with
   6381 > 
   6382 > --- NoMethodError from thread: main
   6383 > undefined method `join' for #<Set: {:list, :xm}>
   6384 > ./lib/sup/buffer.rb:506:in `ask_for_labels'
   6385 
   6386 I'm getting that too. It bisected down to the following which is not
   6387 so surprising:
   6388 
   6389     commit 7aea418a8a62b7070eee764475fcfc0bdd8d58dd
   6390     Author: William Morgan <wmorgan-sup at masanjin.net>
   6391     Date:   Tue Aug 11 16:00:52 2009 -0400
   6392 
   6393         maintain labels as Sets rather than arrays
   6394 
   6395 I've attached a patch that at least makes the crashes I was able ro
   6396 reproduce go away. But I have no idea if I got them all of course[*].
   6397 And please let me know if I'm doing anything wrong. I'm new to ruby as
   6398 well as sup here, so go easy on me, please! :-)
   6399 
   6400 -Carl
   6401 
   6402 [*] Totally off-topic: This is one of the things about "dynamically
   6403 typed" languages that I've never been able to wrap my brain around. I
   6404 really like that with static typing I can trust the compiler to help
   6405 me be very thorough if I make a type change like this, (and catch all
   6406 the cases before shipping any code). Instead, here, there's a hard
   6407 task of exercising every possible code path (at run time) before we
   6408 know if there are any type errors still lingering. I've seen some
   6409 proponents of dynamically-typed languages argue that unit testing
   6410 should provide the same coverage that a statically-typed compiler
   6411 would, but I haven't seen that in practice.
   6412 
   6413 You all definitely have a lot more experience with ruby than I do, so
   6414 I'm honestly interested in learning form your experience. What do you
   6415 do to deal with cases like this?
   6416 -------------- next part --------------
   6417 A non-text attachment was scrubbed...
   6418 Name: 0001-Convert-a-couple-of-arrays-to-sets-for-labels.patch
   6419 Type: application/octet-stream
   6420 Size: 1685 bytes
   6421 Desc: not available
   6422 URL: <http://rubyforge.org/pipermail/sup-talk/attachments/20090819/c4120e6d/attachment.obj>
   6423 -------------- next part --------------
   6424 A non-text attachment was scrubbed...
   6425 Name: signature.asc
   6426 Type: application/pgp-signature
   6427 Size: 189 bytes
   6428 Desc: not available
   6429 URL: <http://rubyforge.org/pipermail/sup-talk/attachments/20090819/c4120e6d/attachment.bin>
   6430 
   6431 From bwalton@artsci.utoronto.ca  Wed Aug 19 22:57:25 2009
   6432 From: bwalton@artsci.utoronto.ca (Ben Walton)
   6433 Date: Wed, 19 Aug 2009 22:57:25 -0400
   6434 Subject: [sup-talk] In next: thread-view-mode labelling No method join
   6435 	for Set
   6436 In-Reply-To: <1250727630-sup-3112@yoom.home.cworth.org>
   6437 References: <1250714501-sup-3033@chigamba>
   6438 	<1250727630-sup-3112@yoom.home.cworth.org>
   6439 Message-ID: <1250734085-sup-2162@ntdws12.chass.utoronto.ca>
   6440 
   6441 Excerpts from Carl Worth's message of Wed Aug 19 20:31:12 -0400 2009:
   6442 
   6443 > [*] Totally off-topic: This is one of the things about "dynamically
   6444 > typed" languages that I've never been able to wrap my brain around. I
   6445 > really like that with static typing I can trust the compiler to help
   6446 > me be very thorough if I make a type change like this, (and catch all
   6447 > the cases before shipping any code). Instead, here, there's a hard
   6448 > task of exercising every possible code path (at run time) before we
   6449 > know if there are any type errors still lingering. I've seen some
   6450 > proponents of dynamically-typed languages argue that unit testing
   6451 > should provide the same coverage that a statically-typed compiler
   6452 > would, but I haven't seen that in practice.
   6453 
   6454 The term you'll see bandied about in ruby circles/books/etc is 'duck
   6455 typing' which coming from strongly typed languages is definitely
   6456 something that takes some getting used to.  Basically, instead of
   6457 caring about the type of the object, you case about what the object
   6458 does.  If it walks like a duck and quacks like a duck, treat it like a
   6459 duck.
   6460 
   6461 A very simple example is a function that expects to append data to
   6462 another object.  You could pass it a string (which uses << to append)
   6463 or an array (which uses << to push elements on the end).  If you
   6464 originally passed a string, but found performance (memory ->
   6465 realloc()) issues, you could swap the string object for an array
   6466 object and do array.join when everything is collected into array
   6467 elements.
   6468 
   6469 Then, you'll see many examples where there is code like:
   6470 
   6471 raise SomeException, "blah" unless someobject.respond_to?(:somemethod)
   6472 
   6473 Your code doesn't care _what kind_ of object it gets as long as it
   6474 knows _how_ to talk to it.
   6475 
   6476 Personally, I really like this.  Ruby isn't perfect by any stretch,
   6477 but of all the languages I've used, it's hands down the most fun to
   6478 write.
   6479 
   6480 -Ben
   6481 -- 
   6482 Ben Walton
   6483 Systems Programmer - CHASS
   6484 University of Toronto
   6485 C:416.407.5610 | W:416.978.4302
   6486 
   6487 GPG Key Id: 8E89F6D2; Key Server: pgp.mit.edu
   6488 Contact me to arrange for a CAcert assurance meeting.
   6489 -------------- next part --------------
   6490 A non-text attachment was scrubbed...
   6491 Name: signature.asc
   6492 Type: application/pgp-signature
   6493 Size: 189 bytes
   6494 Desc: not available
   6495 URL: <http://rubyforge.org/pipermail/sup-talk/attachments/20090819/a644ea46/attachment.bin>
   6496 
   6497 From cworth@cworth.org  Thu Aug 20 00:03:08 2009
   6498 From: cworth@cworth.org (Carl Worth)
   6499 Date: Wed, 19 Aug 2009 21:03:08 -0700
   6500 Subject: [sup-talk] In next: thread-view-mode labelling No method join
   6501 	for Set
   6502 In-Reply-To: <1250734085-sup-2162@ntdws12.chass.utoronto.ca>
   6503 References: <1250714501-sup-3033@chigamba>
   6504 	<1250727630-sup-3112@yoom.home.cworth.org>
   6505 	<1250734085-sup-2162@ntdws12.chass.utoronto.ca>
   6506 Message-ID: <1250740488-sup-1624@yoom.home.cworth.org>
   6507 
   6508 Excerpts from Ben Walton's message of Wed Aug 19 19:57:25 -0700 2009:
   6509 > Excerpts from Carl Worth's message of Wed Aug 19 20:31:12 -0400 2009:
   6510 > 
   6511 > > [*] Totally off-topic: This is one of the things about "dynamically
   6512 > > typed" languages that I've never been able to wrap my brain around. I
   6513 > > really like that with static typing I can trust the compiler to help
   6514 > > me be very thorough if I make a type change like this, (and catch all
   6515 > > the cases before shipping any code).
   6516 ...
   6517 > The term you'll see bandied about in ruby circles/books/etc is 'duck
   6518 > typing' which coming from strongly typed languages is definitely
   6519 > something that takes some getting used to.  Basically, instead of
   6520 > caring about the type of the object, you case about what the object
   6521 > does.  If it walks like a duck and quacks like a duck, treat it like a
   6522 > duck.
   6523 
   6524 Yes, I understand that just fine. But two points:
   6525 
   6526 1. That's not actually helping in the current case where we're trying
   6527    to do simple things like '+' and the distinction between Set and
   6528    Array is causing problems. (See the patch where we're having to add
   6529    .to_a and Set.new to coerce things.) So, here, at least things are
   6530    falling down. So somehow something in ruby isn't living up to the
   6531    concept here.
   6532 
   6533 > Then, you'll see many examples where there is code like:
   6534 > 
   6535 > raise SomeException, "blah" unless someobject.respond_to?(:somemethod)
   6536 >
   6537 > Your code doesn't care _what kind_ of object it gets as long as it
   6538 > knows _how_ to talk to it.
   6539 
   6540 2. Even with the "duck typing" I'd still like to express this
   6541    constraint in a way that is decidable statically. I've definitely
   6542    failed as a programmer if a user sees a runtime exception like
   6543    that. Sytems with sophisticated runtimes are very interesting to
   6544    me. It's just discouraging to me that so many such systems fail to
   6545    actually help me avoid problems like this before the user is
   6546    running my code.
   6547 
   6548 > Personally, I really like this.  Ruby isn't perfect by any stretch,
   6549 > but of all the languages I've used, it's hands down the most fun to
   6550 > write.
   6551 
   6552 That could still be the case for me here. I haven't tried much with it
   6553 yet, so I don't have any strong opinion there yet. :-)
   6554 
   6555 -Carl
   6556 -------------- next part --------------
   6557 A non-text attachment was scrubbed...
   6558 Name: signature.asc
   6559 Type: application/pgp-signature
   6560 Size: 189 bytes
   6561 Desc: not available
   6562 URL: <http://rubyforge.org/pipermail/sup-talk/attachments/20090819/aae17dcd/attachment.bin>
   6563 
   6564 From cworth@cworth.org  Thu Aug 20 01:25:39 2009
   6565 From: cworth@cworth.org (Carl Worth)
   6566 Date: Wed, 19 Aug 2009 22:25:39 -0700
   6567 Subject: [sup-talk] [PATCH] Make SUP_LOG_LEVEL self-documenting.
   6568 Message-ID: <1250745799-sup-6607@yoom.home.cworth.org>
   6569 
   6570 The idea here is that if someone is looking at the log and not seeing
   6571 the information of interest, then the log itself should tell them
   6572 how to get more information, (by suggesting to set SUP_LOG_LEVEL
   6573 to the next lower level).
   6574 ---
   6575 
   6576 I'm probably still off as far as standard ruby idioms, (and I'm
   6577 probably committing some sup layer violations as well). But hopefully
   6578 you get the idea. I went to the log looking for details, couldn't find
   6579 them, and had to resort to searching the mailing list for the exact
   6580 name of the SUP_LOG_LEVEL variable.
   6581 
   6582  bin/sup           |    3 +++
   6583  lib/sup/logger.rb |    2 ++
   6584  2 files changed, 5 insertions(+), 0 deletions(-)
   6585 
   6586 diff --git a/bin/sup b/bin/sup
   6587 index 3d5b6c1..afe2233 100755
   6588 --- a/bin/sup
   6589 +++ b/bin/sup
   6590 @@ -169,6 +169,9 @@ begin
   6591    lmode.on_kill { Logger.clear! }
   6592    Logger.add_sink lmode
   6593    Logger.force_message "Welcome to Sup! Log level is set to #{Logger.level}."
   6594 +  if Logger.LEVELS.index(Logger.level) > 0
   6595 +    Logger.force_message "For more verbose logging, restart with SUP_LOG_LEVEL=#{Logger.LEVELS[Logger.LEVELS.index(Logger.level)-1]}."
   6596 +  end
   6597  
   6598    debug "initializing inbox buffer"
   6599    imode = InboxMode.new
   6600 diff --git a/lib/sup/logger.rb b/lib/sup/logger.rb
   6601 index ccaeae0..8567174 100644
   6602 --- a/lib/sup/logger.rb
   6603 +++ b/lib/sup/logger.rb
   6604 @@ -12,6 +12,8 @@ class Logger
   6605  
   6606    LEVELS = %w(debug info warn error) # in order!
   6607  
   6608 +  def LEVELS; LEVELS end
   6609 +
   6610    def initialize level=nil
   6611      level ||= ENV["SUP_LOG_LEVEL"] || "info"
   6612      @level = LEVELS.index(level) or raise ArgumentError, "invalid log level #{level.inspect}: should be one of #{LEVELS * ', '}"
   6613 -- 
   6614 1.6.3.3
   6615 -------------- next part --------------
   6616 A non-text attachment was scrubbed...
   6617 Name: signature.asc
   6618 Type: application/pgp-signature
   6619 Size: 189 bytes
   6620 Desc: not available
   6621 URL: <http://rubyforge.org/pipermail/sup-talk/attachments/20090819/8eb1635a/attachment.bin>
   6622 
   6623 From cworth@cworth.org  Thu Aug 20 02:31:25 2009
   6624 From: cworth@cworth.org (Carl Worth)
   6625 Date: Wed, 19 Aug 2009 23:31:25 -0700
   6626 Subject: [sup-talk] [PATCH] Be less overzealous in moving text to the left
   6627 	column
   6628 Message-ID: <1250749447-sup-1744@yoom.home.cworth.org>
   6629 
   6630 Specifically, scroll as little as possible to get the current message
   6631 to just fit on the right side.
   6632 ---
   6633 
   6634 This seems to work quite nicely and I think is ready to be comitted as
   6635 is. It's still not perfect in a few ways though, which I think we can
   6636 leave for subsequent commits:
   6637 
   6638 1. I *think* that with this change the loose_alignment mode is
   6639    unnecessary. But I confess that I didn't totally understand the
   6640    calculation it is making, so I tried to just preserve its behavior
   6641    rather than ripping it out.
   6642 
   6643 2. In deep threads of short messages, (so that lots of nesting is
   6644    visible in one screenful), it's easier than it was before for
   6645    messages other than the current message to be scrolled off to the
   6646    right, (though the current message is always made to fit if
   6647    possible). I can imagine someone finding the current patch
   6648    unacceptable based on this.
   6649 
   6650    The fix for this would be to consider the total width of all
   6651    visible messages when making the calculation made here, rather than
   6652    just the width of the current message. I'm not sure how readily
   6653    available that number is.
   6654 
   6655 3. It's still easy to get stuff scrolled off to the left, (which was a
   6656    symptom of the original bug I'm trying to fix), when doing
   6657    something like (E: Expand all messages). This command should
   6658    recompute a left column, so perhaps we should abstract the
   6659    left-column calculation out to some shared place.
   6660 
   6661 Anyway, all feedback is quite welcome,
   6662 
   6663 -Carl (happy to finally be running code from git and contributing patches)
   6664 
   6665  lib/sup/modes/thread-view-mode.rb |    3 +++
   6666  1 files changed, 3 insertions(+), 0 deletions(-)
   6667 
   6668 diff --git a/lib/sup/modes/thread-view-mode.rb b/lib/sup/modes/thread-view-mode.rb
   6669 index dfe30ff..678b841 100644
   6670 --- a/lib/sup/modes/thread-view-mode.rb
   6671 +++ b/lib/sup/modes/thread-view-mode.rb
   6672 @@ -423,6 +423,9 @@ EOS
   6673          0
   6674        end
   6675  
   6676 +    ## scroll as little as possible to make the message fit
   6677 +    ideal_left = (-(buffer.content_width - l.width - left - 1)).clamp(0, ideal_left)
   6678 +
   6679      jump_to_col [ideal_left, 0].max
   6680  
   6681      ## either way, move the cursor to the first line
   6682 -- 
   6683 1.6.3.3
   6684 
   6685 
   6686 -------------- next part --------------
   6687 A non-text attachment was scrubbed...
   6688 Name: signature.asc
   6689 Type: application/pgp-signature
   6690 Size: 189 bytes
   6691 Desc: not available
   6692 URL: <http://rubyforge.org/pipermail/sup-talk/attachments/20090819/16ea9c2d/attachment.bin>
   6693 
   6694 From cworth@cworth.org  Thu Aug 20 13:07:16 2009
   6695 From: cworth@cworth.org (Carl Worth)
   6696 Date: Thu, 20 Aug 2009 10:07:16 -0700
   6697 Subject: [sup-talk] On making kill-thread easier
   6698 Message-ID: <1250785604-sup-5488@yoom.home.cworth.org>
   6699 
   6700 I wrote a long post that started out talking about workflows, but then
   6701 went on into just a dump of feature requests. I'd like to get back to
   6702 talking about workflows again a bit.
   6703 
   6704 I find that when processing my mail in inbox-mode I do a first pass
   6705 with one of two different actions on each thread:
   6706 
   6707 	1. 'a' to archive the thread without reading
   6708 or:
   6709 	2. <down-arrow> to leave the thread in my inbox for reading on
   6710 	   a later pass.
   6711 
   6712 But this misses out on the killer-feature that was one of the things
   6713 that made me most interested in sup: kill-thread.
   6714 
   6715 So I can currently decide to kill a thread instead of archiving it,
   6716 but this requires extra effort on my part, (deciding that I need to do
   6717 something more than just archiving it, and then using a different
   6718 key---currently with a keybinding that requires two keys).
   6719 
   6720 What I find is that I end up using kill-thread much less frequently
   6721 than I should. Basically what ends up happening is that when a thread
   6722 comes up several times (and I keep just archiving it) before I finally
   6723 make the mental effort to kill it instead of just archiving it. And I
   6724 keep trying to train myself to not be afraid to use kill-thread more
   6725 frequently.
   6726 
   6727 But then thought occurs to me, "Shouldn't sup just see that I'm not
   6728 ever reading this thread when it reappears?".
   6729 
   6730 So I think what I actually want is a single keybinding that either
   6731 archives or kills a thread based on whether I've actually read any of
   6732 it or not. Does anybody else agree that that would be useful? Perhaps
   6733 even as the default?
   6734 
   6735 I think a first pass that only does kill-thread if the entire thread
   6736 is unread will likely be enough. I can imagine a more clever version
   6737 that kills a thread even if it's partially read but no new messages
   6738 have been read since the last time this thread was labelled as
   6739 inbox. But that's perhaps more complexity than appropriate[*] and an
   6740 explicit kill-thread command will work just fine here.
   6741 
   6742 -Carl
   6743 
   6744 [*] By the way, my concern with complexity has nothing to do with the
   6745 state management in the code---that shouldn't be bad. It's more a
   6746 matter of making the user-interface easy to explain and understand. If
   6747 a tool violates that, then it can lose a user's trust, (which can be
   6748 quite fatal for a mail client).
   6749 -------------- next part --------------
   6750 A non-text attachment was scrubbed...
   6751 Name: signature.asc
   6752 Type: application/pgp-signature
   6753 Size: 189 bytes
   6754 Desc: not available
   6755 URL: <http://rubyforge.org/pipermail/sup-talk/attachments/20090820/aefd9813/attachment.bin>
   6756 
   6757 From garoth@gmail.com  Thu Aug 20 14:19:19 2009
   6758 From: garoth@gmail.com (Andrei Thorp)
   6759 Date: Thu, 20 Aug 2009 14:19:19 -0400
   6760 Subject: [sup-talk] On making kill-thread easier
   6761 In-Reply-To: <1250785604-sup-5488@yoom.home.cworth.org>
   6762 References: <1250785604-sup-5488@yoom.home.cworth.org>
   6763 Message-ID: <1250792255-sup-4740@Longbow>
   6764 
   6765 Excerpts from Carl Worth's message of Thu Aug 20 13:07:16 -0400 2009:
   6766 > I wrote a long post that started out talking about workflows, but then
   6767 > went on into just a dump of feature requests. I'd like to get back to
   6768 > talking about workflows again a bit.
   6769 > 
   6770 > I find that when processing my mail in inbox-mode I do a first pass
   6771 > with one of two different actions on each thread:
   6772 > 
   6773 >     1. 'a' to archive the thread without reading
   6774 > or:
   6775 >     2. <down-arrow> to leave the thread in my inbox for reading on
   6776 >        a later pass.
   6777 > 
   6778 > But this misses out on the killer-feature that was one of the things
   6779 > that made me most interested in sup: kill-thread.
   6780 > 
   6781 > So I can currently decide to kill a thread instead of archiving it,
   6782 > but this requires extra effort on my part, (deciding that I need to do
   6783 > something more than just archiving it, and then using a different
   6784 > key---currently with a keybinding that requires two keys).
   6785 > 
   6786 > What I find is that I end up using kill-thread much less frequently
   6787 > than I should. Basically what ends up happening is that when a thread
   6788 > comes up several times (and I keep just archiving it) before I finally
   6789 > make the mental effort to kill it instead of just archiving it. And I
   6790 > keep trying to train myself to not be afraid to use kill-thread more
   6791 > frequently.
   6792 > 
   6793 > But then thought occurs to me, "Shouldn't sup just see that I'm not
   6794 > ever reading this thread when it reappears?".
   6795 > 
   6796 > So I think what I actually want is a single keybinding that either
   6797 > archives or kills a thread based on whether I've actually read any of
   6798 > it or not. Does anybody else agree that that would be useful? Perhaps
   6799 > even as the default?
   6800 > 
   6801 > I think a first pass that only does kill-thread if the entire thread
   6802 > is unread will likely be enough. I can imagine a more clever version
   6803 > that kills a thread even if it's partially read but no new messages
   6804 > have been read since the last time this thread was labelled as
   6805 > inbox. But that's perhaps more complexity than appropriate[*] and an
   6806 > explicit kill-thread command will work just fine here.
   6807 > 
   6808 > -Carl
   6809 > 
   6810 > [*] By the way, my concern with complexity has nothing to do with the
   6811 > state management in the code---that shouldn't be bad. It's more a
   6812 > matter of making the user-interface easy to explain and understand. If
   6813 > a tool violates that, then it can lose a user's trust, (which can be
   6814 > quite fatal for a mail client).
   6815 
   6816 Seems like making it the default is a bit cavalier. It's not good to
   6817 assume what the user wants, I think. Maybe a separate key if we want to
   6818 spare it, but I think the better solution is "learn to kill threads
   6819 already and use an explicit command for it."
   6820 -- 
   6821 Andrei Thorp, Developer: Xandros Corp. (http://www.xandros.com)
   6822 
   6823 From chris@chris-wilson.co.uk  Thu Aug 20 16:01:10 2009
   6824 From: chris@chris-wilson.co.uk (Chris Wilson)
   6825 Date: Thu, 20 Aug 2009 21:01:10 +0100
   6826 Subject: [sup-talk] On making kill-thread easier
   6827 In-Reply-To: <1250785604-sup-5488@yoom.home.cworth.org>
   6828 References: <1250785604-sup-5488@yoom.home.cworth.org>
   6829 Message-ID: <1250797598-sup-5105@tiger.alporthouse.com>
   6830 
   6831 Hi everybody! I've just started using sup after Carl told me he'd found
   6832 a fantastic new mail client. And, as usual, he was right.
   6833 
   6834 Excerpts from Carl Worth's message of Thu Aug 20 18:07:16 +0100 2009:
   6835 > But then thought occurs to me, "Shouldn't sup just see that I'm not
   6836 > ever reading this thread when it reappears?".
   6837 
   6838 I have a very similar inbox pattern to Carl, a quick pass to remove
   6839 uninteresting material before acting upon the rest. To this end, I use
   6840 '&' far less frequently than I should, because it's an awkward key
   6841 combination to use in conjunction with scrolling + archiving, and so I
   6842 am irritated by repeatedly archiving a thread which I have never read.
   6843 The behaviour I would like here is exactly: "Shouldn't sup just see that
   6844 I'm not ever reading this thread when it reappears?".
   6845 
   6846 I'd be happy to have sup automatically kill a thread that I have
   6847 archived twice without reading.
   6848 -ickle
   6849 
   6850 From garoth@gmail.com  Thu Aug 20 16:36:15 2009
   6851 From: garoth@gmail.com (Andrei Thorp)
   6852 Date: Thu, 20 Aug 2009 16:36:15 -0400
   6853 Subject: [sup-talk] On making kill-thread easier
   6854 In-Reply-To: <1250797598-sup-5105@tiger.alporthouse.com>
   6855 References: <1250785604-sup-5488@yoom.home.cworth.org>
   6856 	<1250797598-sup-5105@tiger.alporthouse.com>
   6857 Message-ID: <1250800492-sup-136@Longbow>
   6858 
   6859 Excerpts from Chris Wilson's message of Thu Aug 20 16:01:10 -0400 2009:
   6860 > Hi everybody! I've just started using sup after Carl told me he'd found
   6861 > a fantastic new mail client. And, as usual, he was right.
   6862 
   6863 If you're half as verbose as he is, I'll never have time to read it all!
   6864 ;)
   6865 -- 
   6866 Andrei Thorp, Developer: Xandros Corp. (http://www.xandros.com)
   6867 
   6868 From bwalton@artsci.utoronto.ca  Thu Aug 20 16:43:08 2009
   6869 From: bwalton@artsci.utoronto.ca (Ben Walton)
   6870 Date: Thu, 20 Aug 2009 16:43:08 -0400
   6871 Subject: [sup-talk] On making kill-thread easier
   6872 In-Reply-To: <1250797598-sup-5105@tiger.alporthouse.com>
   6873 References: <1250785604-sup-5488@yoom.home.cworth.org>
   6874 	<1250797598-sup-5105@tiger.alporthouse.com>
   6875 Message-ID: <1250800965-sup-4218@ntdws12.chass.utoronto.ca>
   6876 
   6877 Excerpts from Chris Wilson's message of Thu Aug 20 16:01:10 -0400 2009:
   6878 
   6879 > I have a very similar inbox pattern to Carl, a quick pass to remove
   6880 > uninteresting material before acting upon the rest. To this end, I use
   6881 > '&' far less frequently than I should, because it's an awkward key
   6882 > combination to use in conjunction with scrolling + archiving, and so I
   6883 > am irritated by repeatedly archiving a thread which I have never read.
   6884 > The behaviour I would like here is exactly: "Shouldn't sup just see that
   6885 > I'm not ever reading this thread when it reappears?".
   6886 
   6887 I have a similar pattern where there are lots of list messages that I
   6888 don't care about (based on subject).  I skim the inbox using 't' to
   6889 tag all messages I don't care about.  When I've tagged a bunch of
   6890 items, after the scan, I simply to '=' followed by either 'A'
   6891 (archive, mark read) or '&'.  It saves lots of shift key use and
   6892 allows me to quickly tackle a lot of mail.
   6893 
   6894 > I'd be happy to have sup automatically kill a thread that I have
   6895 > archived twice without reading.
   6896 
   6897 I think this kind of heuristic is a) hard to get right b) not required
   6898 if you do batch operations as described above.  Part b) is subject to
   6899 personal opinion, of course! :)
   6900 
   6901 HTH.
   6902 -Ben
   6903 -- 
   6904 Ben Walton
   6905 Systems Programmer - CHASS
   6906 University of Toronto
   6907 C:416.407.5610 | W:416.978.4302
   6908 
   6909 GPG Key Id: 8E89F6D2; Key Server: pgp.mit.edu
   6910 Contact me to arrange for a CAcert assurance meeting.
   6911 -------------- next part --------------
   6912 A non-text attachment was scrubbed...
   6913 Name: signature.asc
   6914 Type: application/pgp-signature
   6915 Size: 189 bytes
   6916 Desc: not available
   6917 URL: <http://rubyforge.org/pipermail/sup-talk/attachments/20090820/1dbd06f5/attachment.bin>
   6918 
   6919 From cworth@cworth.org  Thu Aug 20 17:07:28 2009
   6920 From: cworth@cworth.org (Carl Worth)
   6921 Date: Thu, 20 Aug 2009 14:07:28 -0700
   6922 Subject: [sup-talk] On making kill-thread easier
   6923 In-Reply-To: <1250800492-sup-136@Longbow>
   6924 References: <1250785604-sup-5488@yoom.home.cworth.org>
   6925 	<1250797598-sup-5105@tiger.alporthouse.com>
   6926 	<1250800492-sup-136@Longbow>
   6927 Message-ID: <1250802401-sup-2516@yoom.home.cworth.org>
   6928 
   6929 Excerpts from Andrei Thorp's message of Thu Aug 20 13:36:15 -0700 2009:
   6930 > Excerpts from Chris Wilson's message of Thu Aug 20 16:01:10 -0400 2009:
   6931 > > Hi everybody! I've just started using sup after Carl told me he'd found
   6932 > > a fantastic new mail client. And, as usual, he was right.
   6933 > 
   6934 > If you're half as verbose as he is, I'll never have time to read it all!
   6935 > ;)
   6936 
   6937 Yeah, sorry about that. I will try to be terse when I can. :-)
   6938 
   6939 Welcome, Chris!
   6940 
   6941 -Carl
   6942 -------------- next part --------------
   6943 A non-text attachment was scrubbed...
   6944 Name: signature.asc
   6945 Type: application/pgp-signature
   6946 Size: 189 bytes
   6947 Desc: not available
   6948 URL: <http://rubyforge.org/pipermail/sup-talk/attachments/20090820/481671be/attachment.bin>
   6949 
   6950 From cworth@cworth.org  Thu Aug 20 17:11:49 2009
   6951 From: cworth@cworth.org (Carl Worth)
   6952 Date: Thu, 20 Aug 2009 14:11:49 -0700
   6953 Subject: [sup-talk] On making kill-thread easier
   6954 In-Reply-To: <1250800965-sup-4218@ntdws12.chass.utoronto.ca>
   6955 References: <1250785604-sup-5488@yoom.home.cworth.org>
   6956 	<1250797598-sup-5105@tiger.alporthouse.com>
   6957 	<1250800965-sup-4218@ntdws12.chass.utoronto.ca>
   6958 Message-ID: <1250802452-sup-4348@yoom.home.cworth.org>
   6959 
   6960 Excerpts from Ben Walton's message of Thu Aug 20 13:43:08 -0700 2009:
   6961 > Excerpts from Chris Wilson's message of Thu Aug 20 16:01:10 -0400 2009:
   6962 > I have a similar pattern where there are lots of list messages that I
   6963 > don't care about (based on subject).  I skim the inbox using 't' to
   6964 > tag all messages I don't care about.  When I've tagged a bunch of
   6965 > items, after the scan, I simply to '=' followed by either 'A'
   6966 > (archive, mark read) or '&'.  It saves lots of shift key use and
   6967 > allows me to quickly tackle a lot of mail.
   6968 
   6969 Thanks, Ben!
   6970 
   6971 This is just the kind of workflow report I've been hoping to read.
   6972 
   6973 I wonder, though, what happens when you want to archive some and kill
   6974 others. Do you end up making two passes? Executing the '=' operation
   6975 partway through and then start tagging again? A quick, non-tag 'A' or
   6976 '&' for the exceptional thread? Or maybe just let a few slip by the
   6977 "wrong" direction.
   6978 
   6979 > > I'd be happy to have sup automatically kill a thread that I have
   6980 > > archived twice without reading.
   6981 > 
   6982 > I think this kind of heuristic is a) hard to get right b) not required
   6983 > if you do batch operations as described above.  Part b) is subject to
   6984 > personal opinion, of course! :)
   6985 
   6986 I plan to try a single keybinding for archive-or-kill-if-unread for a
   6987 while and see how I like it, (I'll obviously share it when I code it
   6988 up).. Of course, the failure mode is hiding messages from me, so it
   6989 might be hard for me to know if it fails. :-)
   6990 
   6991 -Carl
   6992 -------------- next part --------------
   6993 A non-text attachment was scrubbed...
   6994 Name: signature.asc
   6995 Type: application/pgp-signature
   6996 Size: 189 bytes
   6997 Desc: not available
   6998 URL: <http://rubyforge.org/pipermail/sup-talk/attachments/20090820/cec04ef5/attachment.bin>
   6999 
   7000 From bwalton@artsci.utoronto.ca  Thu Aug 20 18:56:52 2009
   7001 From: bwalton@artsci.utoronto.ca (Ben Walton)
   7002 Date: Thu, 20 Aug 2009 18:56:52 -0400
   7003 Subject: [sup-talk] On making kill-thread easier
   7004 In-Reply-To: <1250802452-sup-4348@yoom.home.cworth.org>
   7005 References: <1250785604-sup-5488@yoom.home.cworth.org>
   7006 	<1250797598-sup-5105@tiger.alporthouse.com>
   7007 	<1250800965-sup-4218@ntdws12.chass.utoronto.ca>
   7008 	<1250802452-sup-4348@yoom.home.cworth.org>
   7009 Message-ID: <1250808931-sup-3198@ntdws12.chass.utoronto.ca>
   7010 
   7011 Excerpts from Carl Worth's message of Thu Aug 20 17:11:49 -0400 2009:
   7012 > I wonder, though, what happens when you want to archive some and kill
   7013 > others. Do you end up making two passes? Executing the '=' operation
   7014 > partway through and then start tagging again? A quick, non-tag 'A' or
   7015 > '&' for the exceptional thread? Or maybe just let a few slip by the
   7016 > "wrong" direction.
   7017 
   7018 I typically do a big pass to 'A' or '&' large numbers of things.  That
   7019 knocks the list to a point where I can either do another smaller pass
   7020 where I'll apply labels and skim things.  My last pass is for things I
   7021 actually read, many of which get archived right away too.  I don't
   7022 completely practice 'inbox 0' but I do follow many of its tenets.
   7023 
   7024 My own personal habits are such that an archived thread has to really
   7025 bug me before I kill it, so much of the first (morning) pass is for
   7026 'A.'  Part of this is because while I don't want to necessarily follow
   7027 a thread, there is potential for interesting things to pop in late in
   7028 the game (many of these are on the git ml)...so, after I see a lot of
   7029 activity on it, I may scan the thread or possibly read it.
   7030 
   7031 Bike shedding gets killed quickly! :)
   7032 
   7033 > I plan to try a single keybinding for archive-or-kill-if-unread for a
   7034 > while and see how I like it, (I'll obviously share it when I code it
   7035 > up).. Of course, the failure mode is hiding messages from me, so it
   7036 > might be hard for me to know if it fails. :-)
   7037 
   7038 If you get into adding code, consider writing it such that there is an
   7039 available Hook that overrides the default behaviour.  This may get you
   7040 the best of all outcomes.  It'd be useful for you and more likely to
   7041 be useful for others.
   7042 
   7043 HTH.
   7044 -Ben
   7045 -- 
   7046 Ben Walton
   7047 Systems Programmer - CHASS
   7048 University of Toronto
   7049 C:416.407.5610 | W:416.978.4302
   7050 
   7051 GPG Key Id: 8E89F6D2; Key Server: pgp.mit.edu
   7052 Contact me to arrange for a CAcert assurance meeting.
   7053 -------------- next part --------------
   7054 A non-text attachment was scrubbed...
   7055 Name: signature.asc
   7056 Type: application/pgp-signature
   7057 Size: 189 bytes
   7058 Desc: not available
   7059 URL: <http://rubyforge.org/pipermail/sup-talk/attachments/20090820/0226132d/attachment.bin>
   7060 
   7061 From cworth@cworth.org  Thu Aug 20 20:09:30 2009
   7062 From: cworth@cworth.org (Carl Worth)
   7063 Date: Thu, 20 Aug 2009 17:09:30 -0700
   7064 Subject: [sup-talk] On making kill-thread easier
   7065 In-Reply-To: <1250808931-sup-3198@ntdws12.chass.utoronto.ca>
   7066 References: <1250785604-sup-5488@yoom.home.cworth.org>
   7067 	<1250797598-sup-5105@tiger.alporthouse.com>
   7068 	<1250800965-sup-4218@ntdws12.chass.utoronto.ca>
   7069 	<1250802452-sup-4348@yoom.home.cworth.org>
   7070 	<1250808931-sup-3198@ntdws12.chass.utoronto.ca>
   7071 Message-ID: <1250812689-sup-2614@yoom.home.cworth.org>
   7072 
   7073 Excerpts from Ben Walton's message of Thu Aug 20 15:56:52 -0700 2009:
   7074 > My own personal habits are such that an archived thread has to really
   7075 > bug me before I kill it, so much of the first (morning) pass is for
   7076 > 'A.'  Part of this is because while I don't want to necessarily follow
   7077 > a thread, there is potential for interesting things to pop in late in
   7078 > the game (many of these are on the git ml)...so, after I see a lot of
   7079 > activity on it, I may scan the thread or possibly read it.
   7080 
   7081 Thanks. Those are good points. I've definitely seen some interesting
   7082 stuff on the git mailing list where threads start off looking
   7083 worthless, but then Linus comes in with some gem of insight and things
   7084 take off again.
   7085 
   7086 See Joey's post on thread patterns for some examples here:
   7087 
   7088 	http://joey.kitenet.net/blog/entry/thread_patterns/
   7089 
   7090 > Bike shedding gets killed quickly! :)
   7091 
   7092 Yes! Bike shedding without kill-thread available is a lot more painful.
   7093 
   7094 I guess part of what I'm getting at with the idea of merging "archive"
   7095 and "kill-thread" is that I think the distinction between these two
   7096 commands forces the user to get a little too chummy with details of
   7097 the mail store.
   7098 
   7099 I wrote a long post about sup and mail in general here:
   7100 
   7101 	http://cworth.org/sup/a-mail-client-for-geeks/ [*]
   7102 
   7103 and one of the ideas I start talking about there is that I'd like my
   7104 mail client to present me with "Here's what you should find most
   7105 interesting right now", and I can implicitly give the system feedback
   7106 by either reading it or not. So "archive" vs. "kill" feels like manual
   7107 tuning of what would ideally be an automated process.
   7108 
   7109 Of course, getting that process automated and working well is likely
   7110 an open research topic. I'd love for the system to take tags into
   7111 account, authors of messages, my history of reading (or not) posts by
   7112 given authors, etc. Obviously, sup's not going to acquire that kind of
   7113 functionality instantly, but it likely makes a good basis already for
   7114 someone who wants to explore that kind of thing.
   7115 
   7116 So, ideas of mine like "sort certain tags before sorting by date", and
   7117 "merge archive and thread into a single key" I think are both just
   7118 baby steps toward the Big Idea I'd love to see someone tackle. Anyone
   7119 looking for a good M.S. thesis around here? (So much research has been
   7120 dedicated to spam, but has there been as much to sorting out the ham?
   7121 I should ask my C.S-professor-friend---he'd be up on the current state
   7122 of the literature here.)
   7123 
   7124 -Carl
   7125 
   7126 [*] See, I'm keeping some of my verbosity off the list at least. ;-)
   7127 -------------- next part --------------
   7128 A non-text attachment was scrubbed...
   7129 Name: signature.asc
   7130 Type: application/pgp-signature
   7131 Size: 189 bytes
   7132 Desc: not available
   7133 URL: <http://rubyforge.org/pipermail/sup-talk/attachments/20090820/3ed0cc42/attachment.bin>
   7134 
   7135 From bwalton@artsci.utoronto.ca  Thu Aug 20 20:16:23 2009
   7136 From: bwalton@artsci.utoronto.ca (Ben Walton)
   7137 Date: Thu, 20 Aug 2009 20:16:23 -0400
   7138 Subject: [sup-talk] In next: thread-view-mode labelling No method join
   7139 	for Set
   7140 In-Reply-To: <1250740488-sup-1624@yoom.home.cworth.org>
   7141 References: <1250714501-sup-3033@chigamba>
   7142 	<1250727630-sup-3112@yoom.home.cworth.org>
   7143 	<1250734085-sup-2162@ntdws12.chass.utoronto.ca>
   7144 	<1250740488-sup-1624@yoom.home.cworth.org>
   7145 Message-ID: <1250813245-sup-6519@ntdws12.chass.utoronto.ca>
   7146 
   7147 Excerpts from Carl Worth's message of Thu Aug 20 00:03:08 -0400 2009:
   7148 
   7149 > 1. That's not actually helping in the current case where we're trying
   7150 >    to do simple things like '+' and the distinction between Set and
   7151 >    Array is causing problems. (See the patch where we're having to add
   7152 >    .to_a and Set.new to coerce things.) So, here, at least things are
   7153 >    falling down. So somehow something in ruby isn't living up to the
   7154 >    concept here.
   7155 
   7156 You're correct.  The difference between fixing this in Ruby vs fixing
   7157 this in a strongly typed language though is that you could implement
   7158 Set#join such that the code expecting an array wouldn't know the
   7159 difference _or_ you could have that code use kind_of?(Array) to ensure
   7160 it was getting the type of argument it was expecting.  Both are
   7161 technically correct.
   7162 
   7163 In a strongly typed language, you'd have to modify the acceptable
   7164 arguments (function definition) and ensure everything that called the
   7165 function passed something acceptable or provide an overloaded version
   7166 (if you're working with a language that supports it).
   7167 
   7168 Those are correct solutions too.
   7169 
   7170 > > Your code doesn't care _what kind_ of object it gets as long as it
   7171 > > knows _how_ to talk to it.
   7172 > 
   7173 > 2. Even with the "duck typing" I'd still like to express this
   7174 >    constraint in a way that is decidable statically. I've definitely
   7175 >    failed as a programmer if a user sees a runtime exception like
   7176 >    that. Sytems with sophisticated runtimes are very interesting to
   7177 >    me. It's just discouraging to me that so many such systems fail to
   7178 >    actually help me avoid problems like this before the user is
   7179 >    running my code.
   7180 
   7181 Bugs are bugs! :)  Static typing only goes so far to prevent some of
   7182 this stuff...just look what you can make a C compiler do with funky
   7183 casts.  I take your point though.
   7184 
   7185 -Ben
   7186 -- 
   7187 Ben Walton
   7188 Systems Programmer - CHASS
   7189 University of Toronto
   7190 C:416.407.5610 | W:416.978.4302
   7191 
   7192 GPG Key Id: 8E89F6D2; Key Server: pgp.mit.edu
   7193 Contact me to arrange for a CAcert assurance meeting.
   7194 -------------- next part --------------
   7195 A non-text attachment was scrubbed...
   7196 Name: signature.asc
   7197 Type: application/pgp-signature
   7198 Size: 189 bytes
   7199 Desc: not available
   7200 URL: <http://rubyforge.org/pipermail/sup-talk/attachments/20090820/575e53e4/attachment.bin>
   7201 
   7202 From cworth@cworth.org  Thu Aug 20 21:36:28 2009
   7203 From: cworth@cworth.org (Carl Worth)
   7204 Date: Thu, 20 Aug 2009 18:36:28 -0700
   7205 Subject: [sup-talk] On making kill-thread easier
   7206 In-Reply-To: <1250800965-sup-4218@ntdws12.chass.utoronto.ca>
   7207 References: <1250785604-sup-5488@yoom.home.cworth.org>
   7208 	<1250797598-sup-5105@tiger.alporthouse.com>
   7209 	<1250800965-sup-4218@ntdws12.chass.utoronto.ca>
   7210 Message-ID: <1250817987-sup-7256@yoom.home.cworth.org>
   7211 
   7212 Excerpts from Ben Walton's message of Thu Aug 20 13:43:08 -0700 2009:
   7213 > Excerpts from Chris Wilson's message of Thu Aug 20 16:01:10 -0400 2009:
   7214 >
   7215 > > I'd be happy to have sup automatically kill a thread that I have
   7216 > > archived twice without reading.
   7217 > 
   7218 > I think this kind of heuristic is a) hard to get right b) not required
   7219 > if you do batch operations as described above.  Part b) is subject to
   7220 > personal opinion, of course! :)
   7221 
   7222 [Here's one last thought from me in this thread before I come back
   7223 next time with actual code and maybe some experience in using it.]
   7224 
   7225 Since, by nature of being a heuristic, this kind of thing can't be
   7226 perfect, and since the cost of a false positive is high, (an important
   7227 message being killed and never seen), here's another idea:
   7228 
   7229 First, leave killing to the user as an explicit action.
   7230 
   7231 Second, use the heuristics not for killing messages, but merely for
   7232 prioritizing them in the inbox. But since the inbox might often be
   7233 small, it's not adequate to move the "uninteresting" messages to the
   7234 bottom. Instead threads that the heuristic identifies as "likely
   7235 uninteresting" could have a delay attached to them before they are
   7236 presented again in the inbox, (not too unlike throttling proposed for
   7237 mailing-list servers to keep flamewars in check).
   7238 
   7239 This way instead of pestering the user with the bikeshedding until the
   7240 user finally kills the thread in frustration, the bikeshedding could
   7241 get delayed until the next morning's sweep where a day's worth of
   7242 bikeshedding would be easy to identify and easy to kill.
   7243 
   7244 So maybe something like "Once I archive a thread twice without
   7245 reading, don't show it to me again until tomorrow" or so. That might
   7246 be interesting to try out.
   7247 
   7248 -Carl
   7249 -------------- next part --------------
   7250 A non-text attachment was scrubbed...
   7251 Name: signature.asc
   7252 Type: application/pgp-signature
   7253 Size: 189 bytes
   7254 Desc: not available
   7255 URL: <http://rubyforge.org/pipermail/sup-talk/attachments/20090820/aefb8350/attachment.bin>
   7256 
   7257 From kevinr@free-dissociation.com  Thu Aug 20 21:57:42 2009
   7258 From: kevinr@free-dissociation.com (Kevin Riggle)
   7259 Date: Thu, 20 Aug 2009 21:57:42 -0400
   7260 Subject: [sup-talk] [PATCH] Add an after-add-message hook
   7261 In-Reply-To: <1250707991-sup-5429@masanjin.net>
   7262 References: <1250707991-sup-5429@masanjin.net>
   7263 Message-ID: <1250819862-4858-1-git-send-email-kevinr@free-dissociation.com>
   7264 
   7265 This time the loop stores messages in an array as they're added to the
   7266 index, and passes that array to the hook.
   7267 
   7268 I want to do some unrelated processing on each message I receive, but I
   7269 don't want to block the message being added to the index.  This patch
   7270 adds a hook which runs /after/ the message is added to the index.
   7271 ---
   7272  lib/sup/poll.rb |   10 ++++++++++
   7273  1 files changed, 10 insertions(+), 0 deletions(-)
   7274 
   7275 diff --git a/lib/sup/poll.rb b/lib/sup/poll.rb
   7276 index 8a9d218..fb3aacf 100644
   7277 --- a/lib/sup/poll.rb
   7278 +++ b/lib/sup/poll.rb
   7279 @@ -11,6 +11,12 @@ Variables:
   7280    message: the new message
   7281  EOS
   7282  
   7283 +  HookManager.register "after-add-message", <<EOS
   7284 +Executes after all messages are added to the index.
   7285 +Variables:
   7286 +  messages: an array of the new messages added
   7287 +EOS
   7288 +
   7289    HookManager.register "before-poll", <<EOS
   7290  Executes immediately before a poll for new messages commences.
   7291  No variables.
   7292 @@ -138,6 +144,7 @@ EOS
   7293      begin
   7294        return if source.done? || source.has_errors?
   7295  
   7296 +      messages = []
   7297        source.each do |offset, default_labels|
   7298          if source.has_errors?
   7299            Redwood::log "error loading messages from #{source}: #{source.error.message}"
   7300 @@ -145,6 +152,7 @@ EOS
   7301          end
   7302  
   7303          m_new = Message.build_from_source source, offset
   7304 +        messages.push(m_new)
   7305          m_old = Index.build_message m_new.id
   7306  
   7307          m_new.labels += default_labels + (source.archived? ? [] : [:inbox])
   7308 @@ -157,6 +165,8 @@ EOS
   7309          Index.sync_message m_ret, opts
   7310          UpdateManager.relay self, :added, m_ret unless m_old
   7311        end
   7312 +      HookManager.run "after-add-message", :messages => messages
   7313 +
   7314      rescue SourceError => e
   7315        Redwood::log "problem getting messages from #{source}: #{e.message}"
   7316        Redwood::report_broken_sources :force_to_top => true
   7317 -- 
   7318 1.6.0.4
   7319 
   7320 
   7321 From kevinr@free-dissociation.com  Thu Aug 20 22:07:17 2009
   7322 From: kevinr@free-dissociation.com (Kevin Riggle)
   7323 Date: Thu, 20 Aug 2009 22:07:17 -0400
   7324 Subject: [sup-talk] [PATCH] Add an after-add-message hook
   7325 In-Reply-To: <1250707991-sup-5429@masanjin.net>
   7326 References: <1250459229-4500-1-git-send-email-kevinr@free-dissociation.com>
   7327 	<1250618123-sup-8797@masanjin.net>
   7328 	<1250638381-sup-2952@black-opal.mit.edu>
   7329 	<1250707991-sup-5429@masanjin.net>
   7330 Message-ID: <1250820245-sup-2250@black-opal.mit.edu>
   7331 
   7332 Excerpts from William Morgan's message of Wed Aug 19 14:55:03 -0400 2009:
   7333 > Reformatted excerpts from Kevin Riggle's message of 2009-08-18:
   7334 > > I don't /think/ so, unless I misunderstand the way hooks work.  I
   7335 > > assumed the hook would execute and then execution of the loop would
   7336 > > resume, and I don't think I throw anything in the hook which should
   7337 > > cause that either.
   7338 > 
   7339 > What I'm saying is that this hook will execute *after* each message is
   7340 > added to the index, so if Sup found several new messages, all except the
   7341 > first one will wait on this hook to execute before being added to the
   7342 > index. Or do you mean block in some sense besides "wait for completion"?
   7343 
   7344 Oh, duh.  I take your point -- I've sent a new patch.
   7345 
   7346 - Kevin
   7347 -- 
   7348 Kevin Riggle (kevinr at free-dissociation.com) 
   7349 http://free-dissociation.com
   7350 
   7351 From cworth@cworth.org  Thu Aug 20 22:09:15 2009
   7352 From: cworth@cworth.org (Carl Worth)
   7353 Date: Thu, 20 Aug 2009 19:09:15 -0700
   7354 Subject: [sup-talk] 'next' crash: wrong id called on nil (thread.rb:264:in
   7355 	`thread_for')
   7356 Message-ID: <1250820431-sup-8159@yoom.home.cworth.org>
   7357 
   7358 I'm running sup next, (3de96fb9b308afe600c7ccfcee75913f039ef4f6 + 3
   7359 patches that I've posted to this list, but which I hope are not
   7360 relevant here), and I got the following crash.
   7361 
   7362 My best recollection is that I had just sent a reply, and then hit
   7363 ".a".
   7364 
   7365 Anything here look like an obvious fix for someone?
   7366 
   7367 -Carl
   7368 
   7369 --- RuntimeError from thread: main
   7370 wrong id called on nil
   7371 ./lib/sup.rb:17:in `id'
   7372 ./lib/sup/thread.rb:264:in `thread_for'
   7373 ./lib/sup/modes/thread-index-mode.rb:702:in `thread_containing'
   7374 ./lib/sup/modes/thread-index-mode.rb:702:in `synchronize'
   7375 ./lib/sup/modes/thread-index-mode.rb:702:in `thread_containing'
   7376 ./lib/sup/modes/thread-index-mode.rb:173:in `handle_simple_update'
   7377 ./lib/sup/modes/thread-index-mode.rb:180:in `handle_archived_update'
   7378 ./lib/sup/update.rb:26:in `send'
   7379 ./lib/sup/update.rb:26:in `relay'
   7380 ./lib/sup/update.rb:26:in `each'
   7381 ./lib/sup/update.rb:26:in `relay'
   7382 ./lib/sup/util.rb:520:in `send'
   7383 ./lib/sup/util.rb:520:in `method_missing'
   7384 ./lib/sup/modes/thread-view-mode.rb:481:in `archive_and_then'
   7385 ./lib/sup/modes/thread-view-mode.rb:515:in `dispatch'
   7386 ./lib/sup/modes/thread-view-mode.rb:525:in `call'
   7387 ./lib/sup/modes/thread-view-mode.rb:525:in `dispatch'
   7388 ./lib/sup/modes/thread-view-mode.rb:479:in `archive_and_then'
   7389 ./lib/sup/modes/thread-view-mode.rb:461:in `archive_and_kill'
   7390 ./lib/sup/mode.rb:50:in `send'
   7391 ./lib/sup/mode.rb:50:in `handle_input'
   7392 ./lib/sup/buffer.rb:260:in `handle_input'
   7393 ./bin/sup:237
   7394 
   7395 -------------- next part --------------
   7396 A non-text attachment was scrubbed...
   7397 Name: signature.asc
   7398 Type: application/pgp-signature
   7399 Size: 189 bytes
   7400 Desc: not available
   7401 URL: <http://rubyforge.org/pipermail/sup-talk/attachments/20090820/c9929115/attachment.bin>
   7402 
   7403 From chris@chris-wilson.co.uk  Fri Aug 21 11:16:26 2009
   7404 From: chris@chris-wilson.co.uk (Chris Wilson)
   7405 Date: Fri, 21 Aug 2009 16:16:26 +0100
   7406 Subject: [sup-talk] On making kill-thread easier
   7407 In-Reply-To: <1250800965-sup-4218@ntdws12.chass.utoronto.ca>
   7408 References: <1250785604-sup-5488@yoom.home.cworth.org>
   7409 	<1250797598-sup-5105@tiger.alporthouse.com>
   7410 	<1250800965-sup-4218@ntdws12.chass.utoronto.ca>
   7411 Message-ID: <1250867140-sup-2558@tiger.alporthouse.com>
   7412 
   7413 Excerpts from Ben Walton's message of Thu Aug 20 21:43:08 +0100 2009:
   7414 > I skim the inbox using 't' to
   7415 > tag all messages I don't care about.  When I've tagged a bunch of
   7416 > items, after the scan, I simply to '=' followed by either 'A'
   7417 > (archive, mark read) or '&'.
   7418 
   7419 This works very nicely, thanks. Though I miss the subtly of why you
   7420 use 'A' rather than 'a'. Could you explain the difference this makes?
   7421 -ickle
   7422 
   7423 From ezyang@MIT.EDU  Fri Aug 21 11:19:35 2009
   7424 From: ezyang@MIT.EDU (Edward Z. Yang)
   7425 Date: Fri, 21 Aug 2009 11:19:35 -0400
   7426 Subject: [sup-talk] On making kill-thread easier
   7427 In-Reply-To: <1250867140-sup-2558@tiger.alporthouse.com>
   7428 References: <1250785604-sup-5488@yoom.home.cworth.org>
   7429 	<1250797598-sup-5105@tiger.alporthouse.com>
   7430 	<1250800965-sup-4218@ntdws12.chass.utoronto.ca>
   7431 	<1250867140-sup-2558@tiger.alporthouse.com>
   7432 Message-ID: <1250867926-sup-4258@javelin>
   7433 
   7434 Excerpts from Chris Wilson's message of Fri Aug 21 11:16:26 -0400 2009:
   7435 > This works very nicely, thanks. Though I miss the subtly of why you
   7436 > use 'A' rather than 'a'. Could you explain the difference this makes?
   7437 > -ickle
   7438 
   7439 A -> mark as read and archive
   7440 a -> just archive
   7441 
   7442 This means you can have unread messages that are archived.  I use this
   7443 to great effect with my mailing list messages (which I have filters
   7444 to archive but not to mark read).
   7445 
   7446 Cheers,
   7447 Edward
   7448 
   7449 From bwalton@artsci.utoronto.ca  Fri Aug 21 11:20:23 2009
   7450 From: bwalton@artsci.utoronto.ca (Ben Walton)
   7451 Date: Fri, 21 Aug 2009 11:20:23 -0400
   7452 Subject: [sup-talk] On making kill-thread easier
   7453 In-Reply-To: <1250867140-sup-2558@tiger.alporthouse.com>
   7454 References: <1250785604-sup-5488@yoom.home.cworth.org>
   7455 	<1250797598-sup-5105@tiger.alporthouse.com>
   7456 	<1250800965-sup-4218@ntdws12.chass.utoronto.ca>
   7457 	<1250867140-sup-2558@tiger.alporthouse.com>
   7458 Message-ID: <1250867933-sup-5786@ntdws12.chass.utoronto.ca>
   7459 
   7460 Excerpts from Chris Wilson's message of Fri Aug 21 11:16:26 -0400 2009:
   7461 
   7462 > This works very nicely, thanks. Though I miss the subtly of why you
   7463 > use 'A' rather than 'a'. Could you explain the difference this makes?
   7464 
   7465 'A' marks the mail as read in addition to archiving it.  This makes
   7466 'U' (unread view) mode better for my use.
   7467 
   7468 -Ben
   7469 
   7470 -- 
   7471 Ben Walton
   7472 Systems Programmer - CHASS
   7473 University of Toronto
   7474 C:416.407.5610 | W:416.978.4302
   7475 
   7476 GPG Key Id: 8E89F6D2; Key Server: pgp.mit.edu
   7477 Contact me to arrange for a CAcert assurance meeting.
   7478 -------------- next part --------------
   7479 A non-text attachment was scrubbed...
   7480 Name: signature.asc
   7481 Type: application/pgp-signature
   7482 Size: 189 bytes
   7483 Desc: not available
   7484 URL: <http://rubyforge.org/pipermail/sup-talk/attachments/20090821/9b947b49/attachment.bin>
   7485 
   7486 From guillaume.quintard@gmail.com  Fri Aug 21 12:00:29 2009
   7487 From: guillaume.quintard@gmail.com (Guillaume Quintard)
   7488 Date: Fri, 21 Aug 2009 18:00:29 +0200
   7489 Subject: [sup-talk] Crashing ssh + sup, bad combo
   7490 Message-ID: <1e5fdab70908210900y5b51722agf33487b3d4dafcf4@mail.gmail.com>
   7491 
   7492 Sooooo, here's what happened: I was running sup through ssh, minding
   7493 my own business, when suddenly, my local machine crashed. I reboot,
   7494 reconnect, sup is somehow still running, I kill it (with a good ol'
   7495 kill, because the lock file was empty so sup could ask for a seppuku),
   7496 and no I have this:
   7497 [Fri Aug 21 17:54:54 +0200 2009] ERROR: oh crap, an exception
   7498 ----------------------------------------------------------------
   7499 I'm very sorry. It seems that an error occurred in Sup. Please
   7500 accept my sincere apologies. If you don't mind, please send the
   7501 contents of ~/.sup/exception-log.txt and a brief report of the
   7502 circumstances to sup-talk at rubyforge dot orgs so that I might
   7503 address this problem. Thank you!
   7504 
   7505 Sincerely,
   7506 William
   7507 ----------------------------------------------------------------
   7508 --- RuntimeError from thread: load threads for thread-index-mode
   7509 wrong id called on nil
   7510 ./lib/sup.rb:17:in `id'
   7511 ./lib/sup/xapian_index.rb:155:in `each_message_in_thread_for'
   7512 /usr/lib/ruby/1.8/monitor.rb:242:in `synchronize'
   7513 ./lib/sup/xapian_index.rb:336:in `synchronize'
   7514 ./lib/sup/xapian_index.rb:155:in `each_message_in_thread_for'
   7515 ./lib/sup/thread.rb:341:in `load_thread_for_message'
   7516 ./lib/sup/thread.rb:333:in `load_n_threads'
   7517 ./lib/sup/xapian_index.rb:149:in `each_id_by_date'
   7518 ./lib/sup/xapian_index.rb:142:in `each_id'
   7519 ./lib/sup/xapian_index.rb:142:in `each'
   7520 ./lib/sup/xapian_index.rb:142:in `each_id'
   7521 ./lib/sup/xapian_index.rb:149:in `each_id_by_date'
   7522 ./lib/sup/thread.rb:328:in `load_n_threads'
   7523 ./lib/sup/modes/thread-index-mode.rb:623:in `__unprotected_load_n_threads'
   7524 (eval):12:in `load_n_threads'
   7525 ./lib/sup/modes/thread-index-mode.rb:607:in `load_n_threads_background'
   7526 ./lib/sup.rb:77:in `reporting_thread'
   7527 ./lib/sup.rb:75:in `initialize'
   7528 ./lib/sup.rb:75:in `new'
   7529 ./lib/sup.rb:75:in `reporting_thread'
   7530 ./lib/sup/modes/thread-index-mode.rb:606:in `load_n_threads_background'
   7531 ./lib/sup/modes/thread-index-mode.rb:676:in `__unprotected_load_threads'
   7532 (eval):12:in `load_threads'
   7533 bin/sup:192
   7534 
   7535 me no likey :-(
   7536 
   7537 -- 
   7538 Guillaume
   7539 
   7540 From marka@pobox.com  Fri Aug 21 14:57:10 2009
   7541 From: marka@pobox.com (Mark Alexander)
   7542 Date: Fri, 21 Aug 2009 14:57:10 -0400
   7543 Subject: [sup-talk] Crashing ssh + sup, bad combo
   7544 In-Reply-To: <1e5fdab70908210900y5b51722agf33487b3d4dafcf4@mail.gmail.com>
   7545 References: <1e5fdab70908210900y5b51722agf33487b3d4dafcf4@mail.gmail.com>
   7546 Message-ID: <a412e2a70908211157vcd73cc6r4b401fd38f50902@mail.gmail.com>
   7547 
   7548 This isn't directly related, and you may already know about this, and
   7549 apologies if that's the case... but I highly recommend running screen
   7550 on the machine where you're running sup.  That way you don't lose any
   7551 work when your ssh connection drops for any reason.
   7552 
   7553 From guillaume.quintard@gmail.com  Fri Aug 21 15:29:22 2009
   7554 From: guillaume.quintard@gmail.com (Guillaume Quintard)
   7555 Date: Fri, 21 Aug 2009 21:29:22 +0200
   7556 Subject: [sup-talk] Crashing ssh + sup, bad combo
   7557 In-Reply-To: <a412e2a70908211157vcd73cc6r4b401fd38f50902@mail.gmail.com>
   7558 References: <1e5fdab70908210900y5b51722agf33487b3d4dafcf4@mail.gmail.com>
   7559 	<a412e2a70908211157vcd73cc6r4b401fd38f50902@mail.gmail.com>
   7560 Message-ID: <1e5fdab70908211229w2f11d11h4db7500a340b923b@mail.gmail.com>
   7561 
   7562 On Fri, Aug 21, 2009 at 8:57 PM, Mark Alexander<marka at pobox.com> wrote:
   7563 > This isn't directly related, and you may already know about this, and
   7564 > apologies if that's the case... but I highly recommend running screen
   7565 > on the machine where you're running sup. ?That way you don't lose any
   7566 > work when your ssh connection drops for any reason.
   7567 >
   7568 
   7569 Yup, I know, but screen isn't yet natural to me, and I tend to forgot
   7570 to use it :-)
   7571 
   7572 
   7573 -- 
   7574 Guillaume
   7575 
   7576 From rlane@club.cc.cmu.edu  Fri Aug 21 16:57:55 2009
   7577 From: rlane@club.cc.cmu.edu (Rich Lane)
   7578 Date: Fri, 21 Aug 2009 16:57:55 -0400
   7579 Subject: [sup-talk] Crashing ssh + sup, bad combo
   7580 In-Reply-To: <1e5fdab70908210900y5b51722agf33487b3d4dafcf4@mail.gmail.com>
   7581 References: <1e5fdab70908210900y5b51722agf33487b3d4dafcf4@mail.gmail.com>
   7582 Message-ID: <1250887753-sup-7844@zyrg.net>
   7583 
   7584 Excerpts from Guillaume Quintard's message of Fri Aug 21 12:00:29 -0400 2009:
   7585 > Sooooo, here's what happened: I was running sup through ssh, minding
   7586 > my own business, when suddenly, my local machine crashed. I reboot,
   7587 > reconnect, sup is somehow still running, I kill it (with a good ol'
   7588 > kill, because the lock file was empty so sup could ask for a seppuku),
   7589 > and no I have this:
   7590 
   7591 I'm guessing this is an inconsistency between your xapian and entries.db
   7592 databases. A sup-sync -a might fix it.
   7593 
   7594 I posted a patch a few days ago that moves all index data into Xapian to
   7595 prevent this sort of issue. William, could you take a look at / merge that
   7596 patch?
   7597 
   7598 From lcontzen@gmail.com  Sat Aug 22 05:45:18 2009
   7599 From: lcontzen@gmail.com (Contzen Laurent)
   7600 Date: Sat, 22 Aug 2009 11:45:18 +0200
   7601 Subject: [sup-talk] Sup crashed at launch
   7602 Message-ID: <49454bf60908220245w52764765rdbd111dfd446896f@mail.gmail.com>
   7603 
   7604 Hello,
   7605 
   7606 I've heard about sup and it sounded great so I decided to give it a
   7607 try following http://www.brainyautomation.com/blog/post/Reading-Gmail-with-Sup.aspx
   7608 .
   7609 
   7610 I installed everything, configured ssmtp and got it working, etc. I
   7611 then launched sup for a first time to let it create my ~/.sup and exit
   7612 whithout any troubles. I then configured my .sup/sources.yaml as shown
   7613 in the webpage mentionned above and then launched sup. It crashed with
   7614 that output :
   7615 
   7616 [Sat Aug 22 11:41:56 +0200 2009] using character set encoding "utf8"
   7617 [Sat Aug 22 11:41:56 +0200 2009] dynamically loading setlocale() from libc.so.6
   7618 [Sat Aug 22 11:41:56 +0200 2009] setting locale...
   7619 [Sat Aug 22 11:41:56 +0200 2009] locking /home/laurent/.sup/lock...
   7620 [Sat Aug 22 11:41:56 +0200 2009] crypto: detected gpg binary in /usr/bin/gpg
   7621 [Sat Aug 22 11:41:56 +0200 2009] stopped cursing
   7622 [Sat Aug 22 11:41:56 +0200 2009] oh crap, an exception
   7623 [Sat Aug 22 11:41:56 +0200 2009] unlocking /home/laurent/.sup/lock...
   7624 ----------------------------------------------------------------
   7625 I'm very sorry. It seems that an error occurred in Sup. Please
   7626 accept my sincere apologies. If you don't mind, please send the
   7627 contents of ~/.sup/exception-log.txt and a brief report of the
   7628 circumstances to sup-talk at rubyforge dot orgs so that I might
   7629 address this problem. Thank you!
   7630 
   7631 Sincerely,
   7632 William
   7633 ----------------------------------------------------------------
   7634 --- ArgumentError from thread: main
   7635 username and password must be specified
   7636 /usr/lib/ruby/gems/1.8/gems/sup-0.8.1/lib/sup/imap.rb:60:in `initialize'
   7637 /usr/lib/ruby/gems/1.8/gems/sup-0.8.1/lib/sup.rb:30:in `new'
   7638 /usr/lib/ruby/gems/1.8/gems/sup-0.8.1/lib/sup.rb:30:in `yaml_properties'
   7639 /usr/lib/ruby/1.8/yaml.rb:133:in `call'
   7640 /usr/lib/ruby/1.8/yaml.rb:133:in `transfer'
   7641 /usr/lib/ruby/1.8/yaml.rb:133:in `node_import'
   7642 /usr/lib/ruby/1.8/yaml.rb:133:in `load'
   7643 /usr/lib/ruby/1.8/yaml.rb:133:in `load'
   7644 /usr/lib/ruby/1.8/yaml.rb:144:in `load_file'
   7645 /usr/lib/ruby/1.8/yaml.rb:143:in `open'
   7646 /usr/lib/ruby/1.8/yaml.rb:143:in `load_file'
   7647 /usr/lib/ruby/gems/1.8/gems/sup-0.8.1/lib/sup.rb:98:in `load_yaml_obj'
   7648 /usr/lib/ruby/gems/1.8/gems/sup-0.8.1/lib/sup/index.rb:473:in `load_sources'
   7649 /usr/lib/ruby/gems/1.8/gems/sup-0.8.1/lib/sup/index.rb:121:in `load'
   7650 /usr/lib/ruby/gems/1.8/gems/sup-0.8.1/lib/sup/util.rb:513:in `send'
   7651 /usr/lib/ruby/gems/1.8/gems/sup-0.8.1/lib/sup/util.rb:513:in `method_missing'
   7652 /usr/lib/ruby/gems/1.8/gems/sup-0.8.1/bin/sup:162
   7653 /usr/bin/sup:19:in `load'
   7654 /usr/bin/sup:19
   7655 
   7656 
   7657 The ouput asked to send this mail so I decided to try to help you by doing it.
   7658 
   7659 Don't hesitate to ask for details, ...
   7660 
   7661 Laurent
   7662 
   7663 From ulrik.sverdrup@gmail.com  Fri Aug 21 19:04:15 2009
   7664 From: ulrik.sverdrup@gmail.com (Ulrik Sverdrup)
   7665 Date: Sat, 22 Aug 2009 01:04:15 +0200
   7666 Subject: [sup-talk] Bug: Log printing with encoding problems
   7667 Message-ID: <a1b6cb1b0908211604p4c0e94bk87134933f45e6f73@mail.gmail.com>
   7668 
   7669 My locale is sv_SE.UTF-8, log is truncated since the date string is
   7670 longer than expected.
   7671 
   7672 The date should print "l?r" (from L?rdag = Saturday)
   7673 
   7674 Sat Aug 22 00:55:52 +0200 2009: using character set encoding "UTF-8"
   7675 Sat Aug 22 00:55:52 +0200 2009: dynamically loading setlocale() from libc.so.6
   7676 Sat Aug 22 00:55:52 +0200 2009: setting locale...
   7677 lM-CM-6r aug 22 00:55:52 +0200 2009: locking /home/ulrik/.sup/lo
   7678 lM-CM-6r aug 22 00:55:52 +0200 2009: crypto: detected gpg binary in /usr/bi
   7679 lM-CM-6r aug 22 00:55:52 +0200 2009: loading ind
   7680 lM-CM-6r aug 22 00:55:52 +0200 2009: loaded index of 0 mes
   7681 lM-CM-6r aug 22 00:55:52 +0200 2009: starting c
   7682 
   7683 
   7684 Regards,
   7685 ulrik
   7686 
   7687 From ulrik.sverdrup@gmail.com  Fri Aug 21 19:08:30 2009
   7688 From: ulrik.sverdrup@gmail.com (Ulrik Sverdrup)
   7689 Date: Sat, 22 Aug 2009 01:08:30 +0200
   7690 Subject: [sup-talk] Bug: Quits on unbound(?) keys
   7691 Message-ID: <a1b6cb1b0908211608u40e3ab67h9ff7373a4a686062@mail.gmail.com>
   7692 
   7693 Sup seems to crash if you press a key not bound(?)
   7694 
   7695 Sup version: 0.8.1 (debian unstable)
   7696 
   7697 start sup-mail.
   7698 press 'c'
   7699 
   7700 sup will crash with following message:
   7701 uby: symbol lookup error:
   7702 /usr/lib/ruby/1.8/powerpc-linux/ncurses_bin.so: undefined symbol:
   7703 funcall
   7704 
   7705 
   7706 Regards,
   7707 ulrik
   7708 
   7709 From wmorgan-sup@masanjin.net  Sat Aug 22 09:46:27 2009
   7710 From: wmorgan-sup@masanjin.net (William Morgan)
   7711 Date: Sat, 22 Aug 2009 06:46:27 -0700
   7712 Subject: [sup-talk] [PATCH] index log
   7713 In-Reply-To: <1250491123-19240-1-git-send-email-rlane@club.cc.cmu.edu>
   7714 References: <1250491123-19240-1-git-send-email-rlane@club.cc.cmu.edu>
   7715 Message-ID: <1250948551-sup-2052@masanjin.net>
   7716 
   7717 Reformatted excerpts from Rich Lane's message of 2009-08-16:
   7718 > Add a YAML logfile that records changes to the index and modify
   7719 > sup-dump to use this rather than the normal database.
   7720 
   7721 I like this. I'm going to wait to apply it until the api refactoring
   7722 stuff is merged down to master though. Should be soon.
   7723 -- 
   7724 William <wmorgan-sup at masanjin.net>
   7725 
   7726 From wmorgan-sup@masanjin.net  Sat Aug 22 10:10:04 2009
   7727 From: wmorgan-sup@masanjin.net (William Morgan)
   7728 Date: Sat, 22 Aug 2009 07:10:04 -0700
   7729 Subject: [sup-talk] [PATCH] cache results of Person.from_address
   7730 In-Reply-To: <1250491172-19317-1-git-send-email-rlane@club.cc.cmu.edu>
   7731 References: <1250491172-19317-1-git-send-email-rlane@club.cc.cmu.edu>
   7732 Message-ID: <1250949615-sup-1773@masanjin.net>
   7733 
   7734 This looks good. Two minor questions before I apply:
   7735 
   7736 Reformatted excerpts from Rich Lane's message of 2009-08-16:
   7737 > The regexes in this function are very expensive, so caching improves
   7738 > performance significantly for queries and slightly for indexing.
   7739 
   7740 When you say this affects query performance, is it just the contact-list
   7741 query, or is there some other mechanism by which this is slowing down
   7742 regular queries?
   7743 
   7744 Also in this method:
   7745 
   7746 > +  def []=(k,v)
   7747 > +    if @values.size < @n
   7748 > +      @values[k] = v
   7749 > +      @marks[k] = @i
   7750 > +    else
   7751 > +      if @delete_stack.empty?
   7752 > +        sweep
   7753 > +      else
   7754 > +        k2 = @delete_stack.pop
   7755 > +        @values.delete k2
   7756 > +        @marks.delete k2
   7757 > +        self[k] = v
   7758 > +      end
   7759 > +    end
   7760 > +  end
   7761 
   7762 Wouldn't it be better to do this?
   7763 
   7764        else
   7765          if @delete_stack.empty?
   7766            sweep
   7767          end
   7768 
   7769          unless @delete_stack.empty?
   7770            k2 = @delete_stack.pop
   7771            @values.delete k2
   7772            @marks.delete k2
   7773            self[k] = v
   7774          end
   7775 
   7776 So we check the delete stack even after calling sweep, and we allow for
   7777 the value to be nil.
   7778 
   7779 Thanks!
   7780 -- 
   7781 William <wmorgan-sup at masanjin.net>
   7782 
   7783 From wmorgan-sup@masanjin.net  Sat Aug 22 10:10:20 2009
   7784 From: wmorgan-sup@masanjin.net (William Morgan)
   7785 Date: Sat, 22 Aug 2009 07:10:20 -0700
   7786 Subject: [sup-talk] [PATCH] cache results of Person.from_address
   7787 In-Reply-To: <1250514421-sup-7564@Longbow>
   7788 References: <1250491172-19317-1-git-send-email-rlane@club.cc.cmu.edu>
   7789 	<1250514421-sup-7564@Longbow>
   7790 Message-ID: <1250950211-sup-1042@masanjin.net>
   7791 
   7792 Reformatted excerpts from Andrei Thorp's message of 2009-08-17:
   7793 > Just want to say thanks again for your seemingly unending amount of
   7794 > good work to improve Sup.
   7795 
   7796 Agreed!
   7797 -- 
   7798 William <wmorgan-sup at masanjin.net>
   7799 
   7800 From wmorgan-sup@masanjin.net  Sat Aug 22 10:35:37 2009
   7801 From: wmorgan-sup@masanjin.net (William Morgan)
   7802 Date: Sat, 22 Aug 2009 07:35:37 -0700
   7803 Subject: [sup-talk] [PATCH 2/2] xapian index format versioning
   7804 In-Reply-To: <1250453934-sup-9651@zyrg.net>
   7805 References: <1250451331-16070-1-git-send-email-rlane@club.cc.cmu.edu>
   7806 	<1250451331-16070-2-git-send-email-rlane@club.cc.cmu.edu>
   7807 	<20090816200116.GA17272@chistera.yi.org>
   7808 	<1250453934-sup-9651@zyrg.net>
   7809 Message-ID: <1250951723-sup-3859@masanjin.net>
   7810 
   7811 Branch xapian-updates, merged into next. Thanks!
   7812 -- 
   7813 William <wmorgan-sup at masanjin.net>
   7814 
   7815 From wmorgan-sup@masanjin.net  Sat Aug 22 10:50:58 2009
   7816 From: wmorgan-sup@masanjin.net (William Morgan)
   7817 Date: Sat, 22 Aug 2009 07:50:58 -0700
   7818 Subject: [sup-talk] [PATCH] Fix a thread merging bug introduced by
   7819 	refactoring in 59f8fc2
   7820 In-Reply-To: <1250620200-24319-1-git-send-email-alex@chmrr.net>
   7821 References: <1250620200-24319-1-git-send-email-alex@chmrr.net>
   7822 Message-ID: <1250952651-sup-2682@masanjin.net>
   7823 
   7824 Applied to master. Thanks!
   7825 -- 
   7826 William <wmorgan-sup at masanjin.net>
   7827 
   7828 From wmorgan-sup@masanjin.net  Sat Aug 22 11:01:30 2009
   7829 From: wmorgan-sup@masanjin.net (William Morgan)
   7830 Date: Sat, 22 Aug 2009 08:01:30 -0700
   7831 Subject: [sup-talk] [PATCH] fix garbaged text in textfield when using
   7832 	ncursesw
   7833 In-Reply-To: <1250715278-sup-1941@localdomain>
   7834 References: <1250715278-sup-1941@localdomain>
   7835 Message-ID: <1250952979-sup-9364@masanjin.net>
   7836 
   7837 Reformatted excerpts from Beno?t PIERRE's message of 2009-08-19:
   7838 > Apparently, field_buffer content is not initialized to blanks when
   7839 > using the wide-character version of ncurses. Forcing a call to
   7840 > set_field_buffer fix the problem.
   7841 
   7842 Awesome. Applied to master. I hope this clears up the problems that
   7843 people have been having with newer ncurses ruby libraries and utf8. If
   7844 you've been seeing garbage characters when searching, please let us know
   7845 if this fixes it.
   7846 -- 
   7847 William <wmorgan-sup at masanjin.net>
   7848 
   7849 From carlos_franke@gmx.de  Sat Aug 22 10:49:17 2009
   7850 From: carlos_franke@gmx.de (Carlos Franke)
   7851 Date: Sat, 22 Aug 2009 16:49:17 +0200
   7852 Subject: [sup-talk] sup crash
   7853 Message-ID: <20090822164917.0a84a749@gmx.de>
   7854 
   7855 Hi!
   7856 
   7857 sup 0.8.1 crashed being started after sup-config and sup-sync. Mail
   7858 source: Local IMAP server (Courier) that works with other clients.
   7859 sup's output asked me to send you the appended file. Have fun with it!
   7860 
   7861 Carlos
   7862 -------------- next part --------------
   7863 An embedded and charset-unspecified text was scrubbed...
   7864 Name: exception-log.txt
   7865 URL: <http://rubyforge.org/pipermail/sup-talk/attachments/20090822/fc801d3c/attachment.txt>
   7866 -------------- next part --------------
   7867 A non-text attachment was scrubbed...
   7868 Name: signature.asc
   7869 Type: application/pgp-signature
   7870 Size: 197 bytes
   7871 Desc: not available
   7872 URL: <http://rubyforge.org/pipermail/sup-talk/attachments/20090822/fc801d3c/attachment.bin>
   7873 
   7874 From wmorgan-sup@masanjin.net  Sat Aug 22 12:26:36 2009
   7875 From: wmorgan-sup@masanjin.net (William Morgan)
   7876 Date: Sat, 22 Aug 2009 09:26:36 -0700
   7877 Subject: [sup-talk] Sup crashed at launch
   7878 In-Reply-To: <49454bf60908220245w52764765rdbd111dfd446896f@mail.gmail.com>
   7879 References: <49454bf60908220245w52764765rdbd111dfd446896f@mail.gmail.com>
   7880 Message-ID: <1250958276-sup-9140@masanjin.net>
   7881 
   7882 Reformatted excerpts from Contzen Laurent's message of 2009-08-22:
   7883 > username and password must be specified
   7884 
   7885 Sounds like your sources.yaml file doesn't have a username and password
   7886 for that entry, or isn't have the correct format. You may want to delete
   7887 it and run sup-add (or sup-config) instead to generate it automatically.
   7888 -- 
   7889 William <wmorgan-sup at masanjin.net>
   7890 
   7891 From wmorgan-sup@masanjin.net  Sat Aug 22 12:31:47 2009
   7892 From: wmorgan-sup@masanjin.net (William Morgan)
   7893 Date: Sat, 22 Aug 2009 09:31:47 -0700
   7894 Subject: [sup-talk] sup crash
   7895 In-Reply-To: <20090822164917.0a84a749@gmx.de>
   7896 References: <20090822164917.0a84a749@gmx.de>
   7897 Message-ID: <1250958467-sup-381@masanjin.net>
   7898 
   7899 Reformatted excerpts from Carlos Franke's message of 2009-08-22:
   7900 > invalid source 1
   7901 
   7902 Sup is saying it has messages in its index that claim they're from
   7903 source 1, but your sources.yaml doesn't have such a source. Did you
   7904 remove something from sources.yaml?
   7905 
   7906 The easiest way to fix this is to delete your ~/.sup/ferret/ directory
   7907 and run sup-sync --all --all-sources to rebuild the index, but you'll
   7908 lose all messages state. If that's not acceptable, you can re-add source
   7909 1, or you can delete all such messages from the index with some effort
   7910 and devel/console.sh.
   7911 -- 
   7912 William <wmorgan-sup at masanjin.net>
   7913 
   7914 From wmorgan-sup@masanjin.net  Sat Aug 22 12:34:40 2009
   7915 From: wmorgan-sup@masanjin.net (William Morgan)
   7916 Date: Sat, 22 Aug 2009 09:34:40 -0700
   7917 Subject: [sup-talk] Sup crashed at launch
   7918 In-Reply-To: <1250958276-sup-9140@masanjin.net>
   7919 References: <49454bf60908220245w52764765rdbd111dfd446896f@mail.gmail.com>
   7920 	<1250958276-sup-9140@masanjin.net>
   7921 Message-ID: <1250958837-sup-947@masanjin.net>
   7922 
   7923 Reformatted excerpts from William Morgan's message of 2009-08-22:
   7924 > Sounds like your sources.yaml file doesn't have a username and password
   7925 > for that entry, or isn't have the correct format.
   7926 
   7927 In particular, that webpage doesn't preserve spacing for its example
   7928 sources.yaml, and yaml is space-sensitive.
   7929 -- 
   7930 William <wmorgan-sup at masanjin.net>
   7931 
   7932 From wmorgan-sup@masanjin.net  Sat Aug 22 14:15:15 2009
   7933 From: wmorgan-sup@masanjin.net (William Morgan)
   7934 Date: Sat, 22 Aug 2009 11:15:15 -0700
   7935 Subject: [sup-talk] [PATCH] mime-decode hook: provide a "charset"
   7936 	variable with the attachment charset
   7937 In-Reply-To: <20090819212209.GA10883@chistera.yi.org>
   7938 References: <6fc2e5dd8aa2b0b8547375d77b1776d779f85817.1247238014.git.dato@net.com.org.es>
   7939 	<20090723093543.GA2265@chistera.yi.org> <1248713434-sup-4961@entry>
   7940 	<20090730155656.GA20442@chistera.yi.org>
   7941 	<20090819212209.GA10883@chistera.yi.org>
   7942 Message-ID: <1250964880-sup-7106@masanjin.net>
   7943 
   7944 Reformatted excerpts from Adeodato Sim?'s message of 2009-08-19:
   7945 > Ping?
   7946 
   7947 Sorry, working on a fix for the hook variables issue. Bug me again in a
   7948 few days if I haven't gotten to this.
   7949 -- 
   7950 William <wmorgan-sup at masanjin.net>
   7951 
   7952 From rlane@club.cc.cmu.edu  Sat Aug 22 14:28:15 2009
   7953 From: rlane@club.cc.cmu.edu (Rich Lane)
   7954 Date: Sat, 22 Aug 2009 11:28:15 -0700
   7955 Subject: [sup-talk] [PATCH] add Message#load_from_index! shortcut
   7956 Message-ID: <1250965695-31073-1-git-send-email-rlane@club.cc.cmu.edu>
   7957 
   7958 Message#parse_header is slow, taking up to 2/3 of the time spent loading
   7959 threads in thread-index-mode. This patch adds a shortcut method that the index
   7960 can use to efficiently initialize a message.
   7961 ---
   7962  lib/sup/message.rb      |   25 +++++++++++++++++++++++++
   7963  lib/sup/xapian_index.rb |   30 +++++++++++-------------------
   7964  2 files changed, 36 insertions(+), 19 deletions(-)
   7965 
   7966 diff --git a/lib/sup/message.rb b/lib/sup/message.rb
   7967 index 965c10e..56e66de 100644
   7968 --- a/lib/sup/message.rb
   7969 +++ b/lib/sup/message.rb
   7970 @@ -127,6 +127,31 @@ class Message
   7971      @list_unsubscribe = header["list-unsubscribe"]
   7972    end
   7973  
   7974 +  ## Expected index entry format:
   7975 +  ## :message_id, :subject => String
   7976 +  ## :date => Time
   7977 +  ## :refs, :replytos => Array of String
   7978 +  ## :from => Person
   7979 +  ## :to, :cc, :bcc => Array of Person
   7980 +  def load_from_index! entry
   7981 +    @id = entry[:message_id]
   7982 +    @from = entry[:from]
   7983 +    @date = entry[:date]
   7984 +    @subj = entry[:subject]
   7985 +    @to = entry[:to]
   7986 +    @cc = entry[:cc]
   7987 +    @bcc = entry[:bcc]
   7988 +    @refs = (@refs + entry[:refs]).uniq
   7989 +    @replytos = entry[:replytos]
   7990 +
   7991 +    @replyto = nil
   7992 +    @list_address = nil
   7993 +    @recipient_email = nil
   7994 +    @source_marked_read = false
   7995 +    @list_subscribe = nil
   7996 +    @list_unsubscribe = nil
   7997 +  end
   7998 +
   7999    def add_ref ref
   8000      @refs << ref
   8001      @dirty = true
   8002 diff --git a/lib/sup/xapian_index.rb b/lib/sup/xapian_index.rb
   8003 index 85f6ef0..c260728 100644
   8004 --- a/lib/sup/xapian_index.rb
   8005 +++ b/lib/sup/xapian_index.rb
   8006 @@ -71,25 +71,17 @@ class XapianIndex < BaseIndex
   8007      source = SourceManager[entry[:source_id]]
   8008      raise "invalid source #{entry[:source_id]}" unless source
   8009  
   8010 -    mk_addrs = lambda { |l| l.map { |e,n| "#{n} <#{e}>" } * ', ' }
   8011 -    mk_refs = lambda { |l| l.map { |r| "<#{r}>" } * ' ' }
   8012 -    fake_header = {
   8013 -      'message-id' => entry[:message_id],
   8014 -      'date' => Time.at(entry[:date]),
   8015 -      'subject' => entry[:subject],
   8016 -      'from' => mk_addrs[[entry[:from]]],
   8017 -      'to' => mk_addrs[entry[:to]],
   8018 -      'cc' => mk_addrs[entry[:cc]],
   8019 -      'bcc' => mk_addrs[entry[:bcc]],
   8020 -      'reply-tos' => mk_refs[entry[:replytos]],
   8021 -      'references' => mk_refs[entry[:refs]],
   8022 -     }
   8023 -
   8024 -      m = Message.new :source => source, :source_info => entry[:source_info],
   8025 -                  :labels => entry[:labels],
   8026 -                  :snippet => entry[:snippet]
   8027 -      m.parse_header fake_header
   8028 -      m
   8029 +    m = Message.new :source => source, :source_info => entry[:source_info],
   8030 +                    :labels => entry[:labels], :snippet => entry[:snippet]
   8031 +
   8032 +    mk_person = lambda { |x| Person.new(*x.reverse!) }
   8033 +    entry[:from] = mk_person[entry[:from]]
   8034 +    entry[:to].map!(&mk_person)
   8035 +    entry[:cc].map!(&mk_person)
   8036 +    entry[:bcc].map!(&mk_person)
   8037 +
   8038 +    m.load_from_index! entry
   8039 +    m
   8040    end
   8041  
   8042    def add_message m; sync_message m end
   8043 -- 
   8044 1.6.4
   8045 
   8046 
   8047 From rlane@club.cc.cmu.edu  Sat Aug 22 14:28:39 2009
   8048 From: rlane@club.cc.cmu.edu (Rich Lane)
   8049 Date: Sat, 22 Aug 2009 14:28:39 -0400
   8050 Subject: [sup-talk] [PATCH] cache results of Person.from_address
   8051 In-Reply-To: <1250949615-sup-1773@masanjin.net>
   8052 References: <1250491172-19317-1-git-send-email-rlane@club.cc.cmu.edu>
   8053 	<1250949615-sup-1773@masanjin.net>
   8054 Message-ID: <1250964897-sup-2990@zyrg.net>
   8055 
   8056 Excerpts from William Morgan's message of Sat Aug 22 10:10:04 -0400 2009:
   8057 > This looks good. Two minor questions before I apply:
   8058 > 
   8059 > Reformatted excerpts from Rich Lane's message of 2009-08-16:
   8060 > > The regexes in this function are very expensive, so caching improves
   8061 > > performance significantly for queries and slightly for indexing.
   8062 > 
   8063 > When you say this affects query performance, is it just the contact-list
   8064 > query, or is there some other mechanism by which this is slowing down
   8065 > regular queries?
   8066 
   8067 Actually, your question prompted me to wonder why we're calling
   8068 Person.from_address on this path at all. With a little support from
   8069 Message we can completely avoid Message#parse_header. I've just sent in
   8070 a patch that does this. Please apply that rather than the from_address
   8071 cache.
   8072 
   8073 The performance improvement from the new patch is slightly better than
   8074 that of the cache. Depending on the benchmark I see the time taken by
   8075 ThreadIndexMode#load_n_threads decrease by 1/2 to 2/3.
   8076 
   8077 From rlane@club.cc.cmu.edu  Sat Aug 22 14:54:23 2009
   8078 From: rlane@club.cc.cmu.edu (Rich Lane)
   8079 Date: Sat, 22 Aug 2009 11:54:23 -0700
   8080 Subject: [sup-talk] [PATCH] add xapian-specific hack to quickly create a
   8081 	Person
   8082 In-Reply-To: <1250965695-31073-1-git-send-email-rlane@club.cc.cmu.edu>
   8083 References: <1250965695-31073-1-git-send-email-rlane@club.cc.cmu.edu>
   8084 Message-ID: <1250967263-31292-1-git-send-email-rlane@club.cc.cmu.edu>
   8085 
   8086 Another 10% query performance boost.
   8087 ---
   8088  lib/sup/xapian_index.rb |   10 +++++++++-
   8089  1 files changed, 9 insertions(+), 1 deletions(-)
   8090 
   8091 diff --git a/lib/sup/xapian_index.rb b/lib/sup/xapian_index.rb
   8092 index c260728..3a23951 100644
   8093 --- a/lib/sup/xapian_index.rb
   8094 +++ b/lib/sup/xapian_index.rb
   8095 @@ -74,7 +74,7 @@ class XapianIndex < BaseIndex
   8096      m = Message.new :source => source, :source_info => entry[:source_info],
   8097                      :labels => entry[:labels], :snippet => entry[:snippet]
   8098  
   8099 -    mk_person = lambda { |x| Person.new(*x.reverse!) }
   8100 +    mk_person = lambda { |x| QuickPerson.new(*x) }
   8101      entry[:from] = mk_person[entry[:from]]
   8102      entry[:to].map!(&mk_person)
   8103      entry[:cc].map!(&mk_person)
   8104 @@ -84,6 +84,14 @@ class XapianIndex < BaseIndex
   8105      m
   8106    end
   8107  
   8108 +  class QuickPerson < Person
   8109 +    def initialize email, name
   8110 +      raise ArgumentError, "email can't be nil" unless email
   8111 +      @email = email
   8112 +      @name = name
   8113 +    end
   8114 +  end
   8115 +
   8116    def add_message m; sync_message m end
   8117    def update_message m; sync_message m end
   8118    def update_message_state m; sync_message m end
   8119 -- 
   8120 1.6.4
   8121 
   8122 
   8123 From ingmar@exherbo.org  Sat Aug 22 15:12:30 2009
   8124 From: ingmar@exherbo.org (Ingmar Vanhassel)
   8125 Date: Sat, 22 Aug 2009 21:12:30 +0200
   8126 Subject: [sup-talk] Bug: Quits on unbound(?) keys
   8127 In-Reply-To: <a1b6cb1b0908211608u40e3ab67h9ff7373a4a686062@mail.gmail.com>
   8128 References: <a1b6cb1b0908211608u40e3ab67h9ff7373a4a686062@mail.gmail.com>
   8129 Message-ID: <1250968143-sup-3847@cannonball>
   8130 
   8131 Excerpts from Ulrik Sverdrup's message of Sat Aug 22 01:08:30 +0200 2009:
   8132 > sup will crash with following message:
   8133 > ruby: symbol lookup error:
   8134 > /usr/lib/ruby/1.8/powerpc-linux/ncurses_bin.so: undefined symbol:
   8135 > funcall
   8136 
   8137 I bet you're using ncurses-ruby-1.2.2? What you're seeing is an
   8138 ncurses-ruby bug:
   8139 http://bugs.debian.org/cgi-bin/bugreport.cgi?bug=532431
   8140 Update to 1.2.3 or 1.2.4 & you'll be find. If that's not an option,
   8141 downgrade to a 1.1 release.
   8142 
   8143 -- 
   8144 Exherbo KDE, X.org maintainer
   8145 
   8146 From dato@net.com.org.es  Sat Aug 22 15:16:17 2009
   8147 From: dato@net.com.org.es (Adeodato =?utf-8?B?U2ltw7M=?=)
   8148 Date: Sat, 22 Aug 2009 20:16:17 +0100
   8149 Subject: [sup-talk] [PATCH] mime-decode hook: provide a "charset"
   8150  variable with the attachment charset
   8151 In-Reply-To: <1250964880-sup-7106@masanjin.net>
   8152 References: <6fc2e5dd8aa2b0b8547375d77b1776d779f85817.1247238014.git.dato@net.com.org.es>
   8153 	<20090723093543.GA2265@chistera.yi.org> <1248713434-sup-4961@entry>
   8154 	<20090730155656.GA20442@chistera.yi.org>
   8155 	<20090819212209.GA10883@chistera.yi.org>
   8156 	<1250964880-sup-7106@masanjin.net>
   8157 Message-ID: <20090822191617.GA26897@chistera.yi.org>
   8158 
   8159 + William Morgan (Sat, 22 Aug 2009 11:15:15 -0700):
   8160 
   8161 > Reformatted excerpts from Adeodato Sim?'s message of 2009-08-19:
   8162 > > Ping?
   8163 
   8164 > Sorry, working on a fix for the hook variables issue. Bug me again in a
   8165 > few days if I haven't gotten to this.
   8166 
   8167 Only in case it needs saying: you mean a fix other than the patch I sent
   8168 for that as well? (Perhaps my proposed fix was not completed, I just
   8169 want to make sure the patch got noticed.)
   8170 
   8171 Thanks,
   8172 
   8173 -- 
   8174 - Are you sure we're good?
   8175 - Always.
   8176         -- Rory and Lorelai
   8177 
   8178 
   8179 From wmorgan-sup@masanjin.net  Sat Aug 22 16:23:17 2009
   8180 From: wmorgan-sup@masanjin.net (William Morgan)
   8181 Date: Sat, 22 Aug 2009 13:23:17 -0700
   8182 Subject: [sup-talk] Exception trying to run git source
   8183 In-Reply-To: <1250717434-sup-4489@yoom.home.cworth.org>
   8184 References: <1250642676-sup-2244@yoom> <1250698636-sup-6732@masanjin.net>
   8185 	<1250699596-sup-8133@ntdws12.chass.utoronto.ca>
   8186 	<1250704257-sup-3308@yoom> <1250707794-sup-6173@masanjin.net>
   8187 	<1250710221-sup-925@yoom.home.cworth.org>
   8188 	<1250712045-sup-3506@masanjin.net>
   8189 	<1250717434-sup-4489@yoom.home.cworth.org>
   8190 Message-ID: <1250964942-sup-8625@masanjin.net>
   8191 
   8192 Reformatted excerpts from Carl Worth's message of 2009-08-19:
   8193 > I ran an strace on the ruby process[*] and was able to plainly see
   8194 > that modules were being correctly loaded from ./lib until after
   8195 > /usr/lib/ruby/1.8/chronic.rb was loaded. After that, ruby would look
   8196 > for modules in /usr/lib/ruby/1.8 before ./lib. And sure enough, the
   8197 > first line of my chronic.rb has:
   8198 > 
   8199 > $:.unshift File.dirname(__FILE__)     # For use/testing when no gem is installed
   8200 
   8201 I'd call that a bug in chronic. It shouldn't be screwing with the load
   8202 path. Nice debug work.
   8203 -- 
   8204 William <wmorgan-sup at masanjin.net>
   8205 
   8206 From wmorgan-sup@masanjin.net  Sat Aug 22 16:25:22 2009
   8207 From: wmorgan-sup@masanjin.net (William Morgan)
   8208 Date: Sat, 22 Aug 2009 13:25:22 -0700
   8209 Subject: [sup-talk] [PATCH] Make SUP_LOG_LEVEL self-documenting.
   8210 In-Reply-To: <1250745799-sup-6607@yoom.home.cworth.org>
   8211 References: <1250745799-sup-6607@yoom.home.cworth.org>
   8212 Message-ID: <1250972634-sup-6871@masanjin.net>
   8213 
   8214 Reformatted excerpts from Carl Worth's message of 2009-08-19:
   8215 > I'm probably still off as far as standard ruby idioms, (and I'm
   8216 > probably committing some sup layer violations as well).
   8217 
   8218 It all looks good except you can use Logger::LEVELS to access the
   8219 constants. Then there's no need to write a LEVELS method. If you fix
   8220 that I will apply. Thanks!
   8221 -- 
   8222 William <wmorgan-sup at masanjin.net>
   8223 
   8224 From chris@chris-wilson.co.uk  Sun Aug 23 08:44:29 2009
   8225 From: chris@chris-wilson.co.uk (Chris Wilson)
   8226 Date: Sun, 23 Aug 2009 13:44:29 +0100
   8227 Subject: [sup-talk] How to edit attachments in reply?
   8228 Message-ID: <1251031062-sup-4617@tiger.alporthouse.com>
   8229 
   8230 Just a simple plea to make my life easier... Given an email with a
   8231 couple of attached patches, what is the easiest way to reply including
   8232 inline comments on the attached patches? At the moment I'm saving the
   8233 attachments to /tmp and then manually including them whilst replying.
   8234 Can anyone give me any clues on how to automatically include the
   8235 attachments in a reply?
   8236 
   8237 Thanks.
   8238 -Chris
   8239 
   8240 From wmorgan-sup@masanjin.net  Sun Aug 23 13:34:10 2009
   8241 From: wmorgan-sup@masanjin.net (William Morgan)
   8242 Date: Sun, 23 Aug 2009 10:34:10 -0700
   8243 Subject: [sup-talk] [PATCH] mime-decode hook: provide a "charset"
   8244 	variable with the attachment charset
   8245 In-Reply-To: <20090822191617.GA26897@chistera.yi.org>
   8246 References: <6fc2e5dd8aa2b0b8547375d77b1776d779f85817.1247238014.git.dato@net.com.org.es>
   8247 	<20090723093543.GA2265@chistera.yi.org> <1248713434-sup-4961@entry>
   8248 	<20090730155656.GA20442@chistera.yi.org>
   8249 	<20090819212209.GA10883@chistera.yi.org>
   8250 	<1250964880-sup-7106@masanjin.net>
   8251 	<20090822191617.GA26897@chistera.yi.org>
   8252 Message-ID: <1251048347-sup-5075@masanjin.net>
   8253 
   8254 Reformatted excerpts from Adeodato Sim?'s message of 2009-08-22:
   8255 > Only in case it needs saying: you mean a fix other than the patch I
   8256 > sent for that as well? (Perhaps my proposed fix was not completed, I
   8257 > just want to make sure the patch got noticed.)
   8258 
   8259 Hm, I don't remember seeing it and can't find it now. Can you resend,
   8260 please?
   8261 
   8262 I do see a previous patch that did miss from you, about a crypto+mime
   8263 fix. Is that still something that should be applied? It looks good to
   8264 me.
   8265 
   8266 Anyways, I just merged my hook changes into next, on the branch
   8267 hook-local-vars. Take a look and tell me what you think. This should
   8268 also fix Edward Z. Yang's problems with hook locals not being useable in
   8269 statements like "x = x.foo()".
   8270 -- 
   8271 William <wmorgan-sup at masanjin.net>
   8272 
   8273 From wmorgan-sup@masanjin.net  Sun Aug 23 13:55:59 2009
   8274 From: wmorgan-sup@masanjin.net (William Morgan)
   8275 Date: Sun, 23 Aug 2009 10:55:59 -0700
   8276 Subject: [sup-talk] [PATCH] Be less overzealous in moving text to the
   8277 	left column
   8278 In-Reply-To: <1250749447-sup-1744@yoom.home.cworth.org>
   8279 References: <1250749447-sup-1744@yoom.home.cworth.org>
   8280 Message-ID: <1251050007-sup-9740@masanjin.net>
   8281 
   8282 Reformatted excerpts from Carl Worth's message of 2009-08-19:
   8283 > Specifically, scroll as little as possible to get the current message
   8284 > to just fit on the right side.
   8285 
   8286 Is this the same as setting loose_alignment to true, and the
   8287 IDEAL_*_CONTENTs to 0?
   8288 -- 
   8289 William <wmorgan-sup at masanjin.net>
   8290 
   8291 From rlane@club.cc.cmu.edu  Sun Aug 23 14:36:59 2009
   8292 From: rlane@club.cc.cmu.edu (Rich Lane)
   8293 Date: Sun, 23 Aug 2009 11:36:59 -0700
   8294 Subject: [sup-talk] [PATCH] sup-sync: restore state on messages that dont
   8295 	already exist
   8296 Message-ID: <1251052619-9915-1-git-send-email-rlane@club.cc.cmu.edu>
   8297 
   8298 ---
   8299  bin/sup-sync |    5 +++++
   8300  1 files changed, 5 insertions(+), 0 deletions(-)
   8301 
   8302 diff --git a/bin/sup-sync b/bin/sup-sync
   8303 index 2aa00c3..003a72d 100755
   8304 --- a/bin/sup-sync
   8305 +++ b/bin/sup-sync
   8306 @@ -174,7 +174,12 @@ begin
   8307        ## decide what to do based on message labels and the operation we're performing
   8308        dothis, new_labels = case
   8309        when (op == :restore) && restored_state[m.id] && old_m && (old_m.labels != restored_state[m.id])
   8310 +        num_restored += 1
   8311          [:update_message_state, restored_state[m.id]]
   8312 +      when (op == :restore) && restored_state[m.id] && !old_m
   8313 +        num_restored += 1
   8314 +        m.labels = restored_state[m.id]
   8315 +        :add_message
   8316        when op == :discard
   8317          if old_m && (old_m.labels != m.labels)
   8318            [:update_message_state, m.labels]
   8319 -- 
   8320 1.6.4
   8321 
   8322 
   8323 From rlane@club.cc.cmu.edu  Sun Aug 23 14:46:10 2009
   8324 From: rlane@club.cc.cmu.edu (Rich Lane)
   8325 Date: Sun, 23 Aug 2009 11:46:10 -0700
   8326 Subject: [sup-talk] [PATCH 1/2] preemptively load messages when scrolling
   8327 Message-ID: <1251053171-11450-1-git-send-email-rlane@club.cc.cmu.edu>
   8328 
   8329 ---
   8330  lib/sup/modes/line-cursor-mode.rb |    2 +-
   8331  1 files changed, 1 insertions(+), 1 deletions(-)
   8332 
   8333 diff --git a/lib/sup/modes/line-cursor-mode.rb b/lib/sup/modes/line-cursor-mode.rb
   8334 index 246f2b5..0b1fd1d 100644
   8335 --- a/lib/sup/modes/line-cursor-mode.rb
   8336 +++ b/lib/sup/modes/line-cursor-mode.rb
   8337 @@ -77,7 +77,7 @@ protected
   8338    end
   8339  
   8340    def cursor_down
   8341 -    call_load_more_callbacks buffer.content_height if @curpos == lines - 1
   8342 +    call_load_more_callbacks buffer.content_height if @curpos >= lines - [buffer.content_height/2,1].max
   8343      return false unless @curpos < lines - 1
   8344  
   8345      if @curpos >= botline - 1
   8346 -- 
   8347 1.6.4
   8348 
   8349 
   8350 From rlane@club.cc.cmu.edu  Sun Aug 23 14:46:11 2009
   8351 From: rlane@club.cc.cmu.edu (Rich Lane)
   8352 Date: Sun, 23 Aug 2009 11:46:11 -0700
   8353 Subject: [sup-talk] [PATCH 2/2] ui responsiveness tweaks
   8354 In-Reply-To: <1251053171-11450-1-git-send-email-rlane@club.cc.cmu.edu>
   8355 References: <1251053171-11450-1-git-send-email-rlane@club.cc.cmu.edu>
   8356 Message-ID: <1251053171-11450-2-git-send-email-rlane@club.cc.cmu.edu>
   8357 
   8358 ---
   8359  bin/sup                            |    1 +
   8360  lib/sup/modes/thread-index-mode.rb |    4 ++--
   8361  2 files changed, 3 insertions(+), 2 deletions(-)
   8362 
   8363 diff --git a/bin/sup b/bin/sup
   8364 index 3d5b6c1..f3c6771 100755
   8365 --- a/bin/sup
   8366 +++ b/bin/sup
   8367 @@ -58,6 +58,7 @@ if $opts[:list_hooks]
   8368  end
   8369  
   8370  Thread.abort_on_exception = true # make debugging possible
   8371 +Thread.current.priority = 1 # keep ui responsive
   8372  
   8373  module Redwood
   8374  
   8375 diff --git a/lib/sup/modes/thread-index-mode.rb b/lib/sup/modes/thread-index-mode.rb
   8376 index fb6b2ce..177431b 100644
   8377 --- a/lib/sup/modes/thread-index-mode.rb
   8378 +++ b/lib/sup/modes/thread-index-mode.rb
   8379 @@ -76,8 +76,7 @@ EOS
   8380      @last_load_more_size = nil
   8381      to_load_more do |size|
   8382        next if @last_load_more_size == 0
   8383 -      load_threads :num => 1, :background => false
   8384 -      load_threads :num => (size - 1),
   8385 +      load_threads :num => size,
   8386                     :when_done => lambda { |num| @last_load_more_size = num }
   8387      end
   8388    end
   8389 @@ -627,6 +626,7 @@ EOS
   8390          BufferManager.draw_screen
   8391          last_update = Time.now
   8392        end
   8393 +      ::Thread.pass
   8394        break if @interrupt_search
   8395      end
   8396      @ts.threads.each { |th| th.labels.each { |l| LabelManager << l } }
   8397 -- 
   8398 1.6.4
   8399 
   8400 
   8401 From rlane@club.cc.cmu.edu  Sun Aug 23 14:49:02 2009
   8402 From: rlane@club.cc.cmu.edu (Rich Lane)
   8403 Date: Sun, 23 Aug 2009 11:49:02 -0700
   8404 Subject: [sup-talk] [PATCH] reply all keybindings
   8405 Message-ID: <1251053342-11859-1-git-send-email-rlane@club.cc.cmu.edu>
   8406 
   8407 ---
   8408  lib/sup/modes/reply-mode.rb        |    6 ++++--
   8409  lib/sup/modes/thread-index-mode.rb |    7 +++++--
   8410  lib/sup/modes/thread-view-mode.rb  |    7 +++++--
   8411  3 files changed, 14 insertions(+), 6 deletions(-)
   8412 
   8413 diff --git a/lib/sup/modes/reply-mode.rb b/lib/sup/modes/reply-mode.rb
   8414 index 700dfc1..3d39a8a 100644
   8415 --- a/lib/sup/modes/reply-mode.rb
   8416 +++ b/lib/sup/modes/reply-mode.rb
   8417 @@ -40,7 +40,7 @@ Return value:
   8418    The reply mode you desire, or nil to use the default behavior.
   8419  EOS
   8420  
   8421 -  def initialize message
   8422 +  def initialize message, type_arg=nil
   8423      @m = message
   8424  
   8425      ## it's important to put this early because it forces a read of
   8426 @@ -138,7 +138,9 @@ EOS
   8427      hook_reply = HookManager.run "reply-to", :modes => types
   8428  
   8429      @type_selector.set_to(
   8430 -      if types.include? hook_reply
   8431 +      if types.include? type_arg
   8432 +        type_arg
   8433 +      elsif types.include? hook_reply
   8434          hook_reply
   8435        elsif @m.is_list_message?
   8436          :list
   8437 diff --git a/lib/sup/modes/thread-index-mode.rb b/lib/sup/modes/thread-index-mode.rb
   8438 index fb6b2ce..d1b7fdb 100644
   8439 --- a/lib/sup/modes/thread-index-mode.rb
   8440 +++ b/lib/sup/modes/thread-index-mode.rb
   8441 @@ -40,6 +40,7 @@ EOS
   8442      k.add :save, "Save changes now", '$'
   8443      k.add :jump_to_next_new, "Jump to next new thread", :tab
   8444      k.add :reply, "Reply to latest message in a thread", 'r'
   8445 +    k.add :reply_all, "Reply to all participants of the latest message in a thread", 'G'
   8446      k.add :forward, "Forward latest message in a thread", 'f'
   8447      k.add :toggle_tagged, "Tag/untag selected thread", 't'
   8448      k.add :toggle_tagged_all, "Tag/untag all threads", 'T'
   8449 @@ -584,15 +585,17 @@ EOS
   8450      end
   8451    end
   8452  
   8453 -  def reply
   8454 +  def reply type_arg=nil
   8455      t = cursor_thread or return
   8456      m = t.latest_message
   8457      return if m.nil? # probably won't happen
   8458      m.load_from_source!
   8459 -    mode = ReplyMode.new m
   8460 +    mode = ReplyMode.new m, type_arg
   8461      BufferManager.spawn "Reply to #{m.subj}", mode
   8462    end
   8463  
   8464 +  def reply_all; reply :all; end
   8465 +
   8466    def forward
   8467      t = cursor_thread or return
   8468      m = t.latest_message
   8469 diff --git a/lib/sup/modes/thread-view-mode.rb b/lib/sup/modes/thread-view-mode.rb
   8470 index bac4792..98145cc 100644
   8471 --- a/lib/sup/modes/thread-view-mode.rb
   8472 +++ b/lib/sup/modes/thread-view-mode.rb
   8473 @@ -53,6 +53,7 @@ EOS
   8474      k.add :toggle_new, "Toggle unread/read status of message", 'N'
   8475  #    k.add :collapse_non_new_messages, "Collapse all but unread messages", 'N'
   8476      k.add :reply, "Reply to a message", 'r'
   8477 +    k.add :reply_all, "Reply to all participants of this message", 'G'
   8478      k.add :forward, "Forward a message or attachment", 'f'
   8479      k.add :bounce, "Bounce message to other recipient(s)", '!'
   8480      k.add :alias, "Edit alias/nickname for a person", 'i'
   8481 @@ -161,12 +162,14 @@ EOS
   8482      update
   8483    end
   8484  
   8485 -  def reply
   8486 +  def reply type_arg=nil
   8487      m = @message_lines[curpos] or return
   8488 -    mode = ReplyMode.new m
   8489 +    mode = ReplyMode.new m, type_arg
   8490      BufferManager.spawn "Reply to #{m.subj}", mode
   8491    end
   8492  
   8493 +  def reply_all; reply :all; end
   8494 +
   8495    def subscribe_to_list
   8496      m = @message_lines[curpos] or return
   8497      if m.list_subscribe && m.list_subscribe =~ /<mailto:(.*?)\?(subject=(.*?))>/
   8498 -- 
   8499 1.6.4
   8500 
   8501 
   8502 From nicolas.pouillard@gmail.com  Mon Aug 24 08:20:20 2009
   8503 From: nicolas.pouillard@gmail.com (Nicolas Pouillard)
   8504 Date: Mon, 24 Aug 2009 14:20:20 +0200
   8505 Subject: [sup-talk] [PATCH] index log
   8506 In-Reply-To: <1250948551-sup-2052@masanjin.net>
   8507 References: <1250491123-19240-1-git-send-email-rlane@club.cc.cmu.edu>
   8508 	<1250948551-sup-2052@masanjin.net>
   8509 Message-ID: <1251116226-sup-1373@peray>
   8510 
   8511 Excerpts from William Morgan's message of Sat Aug 22 15:46:27 +0200 2009:
   8512 > Reformatted excerpts from Rich Lane's message of 2009-08-16:
   8513 > > Add a YAML logfile that records changes to the index and modify
   8514 > > sup-dump to use this rather than the normal database.
   8515 > 
   8516 > I like this. I'm going to wait to apply it until the api refactoring
   8517 > stuff is merged down to master though. Should be soon.
   8518 
   8519 I'm wondering if a simpler format would not be better, I've patch
   8520 in my sup copy do feed a file called ~/.sup/labels-mapping.log with
   8521 lines like those:
   8522 
   8523 000e0cd20f80143822047118693d at google.com (unread inbox -> )
   8524 20090813213654.GA30223 at community.haskell.org (unread inbox patch -> patch)
   8525 1250148617-sup-6053 at oz.taruti.net (unread inbox sup -> sup)
   8526 1250281208-sup-4199 at masanjin.net (unread inbox sup -> sup)
   8527 
   8528 Their are in the style of sup-dump output and there are pretty easy to manage
   8529 by any tools.
   8530 
   8531 Not to say that I don't like YAML, I am a pretty big fan of it; but here it
   8532 seems overkill.
   8533 
   8534 Best regards,
   8535 
   8536 -- 
   8537 Nicolas Pouillard
   8538 http://nicolaspouillard.fr
   8539 
   8540 From nicolas.pouillard@gmail.com  Mon Aug 24 08:41:03 2009
   8541 From: nicolas.pouillard@gmail.com (Nicolas Pouillard)
   8542 Date: Mon, 24 Aug 2009 14:41:03 +0200
   8543 Subject: [sup-talk] [PATCH 2/2] xapian index format versioning
   8544 In-Reply-To: <1250951723-sup-3859@masanjin.net>
   8545 References: <1250451331-16070-1-git-send-email-rlane@club.cc.cmu.edu>
   8546 	<1250451331-16070-2-git-send-email-rlane@club.cc.cmu.edu>
   8547 	<20090816200116.GA17272@chistera.yi.org>
   8548 	<1250453934-sup-9651@zyrg.net> <1250951723-sup-3859@masanjin.net>
   8549 Message-ID: <1251117610-sup-9144@peray>
   8550 
   8551 Excerpts from William Morgan's message of Sat Aug 22 16:35:37 +0200 2009:
   8552 > Branch xapian-updates, merged into next. Thanks!
   8553 
   8554 What is the updating procedure please ?
   8555 
   8556 -- 
   8557 Nicolas Pouillard
   8558 http://nicolaspouillard.fr
   8559 
   8560 From wmorgan-sup@masanjin.net  Mon Aug 24 14:13:43 2009
   8561 From: wmorgan-sup@masanjin.net (William Morgan)
   8562 Date: Mon, 24 Aug 2009 11:13:43 -0700
   8563 Subject: [sup-talk] In next: thread-view-mode labelling No method join
   8564 	for Set
   8565 In-Reply-To: <1250727630-sup-3112@yoom.home.cworth.org>
   8566 References: <1250714501-sup-3033@chigamba>
   8567 	<1250727630-sup-3112@yoom.home.cworth.org>
   8568 Message-ID: <1251137007-sup-3974@masanjin.net>
   8569 
   8570 Reformatted excerpts from Carl Worth's message of 2009-08-19:
   8571 > I've attached a patch that at least makes the crashes I was able ro
   8572 > reproduce go away.
   8573 
   8574 Applied, thanks!
   8575 
   8576 > [*] Totally off-topic: This is one of the things about "dynamically
   8577 > typed" languages that I've never been able to wrap my brain around. I
   8578 > really like that with static typing I can trust the compiler to help
   8579 > me be very thorough if I make a type change like this, (and catch all
   8580 > the cases before shipping any code). Instead, here, there's a hard
   8581 > task of exercising every possible code path (at run time) before we
   8582 > know if there are any type errors still lingering. I've seen some
   8583 > proponents of dynamically-typed languages argue that unit testing
   8584 > should provide the same coverage that a statically-typed compiler
   8585 > would, but I haven't seen that in practice.
   8586 
   8587 You're right, this is a classic example of the type of bug that would be
   8588 caught with static typing. Unit tests are the canonical answer. I'd
   8589 argue that unit tests provide better error checking than static typing,
   8590 since they allow you to capture the exact set of errors you're
   8591 interested in, rather than the set of type mismatches that a
   8592 type-checker can detect. (IMO the two sets rarely have more than a very
   8593 small overlap.)
   8594 
   8595 Unit tests are only useful, of course, if you write them. Sup doesn't
   8596 have very many. I've made an explicit choice to spend my oh-so-limited
   8597 Sup time adding new features rather than ensuring a rock-solid platform.
   8598 The occasional bug like this is the price we all pay. But it's a matter
   8599 of tradeoffs---I do believe that if I were using a statically-typed
   8600 language, development would be significantly slower, and Sup would be
   8601 nowhere near the point it is now. I have no proof of this statement, of
   8602 course.
   8603 
   8604 And if anyone wants to retrofit some unit tests, I'm more than happy to
   8605 accept them!
   8606 -- 
   8607 William <wmorgan-sup at masanjin.net>
   8608 
   8609 From lists@larsko.org  Mon Aug 24 16:54:35 2009
   8610 From: lists@larsko.org (Lars Kotthoff)
   8611 Date: Mon, 24 Aug 2009 21:54:35 +0100
   8612 Subject: [sup-talk] Encrypted password in configuration file
   8613 Message-ID: <20090824215435.182e0007@ronin.larsko.net>
   8614 
   8615 Hi list,
   8616 
   8617  is it possible to store the account password encrypted in the configuration
   8618 file?
   8619 
   8620 Thanks,
   8621 
   8622 Lars
   8623 
   8624 From wmorgan-sup@masanjin.net  Mon Aug 24 18:38:42 2009
   8625 From: wmorgan-sup@masanjin.net (William Morgan)
   8626 Date: Mon, 24 Aug 2009 15:38:42 -0700
   8627 Subject: [sup-talk] Bug: Quits on unbound(?) keys
   8628 In-Reply-To: <1250968143-sup-3847@cannonball>
   8629 References: <a1b6cb1b0908211608u40e3ab67h9ff7373a4a686062@mail.gmail.com>
   8630 	<1250968143-sup-3847@cannonball>
   8631 Message-ID: <1251153498-sup-1707@masanjin.net>
   8632 
   8633 Reformatted excerpts from Ingmar Vanhassel's message of 2009-08-22:
   8634 > I bet you're using ncurses-ruby-1.2.2? What you're seeing is an
   8635 > ncurses-ruby bug:
   8636 > http://bugs.debian.org/cgi-bin/bugreport.cgi?bug=532431
   8637 
   8638 Wow, Sup is really giving the ncurses-ruby maintainer a workout. Nice!
   8639 -- 
   8640 William <wmorgan-sup at masanjin.net>
   8641 
   8642 From wmorgan-sup@masanjin.net  Mon Aug 24 18:44:58 2009
   8643 From: wmorgan-sup@masanjin.net (William Morgan)
   8644 Date: Mon, 24 Aug 2009 15:44:58 -0700
   8645 Subject: [sup-talk] [PATCH] Add an after-add-message hook
   8646 In-Reply-To: <1250819862-4858-1-git-send-email-kevinr@free-dissociation.com>
   8647 References: <1250707991-sup-5429@masanjin.net>
   8648 	<1250819862-4858-1-git-send-email-kevinr@free-dissociation.com>
   8649 Message-ID: <1251153881-sup-1538@masanjin.net>
   8650 
   8651 Reformatted excerpts from Kevin Riggle's message of 2009-08-20:
   8652 > I want to do some unrelated processing on each message I receive, but
   8653 > I don't want to block the message being added to the index.  This
   8654 > patch adds a hook which runs /after/ the message is added to the
   8655 > index.
   8656 
   8657 Branch after-add-message-hook, merged into next. Thanks!
   8658 -- 
   8659 William <wmorgan-sup at masanjin.net>
   8660 
   8661 From wmorgan-sup@masanjin.net  Mon Aug 24 18:45:37 2009
   8662 From: wmorgan-sup@masanjin.net (William Morgan)
   8663 Date: Mon, 24 Aug 2009 15:45:37 -0700
   8664 Subject: [sup-talk] 'next' crash: wrong id called on nil
   8665 	(thread.rb:264:in `thread_for')
   8666 In-Reply-To: <1250820431-sup-8159@yoom.home.cworth.org>
   8667 References: <1250820431-sup-8159@yoom.home.cworth.org>
   8668 Message-ID: <1251153912-sup-5105@masanjin.net>
   8669 
   8670 Reformatted excerpts from Carl Worth's message of 2009-08-20:
   8671 > --- RuntimeError from thread: main
   8672 > wrong id called on nil
   8673 
   8674 I think this should be fixed in recent nexts. Can you confirm?
   8675 -- 
   8676 William <wmorgan-sup at masanjin.net>
   8677 
   8678 From wmorgan-sup@masanjin.net  Mon Aug 24 18:46:12 2009
   8679 From: wmorgan-sup@masanjin.net (William Morgan)
   8680 Date: Mon, 24 Aug 2009 15:46:12 -0700
   8681 Subject: [sup-talk] Crashing ssh + sup, bad combo
   8682 In-Reply-To: <1e5fdab70908210900y5b51722agf33487b3d4dafcf4@mail.gmail.com>
   8683 References: <1e5fdab70908210900y5b51722agf33487b3d4dafcf4@mail.gmail.com>
   8684 Message-ID: <1251153959-sup-7992@masanjin.net>
   8685 
   8686 Reformatted excerpts from Guillaume Quintard's message of 2009-08-21:
   8687 > --- RuntimeError from thread: load threads for thread-index-mode
   8688 > wrong id called on nil
   8689 
   8690 Let me know if this is still a problem.
   8691 -- 
   8692 William <wmorgan-sup at masanjin.net>
   8693 
   8694 From wmorgan-sup@masanjin.net  Mon Aug 24 18:48:05 2009
   8695 From: wmorgan-sup@masanjin.net (William Morgan)
   8696 Date: Mon, 24 Aug 2009 15:48:05 -0700
   8697 Subject: [sup-talk] Bug: Log printing with encoding problems
   8698 In-Reply-To: <a1b6cb1b0908211604p4c0e94bk87134933f45e6f73@mail.gmail.com>
   8699 References: <a1b6cb1b0908211604p4c0e94bk87134933f45e6f73@mail.gmail.com>
   8700 Message-ID: <1251154017-sup-4599@masanjin.net>
   8701 
   8702 Reformatted excerpts from Ulrik Sverdrup's message of 2009-08-21:
   8703 > My locale is sv_SE.UTF-8, log is truncated since the date string is
   8704 > longer than expected.
   8705 
   8706 Are you running with the ncursesw-enabled ncurses.so? If so, this should
   8707 work, assuming your terminal is otherwise capable of displaying utf8.
   8708 -- 
   8709 William <wmorgan-sup at masanjin.net>
   8710 
   8711 From wmorgan-sup@masanjin.net  Mon Aug 24 19:23:32 2009
   8712 From: wmorgan-sup@masanjin.net (William Morgan)
   8713 Date: Mon, 24 Aug 2009 16:23:32 -0700
   8714 Subject: [sup-talk] [PATCH] add Message#load_from_index! shortcut
   8715 In-Reply-To: <1250965695-31073-1-git-send-email-rlane@club.cc.cmu.edu>
   8716 References: <1250965695-31073-1-git-send-email-rlane@club.cc.cmu.edu>
   8717 Message-ID: <1251156117-sup-2313@masanjin.net>
   8718 
   8719 Reformatted excerpts from Rich Lane's message of 2009-08-22:
   8720 > Message#parse_header is slow, taking up to 2/3 of the time spent
   8721 > loading threads in thread-index-mode. This patch adds a shortcut
   8722 > method that the index can use to efficiently initialize a message.
   8723 
   8724 Yes, great catch. I've applied this to xapian-updates branch and
   8725 remerged into next.
   8726 
   8727 BTW can you base your patches off master instead of next? It will save
   8728 me a couple keystrokes.
   8729 -- 
   8730 William <wmorgan-sup at masanjin.net>
   8731 
   8732 From wmorgan-sup@masanjin.net  Mon Aug 24 19:24:19 2009
   8733 From: wmorgan-sup@masanjin.net (William Morgan)
   8734 Date: Mon, 24 Aug 2009 16:24:19 -0700
   8735 Subject: [sup-talk] [PATCH] add xapian-specific hack to quickly create a
   8736 	Person
   8737 In-Reply-To: <1250967263-31292-1-git-send-email-rlane@club.cc.cmu.edu>
   8738 References: <1250965695-31073-1-git-send-email-rlane@club.cc.cmu.edu>
   8739 	<1250967263-31292-1-git-send-email-rlane@club.cc.cmu.edu>
   8740 Message-ID: <1251156216-sup-5563@masanjin.net>
   8741 
   8742 Reformatted excerpts from Rich Lane's message of 2009-08-22:
   8743 > -    mk_person = lambda { |x| Person.new(*x.reverse!) }
   8744 > +    mk_person = lambda { |x| QuickPerson.new(*x) }
   8745 
   8746 What about lambda { |x| Person.new x[1], x[0] }. Surely that must be
   8747 even faster?
   8748 -- 
   8749 William <wmorgan-sup at masanjin.net>
   8750 
   8751 From wmorgan-sup@masanjin.net  Mon Aug 24 19:29:40 2009
   8752 From: wmorgan-sup@masanjin.net (William Morgan)
   8753 Date: Mon, 24 Aug 2009 16:29:40 -0700
   8754 Subject: [sup-talk] How to edit attachments in reply?
   8755 In-Reply-To: <1251031062-sup-4617@tiger.alporthouse.com>
   8756 References: <1251031062-sup-4617@tiger.alporthouse.com>
   8757 Message-ID: <1251156446-sup-143@masanjin.net>
   8758 
   8759 Reformatted excerpts from Chris Wilson's message of 2009-08-23:
   8760 > Can anyone give me any clues on how to automatically include the
   8761 > attachments in a reply?
   8762 
   8763 There's no way to do this currently. The best option might be to add a
   8764 hook that sets the reply body at the beginning of reply-mode. Then you
   8765 could add the attachments (if the mime type were appropriate) and do
   8766 whatever other transformations you wanted on the message.
   8767 -- 
   8768 William <wmorgan-sup at masanjin.net>
   8769 
   8770 From rlane@club.cc.cmu.edu  Mon Aug 24 21:03:29 2009
   8771 From: rlane@club.cc.cmu.edu (Rich Lane)
   8772 Date: Mon, 24 Aug 2009 21:03:29 -0400
   8773 Subject: [sup-talk] [PATCH 2/2] xapian index format versioning
   8774 In-Reply-To: <1251117610-sup-9144@peray>
   8775 References: <1250451331-16070-1-git-send-email-rlane@club.cc.cmu.edu>
   8776 	<1250451331-16070-2-git-send-email-rlane@club.cc.cmu.edu>
   8777 	<20090816200116.GA17272@chistera.yi.org>
   8778 	<1250453934-sup-9651@zyrg.net>
   8779 	<1250951723-sup-3859@masanjin.net> <1251117610-sup-9144@peray>
   8780 Message-ID: <1251161843-sup-2990@zyrg.net>
   8781 
   8782 Excerpts from Nicolas Pouillard's message of Mon Aug 24 08:41:03 -0400 2009:
   8783 > Excerpts from William Morgan's message of Sat Aug 22 16:35:37 +0200 2009:
   8784 > > Branch xapian-updates, merged into next. Thanks!
   8785 > 
   8786 > What is the updating procedure please ?
   8787 > 
   8788 
   8789 sup-dump and sup-sync. Sorry for the inconvenience, but I don't
   8790 currently have plans to break compatibility again so you should be safe
   8791 for a while.
   8792 
   8793 From nicolas.pouillard@gmail.com  Tue Aug 25 03:44:11 2009
   8794 From: nicolas.pouillard@gmail.com (Nicolas Pouillard)
   8795 Date: Tue, 25 Aug 2009 09:44:11 +0200
   8796 Subject: [sup-talk] In next: thread-view-mode labelling No method join
   8797 	for Set
   8798 In-Reply-To: <1251137007-sup-3974@masanjin.net>
   8799 References: <1250714501-sup-3033@chigamba>
   8800 	<1250727630-sup-3112@yoom.home.cworth.org>
   8801 	<1251137007-sup-3974@masanjin.net>
   8802 Message-ID: <1251185965-sup-6316@peray>
   8803 
   8804 Excerpts from William Morgan's message of Mon Aug 24 20:13:43 +0200 2009:
   8805 > Reformatted excerpts from Carl Worth's message of 2009-08-19:
   8806 > > I've attached a patch that at least makes the crashes I was able ro
   8807 > > reproduce go away.
   8808 > 
   8809 > Applied, thanks!
   8810 > 
   8811 > > [*] Totally off-topic: This is one of the things about "dynamically
   8812 > > typed" languages that I've never been able to wrap my brain around. I
   8813 > > really like that with static typing I can trust the compiler to help
   8814 > > me be very thorough if I make a type change like this, (and catch all
   8815 > > the cases before shipping any code). Instead, here, there's a hard
   8816 > > task of exercising every possible code path (at run time) before we
   8817 > > know if there are any type errors still lingering. I've seen some
   8818 > > proponents of dynamically-typed languages argue that unit testing
   8819 > > should provide the same coverage that a statically-typed compiler
   8820 > > would, but I haven't seen that in practice.
   8821 
   8822 [...]
   8823 
   8824 > I do believe that if I were using a statically-typed
   8825 > language, development would be significantly slower, and Sup would be
   8826 > nowhere near the point it is now. I have no proof of this statement, of
   8827 > course.
   8828 
   8829 I don't really want to start troll on this subject... However it depends
   8830 on what kind of statically-typed language to talk about, if you mean Java
   8831 or C++ then I agree with you, the development would be much sloooower.
   8832 Although if we take a language like Haskell (or OCaml, or Scala...) the
   8833 development become really competitive.
   8834 
   8835 Best regards,
   8836 
   8837 -- 
   8838 Nicolas Pouillard
   8839 http://nicolaspouillard.fr
   8840 
   8841 From israel.herraiz@gmail.com  Tue Aug 25 05:29:01 2009
   8842 From: israel.herraiz@gmail.com (Israel Herraiz)
   8843 Date: Tue, 25 Aug 2009 11:29:01 +0200
   8844 Subject: [sup-talk] [PATCH] Add UTF-8 encoding string for ArchLinux systems
   8845 Message-ID: <1251192382-sup-2350@elly>
   8846 
   8847 Hi,
   8848 
   8849 in ArchLinux, UTF-8 encoding is identified by "utf8" instead of
   8850 "UTF-8".
   8851 
   8852 Cheers,
   8853 Israel
   8854 
   8855 ---
   8856  lib/sup/util.rb |    2 +-
   8857  1 files changed, 1 insertions(+), 1 deletions(-)
   8858 
   8859 diff --git a/lib/sup/util.rb b/lib/sup/util.rb
   8860 index 068ce6b..f99e1c1 100644
   8861 --- a/lib/sup/util.rb
   8862 +++ b/lib/sup/util.rb
   8863 @@ -177,7 +177,7 @@ class String
   8864    ## nasty multibyte hack for ruby 1.8. if it's utf-8, split into chars using
   8865    ## the utf8 regex and count those. otherwise, use the byte length.
   8866    def display_length
   8867 -    if $encoding == "UTF-8"
   8868 +    if $encoding == "UTF-8" || $encoding == "utf8"
   8869        scan(/./u).size
   8870      else
   8871        size
   8872 -- 
   8873 1.6.4
   8874 
   8875 
   8876 
   8877 From israel.herraiz@gmail.com  Tue Aug 25 05:31:55 2009
   8878 From: israel.herraiz@gmail.com (Israel Herraiz)
   8879 Date: Tue, 25 Aug 2009 11:31:55 +0200
   8880 Subject: [sup-talk] [PATCH] Identify list messages by list-id if list-post
   8881 	is not present
   8882 Message-ID: <1251192579-sup-1849@elly>
   8883 
   8884 Hi,
   8885 
   8886 I am subscribed to some lists that do not fill the list-post header,
   8887 but have a list-id header. I am not sure how standard-compliant is
   8888 that, but it would nice if Sup could identify those messages as list
   8889 messages.
   8890 
   8891 Cheers,
   8892 Israel
   8893 
   8894 ---
   8895  lib/sup/message.rb |   11 +++++++++--
   8896  1 files changed, 9 insertions(+), 2 deletions(-)
   8897 
   8898 diff --git a/lib/sup/message.rb b/lib/sup/message.rb
   8899 index 56e66de..67f928c 100644
   8900 --- a/lib/sup/message.rb
   8901 +++ b/lib/sup/message.rb
   8902 @@ -34,7 +34,7 @@ class Message
   8903  
   8904    attr_reader :id, :date, :from, :subj, :refs, :replytos, :to, :source,
   8905                :cc, :bcc, :labels, :attachments, :list_address, :recipient_email, :replyto,
   8906 -              :source_info, :list_subscribe, :list_unsubscribe
   8907 +              :source_info, :list_subscribe, :list_unsubscribe, :list_id
   8908  
   8909    bool_reader :dirty, :source_marked_read, :snippet_contains_encrypted_content
   8910  
   8911 @@ -120,6 +120,13 @@ class Message
   8912        else
   8913          nil
   8914        end
   8915 +     
   8916 +    @list_id =
   8917 +      if header["list-id"]
   8918 +        @list_id = header["list-id"].gsub(/^<|>$/, "")
   8919 +      else
   8920 +        nil
   8921 +      end
   8922  
   8923      @recipient_email = header["envelope-to"] || header["x-original-to"] || header["delivered-to"]
   8924      @source_marked_read = header["status"] == "RO"
   8925 @@ -162,7 +169,7 @@ class Message
   8926    end
   8927  
   8928    def snippet; @snippet || (chunks && @snippet); end
   8929 -  def is_list_message?; !@list_address.nil?; end
   8930 +  def is_list_message?; !@list_address.nil? || !@list_id.nil?; end
   8931    def is_draft?; @source.is_a? DraftLoader; end
   8932    def draft_filename
   8933      raise "not a draft" unless is_draft?
   8934 -- 
   8935 1.6.4
   8936 
   8937 
   8938 From wmorgan-sup@masanjin.net  Tue Aug 25 10:16:44 2009
   8939 From: wmorgan-sup@masanjin.net (William Morgan)
   8940 Date: Tue, 25 Aug 2009 07:16:44 -0700
   8941 Subject: [sup-talk] lots of branches merged down to  master
   8942 Message-ID: <1251209432-sup-766@masanjin.net>
   8943 
   8944 Just FYI, I've merged the following branches down to master:
   8945 buffer-rolling, run-mailcap-fixes, locking-refactor, logging,
   8946 various-api-tweaks, and ncurses-fixes. If you're running master, you
   8947 should see some fun improvements.
   8948 -- 
   8949 William <wmorgan-sup at masanjin.net>
   8950 
   8951 From rlane@club.cc.cmu.edu  Tue Aug 25 21:50:48 2009
   8952 From: rlane@club.cc.cmu.edu (Rich Lane)
   8953 Date: Tue, 25 Aug 2009 21:50:48 -0400
   8954 Subject: [sup-talk] [PATCH] add xapian-specific hack to quickly create a
   8955 	Person
   8956 In-Reply-To: <1251156216-sup-5563@masanjin.net>
   8957 References: <1250965695-31073-1-git-send-email-rlane@club.cc.cmu.edu>
   8958 	<1250967263-31292-1-git-send-email-rlane@club.cc.cmu.edu>
   8959 	<1251156216-sup-5563@masanjin.net>
   8960 Message-ID: <1251250991-sup-3593@zyrg.net>
   8961 
   8962 Excerpts from William Morgan's message of Mon Aug 24 19:24:19 -0400 2009:
   8963 > Reformatted excerpts from Rich Lane's message of 2009-08-22:
   8964 > > -    mk_person = lambda { |x| Person.new(*x.reverse!) }
   8965 > > +    mk_person = lambda { |x| QuickPerson.new(*x) }
   8966 > 
   8967 > What about lambda { |x| Person.new x[1], x[0] }. Surely that must be
   8968 > even faster?
   8969 
   8970 The slow part is the processing in Person#initialize, which QuickPerson
   8971 overrides. You might also be able to avoid that by moving the
   8972 initialize() code into Person.from_address.
   8973 
   8974 From cworth@cworth.org  Wed Aug 26 16:26:34 2009
   8975 From: cworth@cworth.org (Carl Worth)
   8976 Date: Wed, 26 Aug 2009 13:26:34 -0700
   8977 Subject: [sup-talk] 'next' crash: wrong id called on nil
   8978 	(thread.rb:264:in `thread_for')
   8979 In-Reply-To: <1251153912-sup-5105@masanjin.net>
   8980 References: <1250820431-sup-8159@yoom.home.cworth.org>
   8981 	<1251153912-sup-5105@masanjin.net>
   8982 Message-ID: <1251318332-sup-4953@yoom.home.cworth.org>
   8983 
   8984 Excerpts from William Morgan's message of Mon Aug 24 15:45:37 -0700 2009:
   8985 > Reformatted excerpts from Carl Worth's message of 2009-08-20:
   8986 > > --- RuntimeError from thread: main
   8987 > > wrong id called on nil
   8988 > 
   8989 > I think this should be fixed in recent nexts. Can you confirm?
   8990 
   8991 I don't think I'll be able to, (since I don't have a good recipe for
   8992 reproducing the bug). But I'll certainly start running rom newer next
   8993 and I'll let you know if I run into any further problems.
   8994 
   8995 Thanks for everything,
   8996 
   8997 -Carl
   8998 -------------- next part --------------
   8999 A non-text attachment was scrubbed...
   9000 Name: signature.asc
   9001 Type: application/pgp-signature
   9002 Size: 189 bytes
   9003 Desc: not available
   9004 URL: <http://rubyforge.org/pipermail/sup-talk/attachments/20090826/e9ada9c1/attachment.bin>
   9005 
   9006 From cworth@cworth.org  Wed Aug 26 17:15:36 2009
   9007 From: cworth@cworth.org (Carl Worth)
   9008 Date: Wed, 26 Aug 2009 14:15:36 -0700
   9009 Subject: [sup-talk] [PATCH 2/2] ui responsiveness tweaks
   9010 In-Reply-To: <1251053171-11450-2-git-send-email-rlane@club.cc.cmu.edu>
   9011 References: <1251053171-11450-1-git-send-email-rlane@club.cc.cmu.edu>
   9012 	<1251053171-11450-2-git-send-email-rlane@club.cc.cmu.edu>
   9013 Message-ID: <1251318620-sup-3031@yoom.home.cworth.org>
   9014 
   9015 My message here really has nothing to do with Rich's patches
   9016 specifically, (so sorry about that), but his patches happened to
   9017 provide the perfect context for an issue I wanted to bring up. As is
   9018 typical of git-formatted patches, Rich's emails have subject lines
   9019 from his commit messages:
   9020 
   9021     [sup-talk] [PATCH 1/2] preemptively load messages when scrolling
   9022     [sup-talk] [PATCH 2/2] ui responsiveness tweaks
   9023 
   9024 As far as the git commits go, this subject line is one of the most
   9025 essential pieces of metadata to accompany the patch. Yet by default
   9026 sup doesn't display it at all, (requiring keypresses to display the
   9027 header and find the subject line). I think what I would like is for
   9028 sup to display the subject line everytime it changes significantly in
   9029 a thread, (specifically not regarding things like an initial "Re: "
   9030 getting added as significant).
   9031 
   9032 I think I'd be willing to spend an entire line's worth of screen real
   9033 estate for this information---it's quite useful when people do
   9034 meaningful subject changes for sub-threads.
   9035 
   9036 -Carl
   9037 
   9038 Excerpts from Rich Lane's message of Sun Aug 23 11:46:11 -0700 2009:
   9039 > ---
   9040 >  bin/sup                            |    1 +
   9041 >  lib/sup/modes/thread-index-mode.rb |    4 ++--
   9042 >  2 files changed, 3 insertions(+), 2 deletions(-)
   9043 > 
   9044 > diff --git a/bin/sup b/bin/sup
   9045 > index 3d5b6c1..f3c6771 100755
   9046 > --- a/bin/sup
   9047 > +++ b/bin/sup
   9048 > @@ -58,6 +58,7 @@ if $opts[:list_hooks]
   9049 >  end
   9050 >  
   9051 >  Thread.abort_on_exception = true # make debugging possible
   9052 > +Thread.current.priority = 1 # keep ui responsive
   9053 >  
   9054 >  module Redwood
   9055 >  
   9056 > diff --git a/lib/sup/modes/thread-index-mode.rb
   9057 > b/lib/sup/modes/thread-index-mode.rb
   9058 > index fb6b2ce..177431b 100644
   9059 > --- a/lib/sup/modes/thread-index-mode.rb
   9060 > +++ b/lib/sup/modes/thread-index-mode.rb
   9061 > @@ -76,8 +76,7 @@ EOS
   9062 >      @last_load_more_size = nil
   9063 >      to_load_more do |size|
   9064 >        next if @last_load_more_size == 0
   9065 > -      load_threads :num => 1, :background => false
   9066 > -      load_threads :num => (size - 1),
   9067 > +      load_threads :num => size,
   9068 >                     :when_done => lambda { |num| @last_load_more_size = num }
   9069 >      end
   9070 >    end
   9071 > @@ -627,6 +626,7 @@ EOS
   9072 >          BufferManager.draw_screen
   9073 >          last_update = Time.now
   9074 >        end
   9075 > +      ::Thread.pass
   9076 >        break if @interrupt_search
   9077 >      end
   9078 >      @ts.threads.each { |th| th.labels.each { |l| LabelManager << l } }
   9079 -------------- next part --------------
   9080 A non-text attachment was scrubbed...
   9081 Name: signature.asc
   9082 Type: application/pgp-signature
   9083 Size: 189 bytes
   9084 Desc: not available
   9085 URL: <http://rubyforge.org/pipermail/sup-talk/attachments/20090826/5b3011d5/attachment.bin>
   9086 
   9087 From cworth@cworth.org  Wed Aug 26 17:26:18 2009
   9088 From: cworth@cworth.org (Carl Worth)
   9089 Date: Wed, 26 Aug 2009 14:26:18 -0700
   9090 Subject: [sup-talk] Exception trying to run git source
   9091 In-Reply-To: <1250964942-sup-8625@masanjin.net>
   9092 References: <1250642676-sup-2244@yoom> <1250698636-sup-6732@masanjin.net>
   9093 	<1250699596-sup-8133@ntdws12.chass.utoronto.ca>
   9094 	<1250704257-sup-3308@yoom> <1250707794-sup-6173@masanjin.net>
   9095 	<1250710221-sup-925@yoom.home.cworth.org>
   9096 	<1250712045-sup-3506@masanjin.net>
   9097 	<1250717434-sup-4489@yoom.home.cworth.org>
   9098 	<1250964942-sup-8625@masanjin.net>
   9099 Message-ID: <1251321606-sup-7393@yoom.home.cworth.org>
   9100 
   9101 Reformatted excerpts from William Morgan's message of Sat Aug 22 13:23:17 -0700 2009:
   9102 > Reformatted excerpts from Carl Worth's message of 2009-08-19:
   9103 > > $:.unshift File.dirname(__FILE__)     # For use/testing when no gem is installed
   9104 > 
   9105 > I'd call that a bug in chronic. It shouldn't be screwing with the load
   9106 > path.
   9107 
   9108 That's what I thought too. I filed a Debian bug against the
   9109 libchronic-ruby package here:
   9110 
   9111     http://bugs.debian.org/cgi-bin/bugreport.cgi?bug=542491
   9112 
   9113 But I reall only did that because I didn't find any contact
   9114 information for how to submit an upstream bug against chronic
   9115 (http://chronic.rubyforge.net didn't have any details that I could
   9116 find).
   9117 
   9118 So if someone knows a better place to file the bug, I'd be glad to do
   9119 that.
   9120 
   9121 > Nice debug work.
   9122 
   9123 Thanks.
   9124 
   9125 -Carl
   9126 -------------- next part --------------
   9127 A non-text attachment was scrubbed...
   9128 Name: signature.asc
   9129 Type: application/pgp-signature
   9130 Size: 189 bytes
   9131 Desc: not available
   9132 URL: <http://rubyforge.org/pipermail/sup-talk/attachments/20090826/41bd963c/attachment.bin>
   9133 
   9134 From cworth@cworth.org  Wed Aug 26 17:35:25 2009
   9135 From: cworth@cworth.org (Carl Worth)
   9136 Date: Wed, 26 Aug 2009 14:35:25 -0700
   9137 Subject: [sup-talk] [PATCH] Make SUP_LOG_LEVEL self-documenting.
   9138 In-Reply-To: <1250972634-sup-6871@masanjin.net>
   9139 References: <1250745799-sup-6607@yoom.home.cworth.org>
   9140 	<1250972634-sup-6871@masanjin.net>
   9141 Message-ID: <1251322427-sup-9184@yoom.home.cworth.org>
   9142 
   9143 The idea here is that if someone is looking at the log and not seeing
   9144 the information of interest, then the log itself should tell them
   9145 how to get more information, (by suggesting to set SUP_LOG_LEVEL
   9146 to the next lower level).
   9147 ---
   9148 
   9149 Excerpts from William Morgan's message of Sat Aug 22 13:25:22 -0700 2009:
   9150 > It all looks good except you can use Logger::LEVELS to access the
   9151 > constants. Then there's no need to write a LEVELS method. If you fix
   9152 > that I will apply. Thanks!
   9153 
   9154 Thanks. I had the distinct feeling I was doing something wrong
   9155 there. Here's a corrected version.
   9156 
   9157 -Carl
   9158 
   9159  bin/sup |    3 +++
   9160  1 files changed, 3 insertions(+), 0 deletions(-)
   9161 
   9162 diff --git a/bin/sup b/bin/sup
   9163 index 3d5b6c1..cdf1ff2 100755
   9164 --- a/bin/sup
   9165 +++ b/bin/sup
   9166 @@ -169,6 +169,9 @@ begin
   9167    lmode.on_kill { Logger.clear! }
   9168    Logger.add_sink lmode
   9169    Logger.force_message "Welcome to Sup! Log level is set to #{Logger.level}."
   9170 +  if Logger::LEVELS.index(Logger.level) > 0
   9171 +    Logger.force_message "For more verbose logging, restart with SUP_LOG_LEVEL=#{Logger::LEVELS[Logger::LEVELS.index(Logger.level)-1]}."
   9172 +  end
   9173  
   9174    debug "initializing inbox buffer"
   9175    imode = InboxMode.new
   9176 -- 
   9177 1.6.3.3
   9178 
   9179 -------------- next part --------------
   9180 A non-text attachment was scrubbed...
   9181 Name: signature.asc
   9182 Type: application/pgp-signature
   9183 Size: 189 bytes
   9184 Desc: not available
   9185 URL: <http://rubyforge.org/pipermail/sup-talk/attachments/20090826/3686da0d/attachment.bin>
   9186 
   9187 From cworth@cworth.org  Wed Aug 26 17:53:32 2009
   9188 From: cworth@cworth.org (Carl Worth)
   9189 Date: Wed, 26 Aug 2009 14:53:32 -0700
   9190 Subject: [sup-talk] [PATCH] Be less overzealous in moving text to the
   9191 	left column
   9192 In-Reply-To: <1251050007-sup-9740@masanjin.net>
   9193 References: <1250749447-sup-1744@yoom.home.cworth.org>
   9194 	<1251050007-sup-9740@masanjin.net>
   9195 Message-ID: <1251323127-sup-5162@yoom.home.cworth.org>
   9196 
   9197 Excerpts from William Morgan's message of Sun Aug 23 10:55:59 -0700 2009:
   9198 > Reformatted excerpts from Carl Worth's message of 2009-08-19:
   9199 > > Specifically, scroll as little as possible to get the current message
   9200 > > to just fit on the right side.
   9201 > 
   9202 > Is this the same as setting loose_alignment to true, and the
   9203 > IDEAL_*_CONTENTs to 0?
   9204 
   9205 I don't think so.
   9206 
   9207 Doing that, (at least as in the below patch, for example), always puts
   9208 the current message flush left. And that can result in later messages
   9209 in the threads, (not descendants of the current thread though), being
   9210 cut off on the left. (And all this with dozens of empty columns on the
   9211 right of my terminal.) That's precisely the behavior I was getting
   9212 before my patch and which I'm trying to change.
   9213 
   9214 What I want instead is for the message to appear in its "natural"
   9215 position (according to the threading), unless that would cause the
   9216 message to be cut off on the right. In which case, we jump to the
   9217 minimum column such that:
   9218 
   9219 	1. We don't cut any of the current message off on the left
   9220 
   9221 	2. We display all of the message on the right, (if possible
   9222 	   without violating point 1).
   9223 
   9224 I believe that what I've coded achieves that. The two open questions I
   9225 still have are:
   9226 
   9227 	A. Is there some simpler way to achieve the result I want with
   9228 	   some of the existing code?
   9229 
   9230 	B. If not, is some of the existing code rendered obsolete with
   9231 	   my code in place?
   9232 
   9233 As for (B), for example, with my code in place I don't think there's
   9234 any need for a notion of "ideal context". The ideal context is the
   9235 natural position of the thread.
   9236 
   9237 And I still haven't figured out what loose_alignment means and which
   9238 actions will cause loose vs. non-loose layout.
   9239 
   9240 -Carl
   9241 
   9242 diff --git a/lib/sup/modes/thread-view-mode.rb b/lib/sup/modes/thread-view-mode.rb
   9243 index dfe30ff..b7bbc7c 100644
   9244 --- a/lib/sup/modes/thread-view-mode.rb
   9245 +++ b/lib/sup/modes/thread-view-mode.rb
   9246 @@ -401,9 +401,9 @@ EOS
   9247      end
   9248    end
   9249  
   9250 -  IDEAL_TOP_CONTEXT = 3 # try and give 3 rows of top context
   9251 -  IDEAL_LEFT_CONTEXT = 4 # try and give 4 columns of left context
   9252 -  def jump_to_message m, loose_alignment=false
   9253 +  IDEAL_TOP_CONTEXT = 0 # don't bother trying to give any rows of top context
   9254 +  IDEAL_LEFT_CONTEXT = 0 # don't bother trying to give any columns of left context
   9255 +  def jump_to_message m, loose_alignment=true
   9256      l = @layout[m]
   9257      left = l.depth * INDENT_SPACES
   9258      right = left + l.width
   9259 -------------- next part --------------
   9260 A non-text attachment was scrubbed...
   9261 Name: signature.asc
   9262 Type: application/pgp-signature
   9263 Size: 189 bytes
   9264 Desc: not available
   9265 URL: <http://rubyforge.org/pipermail/sup-talk/attachments/20090826/8c5c013c/attachment.bin>
   9266 
   9267 From cworth@cworth.org  Wed Aug 26 18:24:36 2009
   9268 From: cworth@cworth.org (Carl Worth)
   9269 Date: Wed, 26 Aug 2009 15:24:36 -0700
   9270 Subject: [sup-talk] On making inbox-mode and search-results-mode more similar
   9271 Message-ID: <1251323747-sup-1595@yoom.home.cworth.org>
   9272 
   9273 [Argh! I ended up getting really verbose again with this one. Thanks
   9274 to anyone patient enough to wade through all of this. There is a patch
   9275 here for one issue at least. See below.]
   9276 
   9277 I spent about 4 days away from email which gave me my first case of a
   9278 large inbox after switching to sup. And there are definitely a few
   9279 things I'd like to convince sup to do to make it easier for me to deal
   9280 with this.
   9281 
   9282 Most important, with a large inbox, my mail falls into different
   9283 "classes", some of which are more important than others, and I'd like
   9284 to deal with the most important things first. I also often want to
   9285 deal with a single "class" of mail as a whole to avoid mental context
   9286 switches.
   9287 
   9288 Fortunately, I've got sup labels capturing these classes quite
   9289 well. I've got some future ideas for having a prioritized (partial
   9290 order) list of labels so that inbox-mode will present messages
   9291 according to that priority. But for now, it would be good enough to be
   9292 able to easily filter my inbox down to just a single class of messages
   9293 at a time.
   9294 
   9295 To this end, I started using the patch below, which adds a
   9296 refine_search keybinding to inbox-mode much like the same function in
   9297 search-result-mode. This is useful already and might be considered for
   9298 inclusion as is, (another feature I'd like for both modes is "restrict
   9299 to label" which would act like refine-search but save me from having
   9300 to type "label:" much like the 'L' command avoids having to type
   9301 "label:" compared to the 'F' command).
   9302 
   9303 Beyond this patch as is, though, I'd like to talk a bit about how to
   9304 better achieve what I want. There's obviously some code duplication in
   9305 this patch which is not ideal. It would be better if InboxMode could
   9306 be a derived class from SearchResultsMode. Not only would this reduce
   9307 code-duplication, but there are features currently in InboxMode that I
   9308 think belong in all searches.
   9309 
   9310 For example, if I use the refine_search command below to get a view of
   9311 my inbox restricted to a particular label, it no longer acts like my
   9312 inbox does. One of the most noticeable cases is the archive
   9313 command[*].  In both inbox-mode and search-result-mode this command
   9314 removes the "inbox" label from a thread, but in inbox-mode the thread
   9315 is immediately removed from the results, while in search-results-mode
   9316 the thread remains in the results.
   9317 
   9318 One annoying side effect of this is that when I'm reading and
   9319 archiving many threads in some class, then I happen to reply to one
   9320 thread, that thread gets bumped to the top of my search so when I
   9321 navigate to the "next" thread I start cycling through threads that I
   9322 just got finished reading and archiving. To fix this I end up having
   9323 to notice I'm seeing repeated messages, remember why, then save my
   9324 current changes and refresh the search. And I have to do this after
   9325 every reply.
   9326 
   9327 [Note: Even if archiving messages made them immediately disappear from
   9328 my search results, there could still be problems with "next" causing
   9329 me to re-cycle through messages I had already read but decided to
   9330 leave in my inbox. I think this is just another general race-condition
   9331 bug. I think the fix would be for the transition from
   9332 search-results-mode to thread-view-mode to somehow snapshot the
   9333 current search results so that future modifications due to newly
   9334 arriving messages don't modify the meaning of "next thread" within
   9335 thread-view-mode.]
   9336 
   9337 So what I want is for anytime a message is changed such that it no
   9338 longer meets the current search criteria, it is immediately removed
   9339 from the search results. I think that means simply implementing the
   9340 is_relevant? method for SearcResultsMode where there is currently just
   9341 the following comment:
   9342 
   9343   ## a proper is_relevant? method requires some way of asking ferret
   9344   ## if an in-memory object satisfies a query. i'm not sure how to do
   9345   ## that yet. in the worst case i can make an in-memory index, add
   9346   ## the message, and search against it to see if i have > 0 results,
   9347   ## but that seems pretty insane.
   9348 
   9349 That single-message index and search sounds exactly like what I want,
   9350 and not insane at all. Has someone attempted this and found a
   9351 performance issue? (In which case, I would think we just need to fix
   9352 that performance bug.) Or is it simply a matter of nobody having tried
   9353 to code this up yet? (In which case, I'll try, and I'll be glad for
   9354 any pointers that anyone can give me on how to go about creating an
   9355 in-memory index and searching on it.)
   9356 
   9357 Thanks,
   9358 
   9359 -Carl
   9360 
   9361 [*] I'll ignore for now the fact that 'a' is a toggle of the inbox
   9362 label in SearchResultsMode and a one-way removal of the label in
   9363 InboxMode. I haven't found any need to ever put a thread _back_ into
   9364 the inbox, (except perhaps in the case of accidental archiving, and
   9365 there an immediate undo works fine). So I would imagine the use is
   9366 rare enough to not need a single-character command. The command I
   9367 would find natural for putting a thread back into the inbox would be
   9368 to simply add the inbox label to the thread. Oddly this is currently
   9369 not allowed as "inbox" is a reserved label. I don't
   9370 
   9371 
   9372 >From d37eca31aaddee80f05357d6a4ed896f39bbad16 Mon Sep 17 00:00:00 2001
   9373 From: Carl Worth <cworth at cworth.org>
   9374 Date: Wed, 26 Aug 2009 10:17:20 -0700
   9375 Subject: [PATCH] Add a refine_search command to InboxMode
   9376 
   9377 This is just a copy of SearchResultsMode's refine_search command.
   9378 A much cleaner, but more involved, approach would be to rework
   9379 InboxMode to derive from SearchResultsMode in the first place.
   9380 ---
   9381  lib/sup/modes/inbox-mode.rb |    7 +++++++
   9382  1 files changed, 7 insertions(+), 0 deletions(-)
   9383 
   9384 diff --git a/lib/sup/modes/inbox-mode.rb b/lib/sup/modes/inbox-mode.rb
   9385 index ba095da..c8072cd 100644
   9386 --- a/lib/sup/modes/inbox-mode.rb
   9387 +++ b/lib/sup/modes/inbox-mode.rb
   9388 @@ -7,6 +7,7 @@ class InboxMode < ThreadIndexMode
   9389      ## overwrite toggle_archived with archive
   9390      k.add :archive, "Archive thread (remove from inbox)", 'a'
   9391      k.add :read_and_archive, "Archive thread (remove from inbox) and mark read", 'A'
   9392 +    k.add :refine_search, "Refine search", '|'
   9393    end
   9394  
   9395    def initialize
   9396 @@ -17,6 +18,12 @@ class InboxMode < ThreadIndexMode
   9397  
   9398    def is_relevant? m; (m.labels & [:spam, :deleted, :killed, :inbox]) == Set.new([:inbox]) end
   9399  
   9400 +  def refine_search
   9401 +    text = BufferManager.ask :search, "refine query: ", "label:inbox -label:spam -label:deleted -label:killed "
   9402 +    return unless text && text !~ /^\s*$/
   9403 +    SearchResultsMode.spawn_from_query text
   9404 +  end
   9405 +
   9406    ## label-list-mode wants to be able to raise us if the user selects
   9407    ## the "inbox" label, so we need to keep our singletonness around
   9408    def self.instance; @@instance; end
   9409 -- 
   9410 1.6.3.3
   9411 
   9412 -------------- next part --------------
   9413 A non-text attachment was scrubbed...
   9414 Name: signature.asc
   9415 Type: application/pgp-signature
   9416 Size: 189 bytes
   9417 Desc: not available
   9418 URL: <http://rubyforge.org/pipermail/sup-talk/attachments/20090826/0ec68a3f/attachment.bin>
   9419 
   9420 From cworth@cworth.org  Wed Aug 26 18:40:34 2009
   9421 From: cworth@cworth.org (Carl Worth)
   9422 Date: Wed, 26 Aug 2009 15:40:34 -0700
   9423 Subject: [sup-talk] [PATCH] Add 'a' and 'd' keybindings to thread-view-mode
   9424 	to archive/delete current thread
   9425 Message-ID: <1251325542-sup-3105@yoom.home.cworth.org>
   9426 
   9427 These behave identically to the existing ",a" and ",d" commands, (that
   9428 is they archive or delete the current thread and then view the next).
   9429 ---
   9430 
   9431 I appreciate that within thread-view-mode, sup already supports
   9432 explicitly selecting one of three different actions for what do after
   9433 the user is done with a thread. And the choice is determined by one of
   9434 three different prefix characters. For example:
   9435 
   9436     . -> return to previous buffer (likely something like
   9437          inbox-mode/search-result-mode)
   9438     , -> advance to next thread (into thread-view-mode)
   9439     ] -> advance to previous thread (into thread-view-mode)
   9440 
   9441 I'm lazy enough to want a single-character command for efficient
   9442 processing of mail in thread-view-mode, (just like I already have
   9443 while in inbox-mode and search-results-mode). And for two of the
   9444 different actions, (archive and delete), the obvious/consistent
   9445 keybinding is available. So this patch assigns those, ('a' as a
   9446 shortcut for ',a' and 'd' as a shortcut for ',d').
   9447 
   9448 If I seem too lazy here, and it doesn't seem sane to add these
   9449 keybindingd by default, just let me know. In that case I'll consign
   9450 myself to just using a hook to setup these keybindings for myself
   9451 personally.
   9452 
   9453 The perhaps-not-as-obvious piece is what the exit action should be for
   9454 these shortcut commands. For my own use, I've found it best to advance
   9455 to the next thread. (This supports a workflow where there's one pass
   9456 through the inbox to archive as much as possible without reading, and
   9457 then another pass through thread-view-mode for everything that's
   9458 left.)
   9459 
   9460 One thing this patch doesn't provide is shortcuts for the other three
   9461 exit actions, (',s' for mark-as-spam-then-next, ',N' for
   9462 mark-as-unread-then-next, and ',n' for simply advancing to the next
   9463 thread without changing the current thread).
   9464 
   9465 Of those, the only one I really care about personally is ',n'. It's
   9466 obviously not a simple matter of just making 'n' a shortcut for ',n'
   9467 since the 'n' keybinding is already used. But actually, I think I
   9468 would like the 'n' keybinding to advance to the next thread once I'm
   9469 viewing the last open message in the current thread. This would make
   9470 for very efficient sessions of just reading mail, where I'd only need
   9471 to keep hitting 'n', (and I could hit 'a' whenever bored with any
   9472 particular thread). So perhaps I'll look into coding that up next.
   9473 
   9474  lib/sup/modes/thread-view-mode.rb |    3 +++
   9475  1 files changed, 3 insertions(+), 0 deletions(-)
   9476 
   9477 diff --git a/lib/sup/modes/thread-view-mode.rb b/lib/sup/modes/thread-view-mode.rb
   9478 index 678b841..0706757 100644
   9479 --- a/lib/sup/modes/thread-view-mode.rb
   9480 +++ b/lib/sup/modes/thread-view-mode.rb
   9481 @@ -64,6 +64,9 @@ EOS
   9482      k.add :unsubscribe_from_list, "Subscribe to/unsubscribe from mailing list", ")"
   9483      k.add :pipe_message, "Pipe message or attachment to a shell command", '|'
   9484  
   9485 +    k.add :archive_and_next, "Archive this thread, kill buffer, and view next", 'a'
   9486 +    k.add :delete_and_next, "Delete this thread, kill buffer, and view next", 'd'
   9487 +
   9488      k.add_multi "(a)rchive/(d)elete/mark as (s)pam/mark as u(N)read:", '.' do |kk|
   9489        kk.add :archive_and_kill, "Archive this thread and kill buffer", 'a'
   9490        kk.add :delete_and_kill, "Delete this thread and kill buffer", 'd'
   9491 -- 
   9492 1.6.3.3
   9493 -------------- next part --------------
   9494 A non-text attachment was scrubbed...
   9495 Name: signature.asc
   9496 Type: application/pgp-signature
   9497 Size: 189 bytes
   9498 Desc: not available
   9499 URL: <http://rubyforge.org/pipermail/sup-talk/attachments/20090826/ac261bb3/attachment.bin>
   9500 
   9501 From cworth@cworth.org  Wed Aug 26 18:47:54 2009
   9502 From: cworth@cworth.org (Carl Worth)
   9503 Date: Wed, 26 Aug 2009 15:47:54 -0700
   9504 Subject: [sup-talk] Should '/' trigger the loading of more messages?
   9505 Message-ID: <1251326494-sup-2328@yoom.home.cworth.org>
   9506 
   9507 It seems to me that the "search in current buffer" command should
   9508 automatically trigger the loading of additional messages when no
   9509 results are found so that it can continue searching.
   9510 
   9511 What just happened to me is that I *knew* my inbox contained a message
   9512 with a particular string in the subject, but I couldn't find it with
   9513 '/'. The problem was that enough new threads had arrived that the
   9514 message of interest wasn't loaded yet.
   9515 
   9516 The fact that the various ThreadIndexModes don't load all relevant
   9517 threads is just an optimization, but I don't think it should change
   9518 the semantics of a search operation. (My thread *is* still in my inbox
   9519 even if it hasn't been loaded.)
   9520 
   9521 Of course, for the feature I want to work well there needs to be an
   9522 easy way to interrupt the searching and loading if it's going on too
   9523 long, (say, I mistyped the search string and I know it's likely to
   9524 load a million messages without ever finding the string I typed).
   9525 
   9526 Does sup already have a notion like emacs' "C-g" which is used to
   9527 cancel or interrupt any ongoing command?
   9528 
   9529 -Carl
   9530 -------------- next part --------------
   9531 A non-text attachment was scrubbed...
   9532 Name: signature.asc
   9533 Type: application/pgp-signature
   9534 Size: 189 bytes
   9535 Desc: not available
   9536 URL: <http://rubyforge.org/pipermail/sup-talk/attachments/20090826/5445e913/attachment.bin>
   9537 
   9538 From cworth@cworth.org  Wed Aug 26 18:52:38 2009
   9539 From: cworth@cworth.org (Carl Worth)
   9540 Date: Wed, 26 Aug 2009 15:52:38 -0700
   9541 Subject: [sup-talk] On making inbox-mode and search-results-mode more
   9542 	similar
   9543 In-Reply-To: <1251323747-sup-1595@yoom.home.cworth.org>
   9544 References: <1251323747-sup-1595@yoom.home.cworth.org>
   9545 Message-ID: <1251327030-sup-7342@yoom.home.cworth.org>
   9546 
   9547 Excerpts from Carl Worth's message of Wed Aug 26 15:24:36 -0700 2009:
   9548 > +    text = BufferManager.ask :search, "refine query: ", "label:inbox
   9549 > -label:spam -label:deleted -label:killed "
   9550 
   9551 Is that even the right syntax for searching for threads with the inbox
   9552 label but excluding threades with the spam, deleted, or killed labels?
   9553 
   9554 I took a guess at the syntax and I thought I saw it working, but it
   9555 doesn't appear to be now. Can someone tell me the actual syntax? (Or
   9556 better, is there a writeup somewhere of the general search syntax
   9557 accepted by sup?)
   9558 
   9559 -Carl
   9560 -------------- next part --------------
   9561 A non-text attachment was scrubbed...
   9562 Name: signature.asc
   9563 Type: application/pgp-signature
   9564 Size: 189 bytes
   9565 Desc: not available
   9566 URL: <http://rubyforge.org/pipermail/sup-talk/attachments/20090826/c0c5ef5d/attachment.bin>
   9567 
   9568 From ingmar@exherbo.org  Wed Aug 26 22:37:57 2009
   9569 From: ingmar@exherbo.org (Ingmar Vanhassel)
   9570 Date: Thu, 27 Aug 2009 04:37:57 +0200
   9571 Subject: [sup-talk] Should '/' trigger the loading of more messages?
   9572 In-Reply-To: <1251326494-sup-2328@yoom.home.cworth.org>
   9573 References: <1251326494-sup-2328@yoom.home.cworth.org>
   9574 Message-ID: <1251340454-sup-3773@cannonball>
   9575 
   9576 Excerpts from Carl Worth's message of Thu Aug 27 00:47:54 +0200 2009:
   9577 > It seems to me that the "search in current buffer" command should
   9578 > automatically trigger the loading of additional messages when no
   9579 > results are found so that it can continue searching.
   9580 
   9581 I'd expect a "search in current buffer" to do exactly that, no more no
   9582 less.
   9583 
   9584 > What just happened to me is that I *knew* my inbox contained a message
   9585 > with a particular string in the subject, but I couldn't find it with
   9586 > '/'. The problem was that enough new threads had arrived that the
   9587 > message of interest wasn't loaded yet.
   9588 
   9589 If you know it's in your inbox, why not search with '\', for
   9590 'label:inbox foo'?
   9591 
   9592 > The fact that the various ThreadIndexModes don't load all relevant
   9593 > threads is just an optimization, but I don't think it should change
   9594 > the semantics of a search operation. (My thread *is* still in my inbox
   9595 > even if it hasn't been loaded.)
   9596 > 
   9597 > Of course, for the feature I want to work well there needs to be an
   9598 > easy way to interrupt the searching and loading if it's going on too
   9599 > long, (say, I mistyped the search string and I know it's likely to
   9600 > load a million messages without ever finding the string I typed).
   9601 > 
   9602 > Does sup already have a notion like emacs' "C-g" which is used to
   9603 > cancel or interrupt any ongoing command?
   9604 
   9605 Try C-g. :-)
   9606 (Documented as ^G on the help page)
   9607 
   9608 > -Carl
   9609 -- 
   9610 Exherbo KDE, X.org maintainer
   9611 
   9612 From ingmar@exherbo.org  Wed Aug 26 22:54:36 2009
   9613 From: ingmar@exherbo.org (Ingmar Vanhassel)
   9614 Date: Thu, 27 Aug 2009 04:54:36 +0200
   9615 Subject: [sup-talk] [PATCH 2/2] ui responsiveness tweaks
   9616 In-Reply-To: <1251318620-sup-3031@yoom.home.cworth.org>
   9617 References: <1251053171-11450-1-git-send-email-rlane@club.cc.cmu.edu>
   9618 	<1251053171-11450-2-git-send-email-rlane@club.cc.cmu.edu>
   9619 	<1251318620-sup-3031@yoom.home.cworth.org>
   9620 Message-ID: <1251341498-sup-428@cannonball>
   9621 
   9622 Excerpts from Carl Worth's message of Wed Aug 26 23:15:36 +0200 2009:
   9623 > My message here really has nothing to do with Rich's patches
   9624 > specifically, (so sorry about that), but his patches happened to
   9625 > provide the perfect context for an issue I wanted to bring up. As is
   9626 > typical of git-formatted patches, Rich's emails have subject lines
   9627 > from his commit messages:
   9628 > 
   9629 >     [sup-talk] [PATCH 1/2] preemptively load messages when scrolling
   9630 >     [sup-talk] [PATCH 2/2] ui responsiveness tweaks
   9631 > 
   9632 > As far as the git commits go, this subject line is one of the most
   9633 > essential pieces of metadata to accompany the patch. Yet by default
   9634 > sup doesn't display it at all, (requiring keypresses to display the
   9635 > header and find the subject line). I think what I would like is for
   9636 > sup to display the subject line everytime it changes significantly in
   9637 > a thread, (specifically not regarding things like an initial "Re: "
   9638 > getting added as significant).
   9639 > 
   9640 > I think I'd be willing to spend an entire line's worth of screen real
   9641 > estate for this information---it's quite useful when people do
   9642 > meaningful subject changes for sub-threads.
   9643 
   9644 Yeah, I completely agree. That would make sup even better for me.
   9645 
   9646 Maybe this could be implemented as a 3-way toggle, toggling between
   9647   - don't show subjects (current default?)
   9648   - only show interesting subject changes
   9649   - always show subject
   9650 in a threadview.
   9651 
   9652 -Ingmar
   9653 -- 
   9654 Exherbo KDE, X.org maintainer
   9655 
   9656 From rlane@club.cc.cmu.edu  Thu Aug 27 02:50:29 2009
   9657 From: rlane@club.cc.cmu.edu (Rich Lane)
   9658 Date: Thu, 27 Aug 2009 02:50:29 -0400
   9659 Subject: [sup-talk] On making inbox-mode and search-results-mode more
   9660 	similar
   9661 In-Reply-To: <1251323747-sup-1595@yoom.home.cworth.org>
   9662 References: <1251323747-sup-1595@yoom.home.cworth.org>
   9663 Message-ID: <1251341286-sup-9400@zyrg.net>
   9664 
   9665 Excerpts from Carl Worth's message of Wed Aug 26 18:24:36 -0400 2009:
   9666 > So what I want is for anytime a message is changed such that it no
   9667 > longer meets the current search criteria, it is immediately removed
   9668 > from the search results. I think that means simply implementing the
   9669 > is_relevant? method for SearcResultsMode where there is currently just
   9670 > the following comment:
   9671 > 
   9672 >   ## a proper is_relevant? method requires some way of asking ferret
   9673 >   ## if an in-memory object satisfies a query. i'm not sure how to do
   9674 >   ## that yet. in the worst case i can make an in-memory index, add
   9675 >   ## the message, and search against it to see if i have > 0 results,
   9676 >   ## but that seems pretty insane.
   9677 > 
   9678 > That single-message index and search sounds exactly like what I want,
   9679 > and not insane at all. Has someone attempted this and found a
   9680 > performance issue? (In which case, I would think we just need to fix
   9681 > that performance bug.) Or is it simply a matter of nobody having tried
   9682 > to code this up yet? (In which case, I'll try, and I'll be glad for
   9683 > any pointers that anyone can give me on how to go about creating an
   9684 > in-memory index and searching on it.)
   9685 
   9686 We had a thread a while back about applying label changes immediately
   9687 and I think the consensus was that that's a good idea. Doing this could
   9688 simplify a great deal of thread-index-mode code because a fast
   9689 is_relevant? could be implemented using existing index operations
   9690 without the special cases for archiving/etc and without creating an
   9691 inmemory database. I have a patch I plan to mail out soon that makes
   9692 changing labels with Xapian much quicker, so that should help. It'd be
   9693 great if you decide to tackle this.
   9694 
   9695 From marcus-sup@bar-coded.net  Thu Aug 27 05:05:13 2009
   9696 From: marcus-sup@bar-coded.net (Marcus Williams)
   9697 Date: Thu, 27 Aug 2009 10:05:13 +0100
   9698 Subject: [sup-talk] Should '/' trigger the loading of more messages?
   9699 In-Reply-To: <1251340454-sup-3773@cannonball>
   9700 References: <1251326494-sup-2328@yoom.home.cworth.org>
   9701 	<1251340454-sup-3773@cannonball>
   9702 Message-ID: <1251363903-sup-2197@bar-coded.net>
   9703 
   9704 On 27.8.2009, Ingmar Vanhassel wrote:
   9705 > > What just happened to me is that I *knew* my inbox contained a message
   9706 > > with a particular string in the subject, but I couldn't find it with
   9707 > > '/'. The problem was that enough new threads had arrived that the
   9708 > > message of interest wasn't loaded yet.
   9709 > 
   9710 > If you know it's in your inbox, why not search with '\', for
   9711 > 'label:inbox foo'?
   9712 
   9713 ... coupled with '!!' to load all threads in the search (ctrl-g works
   9714 to stop search) this would do what you want.
   9715 
   9716 HTH
   9717 
   9718 Marcus
   9719 
   9720 From cworth@cworth.org  Thu Aug 27 08:17:12 2009
   9721 From: cworth@cworth.org (Carl Worth)
   9722 Date: Thu, 27 Aug 2009 05:17:12 -0700
   9723 Subject: [sup-talk] Should '/' trigger the loading of more messages?
   9724 In-Reply-To: <1251340454-sup-3773@cannonball>
   9725 References: <1251326494-sup-2328@yoom.home.cworth.org>
   9726 	<1251340454-sup-3773@cannonball>
   9727 Message-ID: <1251375048-sup-403@yoom.home.cworth.org>
   9728 
   9729 Excerpts from Ingmar Vanhassel's message of Wed Aug 26 19:37:57 -0700 2009:
   9730 > Excerpts from Carl Worth's message of Thu Aug 27 00:47:54 +0200 2009:
   9731 > > It seems to me that the "search in current buffer" command should
   9732 > > automatically trigger the loading of additional messages when no
   9733 > > results are found so that it can continue searching.
   9734 > 
   9735 > I'd expect a "search in current buffer" to do exactly that, no more no
   9736 > less.
   9737 
   9738 You obviously know well what the current buffer is doing,
   9739 (incrementally loading threads only as you page down to them). But I
   9740 don't think it's reasonable to expect all users to understand things
   9741 that well in order to use sup correctly.
   9742 
   9743 Imagine the near future where we get the thread-loading performance
   9744 bugs all worked out, (see nearby threads making good progress). If a
   9745 user starts sup and sees a screenful of threads instantly, hits page
   9746 down a couple of times and sees another couple of screensful
   9747 instantly, then wouldn't it be reasonable for such a user to expect
   9748 that all of that instantly-appearing content does exist in the current
   9749 buffer?
   9750 
   9751 > If you know it's in your inbox, why not search with '\', for
   9752 > 'label:inbox foo'?
   9753 
   9754 I'm searching locally, because I already performed a global search and
   9755 don't want to repeat the terms of it. Or else why does sup have a
   9756 local search command independent of the global search?
   9757 
   9758 > Try C-g. :-)
   9759 > (Documented as ^G on the help page)
   9760 
   9761 Ah, thanks. Now this one was just me being stupid. (I think I was
   9762 already using this in sup naturally.)
   9763 
   9764 -Carl
   9765 -------------- next part --------------
   9766 A non-text attachment was scrubbed...
   9767 Name: signature.asc
   9768 Type: application/pgp-signature
   9769 Size: 189 bytes
   9770 Desc: not available
   9771 URL: <http://rubyforge.org/pipermail/sup-talk/attachments/20090827/cb5aaa58/attachment.bin>
   9772 
   9773 From guillaume.quintard@gmail.com  Thu Aug 27 08:18:53 2009
   9774 From: guillaume.quintard@gmail.com (Guillaume Quintard)
   9775 Date: Thu, 27 Aug 2009 14:18:53 +0200
   9776 Subject: [sup-talk] Nobody told me
   9777 Message-ID: <1e5fdab70908270518k3f349191jb5e780e0e0555461@mail.gmail.com>
   9778 
   9779 Playing the dumb newbie here, but when did that happened?
   9780 
   9781 ./lib/sup/xapian_index.rb:32:in `load_index': This Sup version expects
   9782 a v1 index, but you have an existing v0 index. Please downgrade to
   9783 your previous version and dump your labels before upgrading to this
   9784 version (then run sup-sync --restore). (RuntimeError)
   9785         from ./lib/sup/index.rb:67:in `load'
   9786         from bin/sup-sync:117
   9787 
   9788 -- 
   9789 Guillaume
   9790 
   9791 From ezyang@MIT.EDU  Thu Aug 27 11:36:28 2009
   9792 From: ezyang@MIT.EDU (Edward Z. Yang)
   9793 Date: Thu, 27 Aug 2009 11:36:28 -0400
   9794 Subject: [sup-talk] Ignore killed messages in U screen
   9795 Message-ID: <1251387376-sup-7180@javelin>
   9796 
   9797 >From e01820e5914c4fb8deb5836473aa37553e5a6234 Mon Sep 17 00:00:00 2001
   9798 From: Edward Z. Yang <ezyang at mit.edu>
   9799 Date: Wed, 26 Aug 2009 10:45:26 -0400
   9800 Subject: [PATCH] Do not display killed messages in unread screen.
   9801 
   9802 Signed-off-by: Edward Z. Yang <ezyang at mit.edu>
   9803 ---
   9804  bin/sup |    2 +-
   9805  1 files changed, 1 insertions(+), 1 deletions(-)
   9806 
   9807 diff --git a/bin/sup b/bin/sup
   9808 index bbb6c17..645a9a1 100755
   9809 --- a/bin/sup
   9810 +++ b/bin/sup
   9811 @@ -263,7 +263,7 @@ begin
   9812        next unless query && query !~ /^\s*$/
   9813        SearchResultsMode.spawn_from_query query
   9814      when :search_unread
   9815 -      SearchResultsMode.spawn_from_query "is:unread"
   9816 +      SearchResultsMode.spawn_from_query "is:unread !label:killed"
   9817      when :list_labels
   9818        labels = LabelManager.all_labels.map { |l| LabelManager.string_for l }
   9819        user_label = bm.ask_with_completions :label, "Show threads with label (enter for listing): ", labels
   9820 -- 
   9821 1.6.4
   9822 
   9823 From bwalton@artsci.utoronto.ca  Thu Aug 27 11:50:08 2009
   9824 From: bwalton@artsci.utoronto.ca (Ben Walton)
   9825 Date: Thu, 27 Aug 2009 11:50:08 -0400
   9826 Subject: [sup-talk] Ignore killed messages in U screen
   9827 In-Reply-To: <1251387376-sup-7180@javelin>
   9828 References: <1251387376-sup-7180@javelin>
   9829 Message-ID: <1251388133-sup-2253@ntdws12.chass.utoronto.ca>
   9830 
   9831 Excerpts from Edward Z. Yang's message of Thu Aug 27 11:36:28 -0400 2009:
   9832 > Subject: [PATCH] Do not display killed messages in unread screen.
   9833 
   9834 +1 for this.
   9835 -Ben
   9836 -- 
   9837 Ben Walton
   9838 Systems Programmer - CHASS
   9839 University of Toronto
   9840 C:416.407.5610 | W:416.978.4302
   9841 
   9842 GPG Key Id: 8E89F6D2; Key Server: pgp.mit.edu
   9843 Contact me to arrange for a CAcert assurance meeting.
   9844 -------------- next part --------------
   9845 A non-text attachment was scrubbed...
   9846 Name: signature.asc
   9847 Type: application/pgp-signature
   9848 Size: 189 bytes
   9849 Desc: not available
   9850 URL: <http://rubyforge.org/pipermail/sup-talk/attachments/20090827/95eba3ab/attachment.bin>
   9851 
   9852 From ezyang@MIT.EDU  Thu Aug 27 11:56:32 2009
   9853 From: ezyang@MIT.EDU (Edward Z. Yang)
   9854 Date: Thu, 27 Aug 2009 11:56:32 -0400
   9855 Subject: [sup-talk] Ignore killed messages in U screen
   9856 In-Reply-To: <1251387376-sup-7180@javelin>
   9857 References: <1251387376-sup-7180@javelin>
   9858 Message-ID: <1251388546-sup-7744@javelin>
   9859 
   9860 Excerpts from Edward Z. Yang's message of Thu Aug 27 11:36:28 -0400 2009:
   9861 > -      SearchResultsMode.spawn_from_query "is:unread"
   9862 > +      SearchResultsMode.spawn_from_query "is:unread !label:killed"
   9863 
   9864 I might have one legitimate objection to this patch, which is
   9865 that searches should ignore killed tags unless explicitly told
   9866 not to.
   9867 
   9868 Cheers,
   9869 Edward
   9870 
   9871 From joe@joeshaw.org  Thu Aug 27 15:44:02 2009
   9872 From: joe@joeshaw.org (Joe Shaw)
   9873 Date: Thu, 27 Aug 2009 15:44:02 -0400
   9874 Subject: [sup-talk] sent and draft sources
   9875 Message-ID: <f8203010908271244p1d296d9dw3d2d989b6d48a2ee@mail.gmail.com>
   9876 
   9877 Hi,
   9878 
   9879 I'd like to use existing maildir folders I have for Sup's sent and
   9880 draft folders, but I couldn't find a way how.  Is this possible?  I am
   9881 surprised this is not a FAQ. :)
   9882 
   9883 Apologies for the total noob question.  I'm liking what I see in Sup so far.
   9884 
   9885 Thanks,
   9886 Joe
   9887 
   9888 From bwalton@artsci.utoronto.ca  Thu Aug 27 15:49:17 2009
   9889 From: bwalton@artsci.utoronto.ca (Ben Walton)
   9890 Date: Thu, 27 Aug 2009 15:49:17 -0400
   9891 Subject: [sup-talk] sent and draft sources
   9892 In-Reply-To: <f8203010908271244p1d296d9dw3d2d989b6d48a2ee@mail.gmail.com>
   9893 References: <f8203010908271244p1d296d9dw3d2d989b6d48a2ee@mail.gmail.com>
   9894 Message-ID: <1251402318-sup-4655@ntdws12.chass.utoronto.ca>
   9895 
   9896 Excerpts from Joe Shaw's message of Thu Aug 27 15:44:02 -0400 2009:
   9897 > I'd like to use existing maildir folders I have for Sup's sent and
   9898 > draft folders, but I couldn't find a way how.  Is this possible?  I am
   9899 > surprised this is not a FAQ. :)
   9900 
   9901 For sent, yes.  For drafts, not yet.  Using sup-config you can select
   9902 the sent source, or you could edit config.yaml by hand.  The line in
   9903 my config is this:
   9904 
   9905 :sent_source: maildir:///u/bwalton/Maildir/.sent-mail/
   9906 
   9907 I defined a source with that URI and then set the value in
   9908 config.yaml.  My outbound mail is then stored in that Maildir folder.
   9909 Only some sources work for mail storage.  These are mbox, Maildir and
   9910 IMAP.  I'd advise against having anything else write to the same mbox
   9911 (eg: don't have new mail delivered to the same source) if you go with
   9912 an mbox URI.
   9913 
   9914 I'm not sure whether the official release includes this functionality
   9915 yet or not as I run from git:next.  I _think_ 0.8.1 included it, but
   9916 would have to actually check.
   9917 
   9918 HTH
   9919 -Ben
   9920 -- 
   9921 Ben Walton
   9922 Systems Programmer - CHASS
   9923 University of Toronto
   9924 C:416.407.5610 | W:416.978.4302
   9925 
   9926 GPG Key Id: 8E89F6D2; Key Server: pgp.mit.edu
   9927 Contact me to arrange for a CAcert assurance meeting.
   9928 -------------- next part --------------
   9929 A non-text attachment was scrubbed...
   9930 Name: signature.asc
   9931 Type: application/pgp-signature
   9932 Size: 189 bytes
   9933 Desc: not available
   9934 URL: <http://rubyforge.org/pipermail/sup-talk/attachments/20090827/f78fafa2/attachment.bin>
   9935 
   9936 From joe@joeshaw.org  Thu Aug 27 15:58:29 2009
   9937 From: joe@joeshaw.org (Joe Shaw)
   9938 Date: Thu, 27 Aug 2009 15:58:29 -0400
   9939 Subject: [sup-talk] sent and draft sources
   9940 In-Reply-To: <1251402318-sup-4655@ntdws12.chass.utoronto.ca>
   9941 References: <f8203010908271244p1d296d9dw3d2d989b6d48a2ee@mail.gmail.com>
   9942 	<1251402318-sup-4655@ntdws12.chass.utoronto.ca>
   9943 Message-ID: <f8203010908271258m32cbaacfked4ec80969ce3034@mail.gmail.com>
   9944 
   9945 Hi,
   9946 
   9947 Thanks for the info.
   9948 
   9949 On Thu, Aug 27, 2009 at 3:49 PM, Ben Walton<bwalton at artsci.utoronto.ca> wrote:
   9950 > I'm not sure whether the official release includes this functionality
   9951 > yet or not as I run from git:next. ?I _think_ 0.8.1 included it, but
   9952 > would have to actually check.
   9953 
   9954 It doesn't appear to.  At least, setting sup-config didn't give me any
   9955 option to, and setting it in my config.yaml didn't seem to work
   9956 either.
   9957 
   9958 How safe is building and running from git master?  Is there a general
   9959 philosophy about its stability?  I'm a hacker, but I'm not strong in
   9960 Ruby and I am not sure yet that I want to hack on my mailer. ;)
   9961 
   9962 Joe
   9963 
   9964 From sean.escriva@gmail.com  Thu Aug 27 16:03:17 2009
   9965 From: sean.escriva@gmail.com (Sean Escriva)
   9966 Date: Thu, 27 Aug 2009 13:03:17 -0700
   9967 Subject: [sup-talk] sup crashed: NoMethodError
   9968 Message-ID: <20090827200317.GA3065@gmail.com>
   9969 
   9970 I broke my sup!
   9971 
   9972 I wanted to play with the git version so I did: 
   9973 
   9974     git pull, rake gem, gem install pkg/sup-999.gem
   9975 
   9976 well that broke it all, and I don't know how to fix it.
   9977 
   9978 so far I have tried a gem cleanup, gem uninstall sup, gem install -r
   9979 sup, all to no avail. It still always crashes with the following:
   9980 
   9981 --- NoMethodError from thread: main
   9982 undefined method `[]' for false:FalseClass
   9983 /usr/lib/ruby/gems/1.8/gems/sup-0.8.1/lib/sup.rb:107:in `start'
   9984 /usr/lib/ruby/gems/1.8/gems/sup-0.8.1/bin/sup:161
   9985 /usr/bin/sup:19:in `load'
   9986 /usr/bin/sup:19
   9987 
   9988 Any tips on how to fix/figure out what I did wrong are greatly
   9989 appreciated!
   9990 
   9991 -sme
   9992 
   9993 From dato@net.com.org.es  Thu Aug 27 16:00:53 2009
   9994 From: dato@net.com.org.es (Adeodato =?utf-8?B?U2ltw7M=?=)
   9995 Date: Thu, 27 Aug 2009 21:00:53 +0100
   9996 Subject: [sup-talk] sent and draft sources
   9997 In-Reply-To: <1251402318-sup-4655@ntdws12.chass.utoronto.ca>
   9998 References: <f8203010908271244p1d296d9dw3d2d989b6d48a2ee@mail.gmail.com>
   9999 	<1251402318-sup-4655@ntdws12.chass.utoronto.ca>
  10000 Message-ID: <20090827200053.GA17416@chistera.yi.org>
  10001 
  10002 + Ben Walton (Thu, 27 Aug 2009 15:49:17 -0400):
  10003 
  10004 > For sent, yes.  For drafts, not yet.  Using sup-config you can select
  10005 > the sent source, or you could edit config.yaml by hand.  The line in
  10006 > my config is this:
  10007 
  10008 > :sent_source: maildir:///u/bwalton/Maildir/.sent-mail/
  10009 
  10010 I tried that, but then all messages got tagged "sent", even old ones and
  10011 threads in which I didn't participate.
  10012 
  10013 > I'd advise against having anything else write to the same mbox
  10014 > (eg: don't have new mail delivered to the same source) if you go with
  10015 > an mbox URI.
  10016 
  10017 Why? Would sup not lock the mbox properly?
  10018 
  10019 Thanks,
  10020 
  10021 -- 
  10022 - Are you sure we're good?
  10023 - Always.
  10024         -- Rory and Lorelai
  10025 
  10026 
  10027 From bwalton@artsci.utoronto.ca  Thu Aug 27 19:39:20 2009
  10028 From: bwalton@artsci.utoronto.ca (Ben Walton)
  10029 Date: Thu, 27 Aug 2009 19:39:20 -0400
  10030 Subject: [sup-talk] sent and draft sources
  10031 In-Reply-To: <20090827200053.GA17416@chistera.yi.org>
  10032 References: <f8203010908271244p1d296d9dw3d2d989b6d48a2ee@mail.gmail.com>
  10033 	<1251402318-sup-4655@ntdws12.chass.utoronto.ca>
  10034 	<20090827200053.GA17416@chistera.yi.org>
  10035 Message-ID: <1251416206-sup-4808@ntdws12.chass.utoronto.ca>
  10036 
  10037 Excerpts from Adeodato Sim?'s message of Thu Aug 27 16:00:53 -0400 2009:
  10038 > > I'd advise against having anything else write to the same mbox
  10039 > > (eg: don't have new mail delivered to the same source) if you go with
  10040 > > an mbox URI.
  10041 > 
  10042 > Why? Would sup not lock the mbox properly?
  10043 
  10044 No, it wouldn't.  I've got a half-baked LockManager branch sitting
  10045 around, but I haven't touched it for some time now.  I don't use any
  10046 mbox here myself so it's not a personal itch.
  10047 
  10048 As it stands, the LockManager code has the basic ability to do
  10049 locking using three lock types.  I haven't worked out the nicest way
  10050 to stack them (ala dovecot) though in a way that will play nicely with
  10051 threads _and_ allow for non-block-wrapped calling.
  10052 
  10053 Thanks
  10054 -Ben
  10055 
  10056 -- 
  10057 Ben Walton
  10058 Systems Programmer - CHASS
  10059 University of Toronto
  10060 C:416.407.5610 | W:416.978.4302
  10061 
  10062 GPG Key Id: 8E89F6D2; Key Server: pgp.mit.edu
  10063 Contact me to arrange for a CAcert assurance meeting.
  10064 -------------- next part --------------
  10065 A non-text attachment was scrubbed...
  10066 Name: signature.asc
  10067 Type: application/pgp-signature
  10068 Size: 189 bytes
  10069 Desc: not available
  10070 URL: <http://rubyforge.org/pipermail/sup-talk/attachments/20090827/28664d43/attachment.bin>
  10071 
  10072 From bwalton@artsci.utoronto.ca  Thu Aug 27 20:43:56 2009
  10073 From: bwalton@artsci.utoronto.ca (Ben Walton)
  10074 Date: Thu, 27 Aug 2009 20:43:56 -0400
  10075 Subject: [sup-talk] sent and draft sources
  10076 In-Reply-To: <20090827200053.GA17416@chistera.yi.org>
  10077 References: <f8203010908271244p1d296d9dw3d2d989b6d48a2ee@mail.gmail.com>
  10078 	<1251402318-sup-4655@ntdws12.chass.utoronto.ca>
  10079 	<20090827200053.GA17416@chistera.yi.org>
  10080 Message-ID: <1251420193-sup-4823@ntdws12.chass.utoronto.ca>
  10081 
  10082 Excerpts from Adeodato Sim?'s message of Thu Aug 27 16:00:53 -0400 2009:
  10083 
  10084 > > :sent_source: maildir:///u/bwalton/Maildir/.sent-mail/
  10085 > 
  10086 > I tried that, but then all messages got tagged "sent", even old ones and
  10087 > threads in which I didn't participate.
  10088 
  10089 This is interesting.  It might have happened to me too, but since all
  10090 of the mail in that folder was historically sent, I either didn't
  10091 notice (since it was already archived) or this is a new issue.
  10092 
  10093 -Ben
  10094 -- 
  10095 Ben Walton
  10096 Systems Programmer - CHASS
  10097 University of Toronto
  10098 C:416.407.5610 | W:416.978.4302
  10099 
  10100 GPG Key Id: 8E89F6D2; Key Server: pgp.mit.edu
  10101 Contact me to arrange for a CAcert assurance meeting.
  10102 -------------- next part --------------
  10103 A non-text attachment was scrubbed...
  10104 Name: signature.asc
  10105 Type: application/pgp-signature
  10106 Size: 189 bytes
  10107 Desc: not available
  10108 URL: <http://rubyforge.org/pipermail/sup-talk/attachments/20090827/312b5433/attachment.bin>
  10109 
  10110 From jim@gonzul.net  Thu Aug 27 22:37:48 2009
  10111 From: jim@gonzul.net (Jim Cheetham)
  10112 Date: Fri, 28 Aug 2009 14:37:48 +1200
  10113 Subject: [sup-talk] Encrypted password in configuration file
  10114 In-Reply-To: <20090824215435.182e0007@ronin.larsko.net>
  10115 References: <20090824215435.182e0007@ronin.larsko.net>
  10116 Message-ID: <f4cc59760908271937t764e61aeh7f105c7195fec1ce@mail.gmail.com>
  10117 
  10118 On Tue, Aug 25, 2009 at 8:54 AM, Lars Kotthoff<lists at larsko.org> wrote:
  10119 > Hi list,
  10120 >
  10121 > ?is it possible to store the account password encrypted in the configuration
  10122 > file?
  10123 
  10124 It's possible, but slightly pointless.
  10125 
  10126 Have a read of Eric Raymond's discussions about Fetchmail, which has
  10127 the same configuration data :-
  10128 http://www.catb.org/~esr/writings/cathedral-bazaar/cathedral-bazaar/ar01s09.html
  10129 
  10130 "Another lesson is about security by obscurity. Some fetchmail users
  10131 asked me to change the software to store passwords encrypted in the rc
  10132 file, so snoopers wouldn't be able to casually see them.
  10133 
  10134 I didn't do it, because this doesn't actually add protection. Anyone
  10135 who's acquired permissions to read your rc file will be able to run
  10136 fetchmail as you anyway?and if it's your password they're after,
  10137 they'd be able to rip the necessary decoder out of the fetchmail code
  10138 itself to get it.
  10139 
  10140 All .fetchmailrc password encryption would have done is give a false
  10141 sense of security to people who don't think very hard. The general
  10142 rule here is:
  10143 
  10144     17. A security system is only as secure as its secret. Beware of
  10145 pseudo-secrets."
  10146 
  10147 -jim
  10148 
  10149 From jim@gonzul.net  Fri Aug 28 03:07:02 2009
  10150 From: jim@gonzul.net (Jim Cheetham)
  10151 Date: Fri, 28 Aug 2009 19:07:02 +1200
  10152 Subject: [sup-talk] Encrypted password in configuration file
  10153 In-Reply-To: <20090828012502.15484x8musndy5mo@webmail.seas.upenn.edu>
  10154 References: <20090824215435.182e0007@ronin.larsko.net>
  10155 	<f4cc59760908271937t764e61aeh7f105c7195fec1ce@mail.gmail.com> 
  10156 	<20090828012502.15484x8musndy5mo@webmail.seas.upenn.edu>
  10157 Message-ID: <f4cc59760908280007i3b226f0egd063126476e6ea3d@mail.gmail.com>
  10158 
  10159 On Fri, Aug 28, 2009 at 5:25 PM, <wagnerdm at seas.upenn.edu> wrote:
  10160 > I can imagine all kinds of situations with "benevolent" attackers. ?For
  10161 > example, what about a girlfriend that pokes around your hard drive looking
  10162 > for lolcats when she's bored? ?One glance at .fetchmailrc would show it's
  10163 > not a lolcat; but that same glance could show a password that you don't
  10164 > really want her to know.
  10165 
  10166 It took over 7 years before I would even tell my wife my login
  10167 password; I've since changed it and won't share it. And I trust her
  10168 implicitly with my machine -- there is nothing on there that I'm not
  10169 happy for her to see :-)
  10170 
  10171 So, how does the putative bored girlfriend poke around your hard-drive
  10172 in the first place, in this scenario? If you are letting her use your
  10173 account and poke around your machine in the first place, how does her
  10174 seeing a password cause a problem?
  10175 
  10176 If you don't want someone to know something, don't put them is a
  10177 situation where they might find it. You shouldn't expect a program to
  10178 employ a pointless encryption/obscuration scheme just because you
  10179 don't look after your other data. You are increasing the complexity of
  10180 the code, increasing the complexity of the testing environment,
  10181 increasing the opportunity for bugs to occur (possibly causing data
  10182 loss?), and protecting against nothing.
  10183 
  10184 Now, there is an approach used by mutt that sup doesn't seem to use,
  10185 which is to prompt the user at the beginning of a session for the
  10186 various source passwords; this way they are only held in memory (and
  10187 swap files, probably). That may be a way out of the situation; as a
  10188 mail client is inherently an interactive program, there's no harm in
  10189 prompting for things missing from the config, I think.
  10190 
  10191 -jim
  10192 
  10193 From jim@gonzul.net  Fri Aug 28 05:28:28 2009
  10194 From: jim@gonzul.net (Jim Cheetham)
  10195 Date: Fri, 28 Aug 2009 21:28:28 +1200
  10196 Subject: [sup-talk] Encrypted password in configuration file
  10197 In-Reply-To: <20090828082349.61bfc91b@ronin.larsko.net>
  10198 References: <20090824215435.182e0007@ronin.larsko.net>
  10199 	<f4cc59760908271937t764e61aeh7f105c7195fec1ce@mail.gmail.com> 
  10200 	<20090828082349.61bfc91b@ronin.larsko.net>
  10201 Message-ID: <f4cc59760908280228i47bbd52dy87a5695e3a2361c0@mail.gmail.com>
  10202 
  10203 On Fri, Aug 28, 2009 at 7:23 PM, Lars Kotthoff<lars at larsko.org> wrote:
  10204 >> It's possible, but slightly pointless.
  10205 >
  10206 > Not if the user supplies the passphrase, e.g. it could be encrypted with the
  10207 > user's GPG key and ask for the passphrase at startup.
  10208 
  10209 Why not just ask for the IMAP password itself? There's no functional
  10210 difference between that secret, and the secret that unlocks the secret
  10211 ... indeed, if sup were to accidentally expose the passphrase you
  10212 provided, would you rather lose your GPG key or your IMAP key?
  10213 
  10214 If you are really determined to allow others to read your private
  10215 files, why not just encrypt the whole .sup directory with a separate
  10216 tool (TrueCrypt, loopback, rot13, encfs, ecryptfs, or whatever else
  10217 your distribution provides).
  10218 
  10219 That way, you are also protecting the ferret index collection, and the
  10220 default sent box, which all contain data of the same level of
  10221 sensitivity as your mailbox. Given your concern, I assume that you
  10222 will be remembering to terminate sup and dismount the .sup directory
  10223 every time you walk away from the keyboard.
  10224 
  10225 (Many schemes these days encrypt the whole of $HOME, which makes the
  10226 whole screensaver/away from the keyboard thing even more difficult).
  10227 
  10228 Security must be appropriate to be actual security. Otherwise it's
  10229 just an expensive fa?ade.
  10230 
  10231 -jim
  10232 
  10233 From stan@stanheckman.com  Wed Aug 26 15:59:46 2009
  10234 From: stan@stanheckman.com (Stan Heckman)
  10235 Date: Wed, 26 Aug 2009 19:59:46 +0000
  10236 Subject: [sup-talk] an error occurred in Sup
  10237 Message-ID: <1251316321-sup-8091@clover.schedar.com>
  10238 
  10239 While setting up sup I received the error below.
  10240 I attach the exception-log requested.
  10241 
  10242 I had told sup-config about my existing maildirs. This produced a large inbox.
  10243 I attempted to archive all but 15 recent messages from this inbox by loading
  10244 all messages with "!!" and archiving them all by holding down the "a" key for
  10245 several seconds.
  10246 
  10247 After several minutes of archiving, I received the error below.
  10248 
  10249 
  10250 [Wed Aug 26 19:38:08 +0000 2009] stopped cursing
  10251 [Wed Aug 26 19:38:08 +0000 2009] oh crap, an exception
  10252 [Wed Aug 26 19:38:08 +0000 2009] unlocking /home/stan/.sup/lock...
  10253 ----------------------------------------------------------------
  10254 I'm very sorry. It seems that an error occurred in Sup. Please
  10255 accept my sincere apologies. If you don't mind, please send the
  10256 contents of ~/.sup/exception-log.txt and a brief report of the
  10257 circumstances to sup-talk at rubyforge dot orgs so that I might
  10258 address this problem. Thank you!
  10259 
  10260 Sincerely,
  10261 William
  10262 ----------------------------------------------------------------
  10263 --- NoMethodError from thread: periodic poll
  10264 undefined method `+' for nil:NilClass
  10265 /home/stan/.gem/ruby/1.8/gems/sup-0.8.1/lib/sup/maildir.rb:141:in `end_offset'
  10266 /home/stan/.gem/ruby/1.8/gems/sup-0.8.1/lib/sup/source.rb:87:in `done?'
  10267 /home/stan/.gem/ruby/1.8/gems/sup-0.8.1/lib/sup/util.rb:552:in `send'
  10268 /home/stan/.gem/ruby/1.8/gems/sup-0.8.1/lib/sup/util.rb:552:in `__pass'
  10269 /home/stan/.gem/ruby/1.8/gems/sup-0.8.1/lib/sup/util.rb:539:in `method_missing'
  10270 /usr/lib/ruby/1.8/sup/poll.rb:89:in `do_poll'
  10271 /usr/lib/ruby/1.8/sup/poll.rb:86:in `each'
  10272 /usr/lib/ruby/1.8/sup/poll.rb:86:in `do_poll'
  10273 /usr/lib/ruby/1.8/sup/poll.rb:85:in `synchronize'
  10274 /usr/lib/ruby/1.8/sup/poll.rb:85:in `do_poll'
  10275 /home/stan/.gem/ruby/1.8/gems/sup-0.8.1/lib/sup/util.rb:513:in `send'
  10276 /home/stan/.gem/ruby/1.8/gems/sup-0.8.1/lib/sup/util.rb:513:in `method_missing'
  10277 /usr/lib/ruby/1.8/sup/modes/poll-mode.rb:17:in `poll'
  10278 /usr/lib/ruby/1.8/sup/poll.rb:53:in `poll'
  10279 /usr/lib/ruby/1.8/sup/poll.rb:70:in `start'
  10280 /home/stan/.gem/ruby/1.8/gems/sup-0.8.1/lib/sup.rb:71:in `reporting_thread'
  10281 /home/stan/.gem/ruby/1.8/gems/sup-0.8.1/lib/sup.rb:69:in `initialize'
  10282 /home/stan/.gem/ruby/1.8/gems/sup-0.8.1/lib/sup.rb:69:in `new'
  10283 /home/stan/.gem/ruby/1.8/gems/sup-0.8.1/lib/sup.rb:69:in `reporting_thread'
  10284 /usr/lib/ruby/1.8/sup/poll.rb:67:in `start'
  10285 /home/stan/.gem/ruby/1.8/gems/sup-0.8.1/lib/sup/util.rb:513:in `send'
  10286 /home/stan/.gem/ruby/1.8/gems/sup-0.8.1/lib/sup/util.rb:513:in `method_missing'
  10287 /home/stan/.gem/ruby/1.8/gems/sup-0.8.1/bin/sup:213
  10288 /home/stan/.gem/ruby/1.8/bin/sup:19:in `load'
  10289 /home/stan/.gem/ruby/1.8/bin/sup:19
  10290 -------------- next part --------------
  10291 An embedded and charset-unspecified text was scrubbed...
  10292 Name: exception-log.txt
  10293 URL: <http://rubyforge.org/pipermail/sup-talk/attachments/20090826/6de40820/attachment.txt>
  10294 
  10295 From lars@larsko.org  Fri Aug 28 03:23:49 2009
  10296 From: lars@larsko.org (Lars Kotthoff)
  10297 Date: Fri, 28 Aug 2009 08:23:49 +0100
  10298 Subject: [sup-talk] Encrypted password in configuration file
  10299 In-Reply-To: <f4cc59760908271937t764e61aeh7f105c7195fec1ce@mail.gmail.com>
  10300 References: <20090824215435.182e0007@ronin.larsko.net>
  10301 	<f4cc59760908271937t764e61aeh7f105c7195fec1ce@mail.gmail.com>
  10302 Message-ID: <20090828082349.61bfc91b@ronin.larsko.net>
  10303 
  10304 > It's possible, but slightly pointless.
  10305 
  10306 Not if the user supplies the passphrase, e.g. it could be encrypted with the
  10307 user's GPG key and ask for the passphrase at startup.
  10308 
  10309 Lars
  10310 
  10311 From wmorgan-sup@masanjin.net  Fri Aug 28 16:29:03 2009
  10312 From: wmorgan-sup@masanjin.net (William Morgan)
  10313 Date: Fri, 28 Aug 2009 13:29:03 -0700
  10314 Subject: [sup-talk] Encrypted password in configuration file
  10315 In-Reply-To: <20090824215435.182e0007@ronin.larsko.net>
  10316 References: <20090824215435.182e0007@ronin.larsko.net>
  10317 Message-ID: <1251491240-sup-1148@masanjin.net>
  10318 
  10319 Reformatted excerpts from Lars Kotthoff's message of 2009-08-24:
  10320 > is it possible to store the account password encrypted in the
  10321 > configuration file?
  10322 
  10323 Despite generally agreeing with Jim's argument, I'm happy to accept a
  10324 patch to do this.
  10325 -- 
  10326 William <wmorgan-sup at masanjin.net>
  10327 
  10328 From wmorgan-sup@masanjin.net  Fri Aug 28 16:31:26 2009
  10329 From: wmorgan-sup@masanjin.net (William Morgan)
  10330 Date: Fri, 28 Aug 2009 13:31:26 -0700
  10331 Subject: [sup-talk] sent and draft sources
  10332 In-Reply-To: <f8203010908271258m32cbaacfked4ec80969ce3034@mail.gmail.com>
  10333 References: <f8203010908271244p1d296d9dw3d2d989b6d48a2ee@mail.gmail.com>
  10334 	<1251402318-sup-4655@ntdws12.chass.utoronto.ca>
  10335 	<f8203010908271258m32cbaacfked4ec80969ce3034@mail.gmail.com>
  10336 Message-ID: <1251491386-sup-7354@masanjin.net>
  10337 
  10338 Reformatted excerpts from Joe Shaw's message of 2009-08-27:
  10339 > How safe is building and running from git master?
  10340 
  10341 Pretty safe. I merge all changes into next first, which is where people
  10342 see breakage, and only merge them into master when they've baked long
  10343 enough.
  10344 
  10345 > Is there a general philosophy about its stability?
  10346 
  10347 "Stability is good". :)
  10348 -- 
  10349 William <wmorgan-sup at masanjin.net>
  10350 
  10351 From wmorgan-sup@masanjin.net  Fri Aug 28 16:35:06 2009
  10352 From: wmorgan-sup@masanjin.net (William Morgan)
  10353 Date: Fri, 28 Aug 2009 13:35:06 -0700
  10354 Subject: [sup-talk] sent and draft sources
  10355 In-Reply-To: <20090827200053.GA17416@chistera.yi.org>
  10356 References: <f8203010908271244p1d296d9dw3d2d989b6d48a2ee@mail.gmail.com>
  10357 	<1251402318-sup-4655@ntdws12.chass.utoronto.ca>
  10358 	<20090827200053.GA17416@chistera.yi.org>
  10359 Message-ID: <1251491567-sup-2126@masanjin.net>
  10360 
  10361 Reformatted excerpts from Adeodato Sim?'s message of 2009-08-27:
  10362 > Why? Would sup not lock the mbox properly?
  10363 
  10364 Sup doesn't lock the sent mbox currently. It wouldn't be too hard to
  10365 add. I'm still waiting for Ben to provide a nice refactoring patch for
  10366 me. :)
  10367 -- 
  10368 William <wmorgan-sup at masanjin.net>
  10369 
  10370 From wmorgan-sup@masanjin.net  Fri Aug 28 16:37:12 2009
  10371 From: wmorgan-sup@masanjin.net (William Morgan)
  10372 Date: Fri, 28 Aug 2009 13:37:12 -0700
  10373 Subject: [sup-talk] Nobody told me
  10374 In-Reply-To: <1e5fdab70908270518k3f349191jb5e780e0e0555461@mail.gmail.com>
  10375 References: <1e5fdab70908270518k3f349191jb5e780e0e0555461@mail.gmail.com>
  10376 Message-ID: <1251491725-sup-284@masanjin.net>
  10377 
  10378 Reformatted excerpts from Guillaume Quintard's message of 2009-08-27:
  10379 > Playing the dumb newbie here, but when did that happened?
  10380 
  10381 If anyone else has this problem (and anyone who's running next with the 
  10382 Xapian index will): after the dump and before sup-sync, I believe you
  10383 need to remove your ~/.sup/xapian directory and ~/.sup/*.db. Life on the
  10384 bleeding edge!
  10385 
  10386 > ./lib/sup/xapian_index.rb:32:in `load_index': This Sup version expects
  10387 > a v1 index, but you have an existing v0 index. Please downgrade to
  10388 > your previous version and dump your labels before upgrading to this
  10389 > version (then run sup-sync --restore). (RuntimeError)
  10390 >         from ./lib/sup/index.rb:67:in `load'
  10391 >         from bin/sup-sync:117
  10392 > 
  10393 -- 
  10394 William <wmorgan-sup at masanjin.net>
  10395 
  10396 From wmorgan-sup@masanjin.net  Fri Aug 28 16:38:59 2009
  10397 From: wmorgan-sup@masanjin.net (William Morgan)
  10398 Date: Fri, 28 Aug 2009 13:38:59 -0700
  10399 Subject: [sup-talk] an error occurred in Sup
  10400 In-Reply-To: <1251316321-sup-8091@clover.schedar.com>
  10401 References: <1251316321-sup-8091@clover.schedar.com>
  10402 Message-ID: <1251491856-sup-4902@masanjin.net>
  10403 
  10404 Reformatted excerpts from Stan Heckman's message of 2009-08-26:
  10405 > I had told sup-config about my existing maildirs. This produced a
  10406 > large inbox.  I attempted to archive all but 15 recent messages from
  10407 > this inbox by loading all messages with "!!" and archiving them all by
  10408 > holding down the "a" key for several seconds.
  10409 
  10410 Definitely the slow an painful way to do this, and also the way to
  10411 trigger one of the display threading heisenbugs.
  10412 
  10413 I recommend instead using sup-tweak-labels, or starting over and using
  10414 --archive when you sup-add the source (and then just adding the inbox
  10415 label back to the first 15).
  10416 -- 
  10417 William <wmorgan-sup at masanjin.net>
  10418 
  10419 From wmorgan-sup@masanjin.net  Fri Aug 28 16:41:41 2009
  10420 From: wmorgan-sup@masanjin.net (William Morgan)
  10421 Date: Fri, 28 Aug 2009 13:41:41 -0700
  10422 Subject: [sup-talk] sup crashed: NoMethodError
  10423 In-Reply-To: <20090827200317.GA3065@gmail.com>
  10424 References: <20090827200317.GA3065@gmail.com>
  10425 Message-ID: <1251492008-sup-6128@masanjin.net>
  10426 
  10427 Reformatted excerpts from Sean Escriva's message of 2009-08-27:
  10428 > so far I have tried a gem cleanup, gem uninstall sup, gem install -r
  10429 > sup, all to no avail. It still always crashes with the following:
  10430 > 
  10431 > --- NoMethodError from thread: main
  10432 > undefined method `[]' for false:FalseClass
  10433 > /usr/lib/ruby/gems/1.8/gems/sup-0.8.1/lib/sup.rb:107:in `start'
  10434 > /usr/lib/ruby/gems/1.8/gems/sup-0.8.1/bin/sup:161
  10435 > /usr/bin/sup:19:in `load'
  10436 > /usr/bin/sup:19
  10437 > 
  10438 > Any tips on how to fix/figure out what I did wrong are greatly
  10439 > appreciated!
  10440 
  10441 Hm, is your ~/.sup/config.yaml file empty for some reason? If so, delete
  10442 it and retry, and I will add some code to catch this case.
  10443 -- 
  10444 William <wmorgan-sup at masanjin.net>
  10445 
  10446 From guillaume.quintard@gmail.com  Fri Aug 28 17:01:04 2009
  10447 From: guillaume.quintard@gmail.com (Guillaume Quintard)
  10448 Date: Fri, 28 Aug 2009 23:01:04 +0200
  10449 Subject: [sup-talk] Nobody told me
  10450 In-Reply-To: <1251491725-sup-284@masanjin.net>
  10451 References: <1e5fdab70908270518k3f349191jb5e780e0e0555461@mail.gmail.com>
  10452 	<1251491725-sup-284@masanjin.net>
  10453 Message-ID: <1e5fdab70908281401k7f0b59ectb38ce7dfe7280569@mail.gmail.com>
  10454 
  10455 On Fri, Aug 28, 2009 at 10:37 PM, William
  10456 Morgan<wmorgan-sup at masanjin.net> wrote:
  10457 
  10458 arg, when I try to restore, I get this:
  10459 ./lib/sup/crypto.rb:157:in ``': Cannot allocate memory - /usr/bin/gpg
  10460 --quiet --batch --no-verbose --logger-fd 1 --use-agent --verify
  10461 /tmp/31666-0-redwood.signature /tmp/31666-0-redwood.payload 2>
  10462 /dev/null (Errno::ENOMEM)
  10463 	from ./lib/sup/crypto.rb:157:in `run_gpg'
  10464 	from ./lib/sup/crypto.rb:92:in `verify'
  10465 	from ./lib/sup/util.rb:520:in `send'
  10466 	from ./lib/sup/util.rb:520:in `method_missing'
  10467 	from ./lib/sup/message.rb:385:in `multipart_signed_to_chunks'
  10468 	from ./lib/sup/message.rb:421:in `message_to_chunks'
  10469 	from ./lib/sup/message.rb:236:in `load_from_source!'
  10470 	from ./lib/sup/message.rb:332:in `build_from_source'
  10471 	from ./lib/sup/poll.rb:153:in `each_message_from'
  10472 	from ./lib/sup/source.rb:104:in `each'
  10473 	from ./lib/sup/util.rb:560:in `send'
  10474 	from ./lib/sup/util.rb:560:in `__pass'
  10475 	from ./lib/sup/util.rb:547:in `method_missing'
  10476 	from ./lib/sup/poll.rb:147:in `each_message_from'
  10477 	from ./lib/sup/util.rb:520:in `send'
  10478 	from ./lib/sup/util.rb:520:in `method_missing'
  10479 	from bin/sup-sync:146
  10480 	from bin/sup-sync:141:in `each'
  10481 	from bin/sup-sync:141
  10482 
  10483 is it leaking, or is my huge mbox just too big for it?
  10484 
  10485 cheers
  10486 
  10487 -- 
  10488 Guillaume
  10489 
  10490 From sean.escriva@gmail.com  Fri Aug 28 18:50:41 2009
  10491 From: sean.escriva@gmail.com (Sean Escriva)
  10492 Date: Fri, 28 Aug 2009 15:50:41 -0700
  10493 Subject: [sup-talk] sup crashed: NoMethodError
  10494 In-Reply-To: <1251492008-sup-6128@masanjin.net>
  10495 References: <20090827200317.GA3065@gmail.com>
  10496 	<1251492008-sup-6128@masanjin.net>
  10497 Message-ID: <20090828225041.GA22963@gmail.com>
  10498 
  10499 On Fri, Aug 28, 2009 at 01:41:41PM -0700, William Morgan wrote:
  10500 > Reformatted excerpts from Sean Escriva's message of 2009-08-27:
  10501 > > so far I have tried a gem cleanup, gem uninstall sup, gem install -r
  10502 > > sup, all to no avail. It still always crashes with the following:
  10503 > > 
  10504 > > --- NoMethodError from thread: main
  10505 > > undefined method `[]' for false:FalseClass
  10506 > > /usr/lib/ruby/gems/1.8/gems/sup-0.8.1/lib/sup.rb:107:in `start'
  10507 > > /usr/lib/ruby/gems/1.8/gems/sup-0.8.1/bin/sup:161
  10508 > > /usr/bin/sup:19:in `load'
  10509 > > /usr/bin/sup:19
  10510 > > 
  10511 > > Any tips on how to fix/figure out what I did wrong are greatly
  10512 > > appreciated!
  10513 > 
  10514 > Hm, is your ~/.sup/config.yaml file empty for some reason? If so, delete
  10515 > it and retry, and I will add some code to catch this case.
  10516 
  10517 That may have been it. I just clobbered my whole setup and started
  10518 over, now it's working Although now I'm using the gem and not the git
  10519 next branch. I don't want to loose my 8K+ message index again.
  10520 
  10521 was my install process wrong for switching to the git -next branch?
  10522 
  10523 -sme
  10524 
  10525 ps: i'll consider switching fully to sup as soon as I figure out how to manage
  10526 multiple email accounts :)
  10527 
  10528 From pioto@pioto.org  Fri Aug 28 18:48:59 2009
  10529 From: pioto@pioto.org (Mike Kelly)
  10530 Date: Fri, 28 Aug 2009 18:48:59 -0400
  10531 Subject: [sup-talk] Encrypted password in configuration file
  10532 In-Reply-To: <20090824215435.182e0007@ronin.larsko.net>
  10533 References: <20090824215435.182e0007@ronin.larsko.net>
  10534 Message-ID: <20090828184859.59b7f825@aether.home.pioto.org>
  10535 
  10536 On Mon, 24 Aug 2009 21:54:35 +0100
  10537 Lars Kotthoff <lists at larsko.org> wrote:
  10538 >  is it possible to store the account password encrypted in the
  10539 > configuration file?
  10540 
  10541 Along the lines of what Jim said, doing any sort of two-way encryption
  10542 on the password is a wasted effort. There are other sort of
  10543 authentication mechanisms which are probably more appropriate
  10544 (certificate-based, Kerberos/GSSAPI, ...).
  10545 
  10546 -- 
  10547 Mike Kelly
  10548 
  10549 From nicolas.pouillard@gmail.com  Sat Aug 29 05:18:52 2009
  10550 From: nicolas.pouillard@gmail.com (Nicolas Pouillard)
  10551 Date: Sat, 29 Aug 2009 11:18:52 +0200
  10552 Subject: [sup-talk] Crash while syncing
  10553 Message-ID: <cd67f63a0908290218g30a737a9pd46d902cdf5399bb@mail.gmail.com>
  10554 
  10555 Hello,
  10556 
  10557 While doing a from scratch sup-sync to benefit for the new version of
  10558 the xapian index, sup-sync
  10559 crashed like this:
  10560 
  10561 /usr/lib/ruby/site_ruby/1.8/xapian.rb:240:in `doclength':
  10562 DocNotFoundError: Document 3318104838 not found (RuntimeError)
  10563         from /usr/lib/ruby/site_ruby/1.8/xapian.rb:240:in `postlist'
  10564         from /usr/lib/ruby/site_ruby/1.8/xapian.rb:60:in `_safelyIterate'
  10565         from /usr/lib/ruby/site_ruby/1.8/xapian.rb:238:in `postlist'
  10566         from /usr/lib/ruby/gems/1.8/gems/sup-999/lib/sup/xapian_index.rb:365:in
  10567 `term_docids'
  10568         from /usr/lib/ruby/gems/1.8/gems/sup-999/lib/sup/xapian_index.rb:369:in
  10569 `find_docid'
  10570         from /usr/lib/ruby/gems/1.8/gems/sup-999/lib/sup/xapian_index.rb:373:in
  10571 `find_doc'
  10572         from /usr/lib/ruby/gems/1.8/gems/sup-999/lib/sup/xapian_index.rb:469:in
  10573 `index_message'
  10574         from /usr/lib/ruby/gems/1.8/gems/sup-999/lib/sup/xapian_index.rb:469:in
  10575 `map'
  10576         from /usr/lib/ruby/gems/1.8/gems/sup-999/lib/sup/xapian_index.rb:469:in
  10577 `index_message'
  10578         from /usr/lib/ruby/gems/1.8/gems/sup-999/lib/sup/xapian_index.rb:118:in
  10579 `sync_message'
  10580         from /usr/lib/ruby/1.8/monitor.rb:242:in `synchronize'
  10581         from /usr/lib/ruby/gems/1.8/gems/sup-999/lib/sup/xapian_index.rb:392:in
  10582 `synchronize'
  10583         from /usr/lib/ruby/gems/1.8/gems/sup-999/lib/sup/xapian_index.rb:117:in
  10584 `sync_message'
  10585         from /usr/lib/ruby/gems/1.8/gems/sup-999/lib/sup/xapian_index.rb:87:in
  10586 `add_message'
  10587         from /usr/lib/ruby/gems/1.8/gems/sup-999/bin/sup-sync:202
  10588         from /usr/lib/ruby/gems/1.8/gems/sup-999/lib/sup/poll.rb:152:in
  10589 `each_message_from'
  10590         from /usr/lib/ruby/gems/1.8/gems/sup-999/lib/sup/source.rb:104:in `each'
  10591         from /usr/lib/ruby/gems/1.8/gems/sup-999/lib/sup/util.rb:560:in `send'
  10592         from /usr/lib/ruby/gems/1.8/gems/sup-999/lib/sup/util.rb:560:in `__pass'
  10593         from /usr/lib/ruby/gems/1.8/gems/sup-999/lib/sup/util.rb:547:in
  10594 `method_missing'
  10595         from /usr/lib/ruby/gems/1.8/gems/sup-999/lib/sup/poll.rb:140:in
  10596 `each_message_from'
  10597         from /usr/lib/ruby/gems/1.8/gems/sup-999/lib/sup/util.rb:520:in `send'
  10598         from /usr/lib/ruby/gems/1.8/gems/sup-999/lib/sup/util.rb:520:in
  10599 `method_missing'
  10600         from /usr/lib/ruby/gems/1.8/gems/sup-999/bin/sup-sync:146
  10601         from /usr/lib/ruby/gems/1.8/gems/sup-999/bin/sup-sync:141:in `each'
  10602         from /usr/lib/ruby/gems/1.8/gems/sup-999/bin/sup-sync:141
  10603         from /usr/bin/sup-sync:19:in `load'
  10604         from /usr/bin/sup-sync:19
  10605 
  10606 The last status message was:
  10607 
  10608 ## read 9996m (about 30%) @ 11.1m/s. 0:15:03 elapsed, about 0:35:00 remaining
  10609 
  10610 And it was processing a 500MB mbox.
  10611 
  10612 I would like to know what are my options from here?
  10613 
  10614 Best regards,
  10615 
  10616 -- 
  10617 Nicolas Pouillard aka Ertai
  10618 
  10619 From nicolas.pouillard@gmail.com  Sat Aug 29 08:03:04 2009
  10620 From: nicolas.pouillard@gmail.com (Nicolas Pouillard)
  10621 Date: Sat, 29 Aug 2009 14:03:04 +0200
  10622 Subject: [sup-talk] Crash while syncing
  10623 In-Reply-To: <cd67f63a0908290218g30a737a9pd46d902cdf5399bb@mail.gmail.com>
  10624 References: <cd67f63a0908290218g30a737a9pd46d902cdf5399bb@mail.gmail.com>
  10625 Message-ID: <cd67f63a0908290503g37ab5575ibb6162d06f7528af@mail.gmail.com>
  10626 
  10627 On Sat, Aug 29, 2009 at 11:18 AM, Nicolas
  10628 Pouillard<nicolas.pouillard at gmail.com> wrote:
  10629 > Hello,
  10630 >
  10631 > While doing a from scratch sup-sync to benefit for the new version of
  10632 > the xapian index, sup-sync
  10633 > crashed like this:
  10634 >
  10635 
  10636 I've lauched sup-sync on another bunch of mboxes and got this crash at the end:
  10637 
  10638 Deleting missing messages from the index...
  10639 /usr/lib/ruby/gems/1.8/gems/sup-999/lib/sup.rb:17:in `id': wrong id
  10640 called on nil (RuntimeError)
  10641         from /usr/lib/ruby/gems/1.8/gems/sup-999/bin/sup-sync:237
  10642         from /usr/lib/ruby/gems/1.8/gems/sup-999/lib/sup/index.rb:150:in
  10643 `each_message'
  10644         from /usr/lib/ruby/gems/1.8/gems/sup-999/lib/sup/xapian_index.rb:141:in
  10645 `each_id'
  10646         from /usr/lib/ruby/gems/1.8/gems/sup-999/lib/sup/xapian_index.rb:141:in
  10647 `each'
  10648         from /usr/lib/ruby/gems/1.8/gems/sup-999/lib/sup/xapian_index.rb:141:in
  10649 `each_id'
  10650         from /usr/lib/ruby/gems/1.8/gems/sup-999/lib/sup/index.rb:149:in
  10651 `each_message'
  10652         from /usr/lib/ruby/gems/1.8/gems/sup-999/bin/sup-sync:235
  10653         from /usr/lib/ruby/gems/1.8/gems/sup-999/bin/sup-sync:233:in `each'
  10654         from /usr/lib/ruby/gems/1.8/gems/sup-999/bin/sup-sync:233
  10655         from /usr/bin/sup-sync:19:in `load'
  10656         from /usr/bin/sup-sync:19
  10657 
  10658 
  10659 -- 
  10660 Nicolas Pouillard aka Ertai
  10661 
  10662 From rlane@club.cc.cmu.edu  Sat Aug 29 12:25:33 2009
  10663 From: rlane@club.cc.cmu.edu (Rich Lane)
  10664 Date: Sat, 29 Aug 2009 12:25:33 -0400
  10665 Subject: [sup-talk] Crash while syncing
  10666 In-Reply-To: <cd67f63a0908290503g37ab5575ibb6162d06f7528af@mail.gmail.com>
  10667 References: <cd67f63a0908290218g30a737a9pd46d902cdf5399bb@mail.gmail.com>
  10668 	<cd67f63a0908290503g37ab5575ibb6162d06f7528af@mail.gmail.com>
  10669 Message-ID: <1251563082-sup-3525@zyrg.net>
  10670 
  10671 Excerpts from Nicolas Pouillard's message of Sat Aug 29 08:03:04 -0400 2009:
  10672 > On Sat, Aug 29, 2009 at 11:18 AM, Nicolas
  10673 > Pouillard<nicolas.pouillard at gmail.com> wrote:
  10674 > > Hello,
  10675 > >
  10676 > > While doing a from scratch sup-sync to benefit for the new version of
  10677 > > the xapian index, sup-sync
  10678 > > crashed like this:
  10679 > >
  10680 > 
  10681 > I've lauched sup-sync on another bunch of mboxes and got this crash at the end:
  10682 > 
  10683 > Deleting missing messages from the index...
  10684 > /usr/lib/ruby/gems/1.8/gems/sup-999/lib/sup.rb:17:in `id': wrong id
  10685 > called on nil (RuntimeError)
  10686 >         from /usr/lib/ruby/gems/1.8/gems/sup-999/bin/sup-sync:237
  10687 >         from /usr/lib/ruby/gems/1.8/gems/sup-999/lib/sup/index.rb:150:in
  10688 > `each_message'
  10689 >         from /usr/lib/ruby/gems/1.8/gems/sup-999/lib/sup/xapian_index.rb:141:in
  10690 > `each_id'
  10691 >         from /usr/lib/ruby/gems/1.8/gems/sup-999/lib/sup/xapian_index.rb:141:in
  10692 > `each'
  10693 >         from /usr/lib/ruby/gems/1.8/gems/sup-999/lib/sup/xapian_index.rb:141:in
  10694 > `each_id'
  10695 >         from /usr/lib/ruby/gems/1.8/gems/sup-999/lib/sup/index.rb:149:in
  10696 > `each_message'
  10697 >         from /usr/lib/ruby/gems/1.8/gems/sup-999/bin/sup-sync:235
  10698 >         from /usr/lib/ruby/gems/1.8/gems/sup-999/bin/sup-sync:233:in `each'
  10699 >         from /usr/lib/ruby/gems/1.8/gems/sup-999/bin/sup-sync:233
  10700 >         from /usr/bin/sup-sync:19:in `load'
  10701 >         from /usr/bin/sup-sync:19
  10702 > 
  10703 
  10704 Are you using the Flint or Chert Xapian backend?
  10705 
  10706 From nicolas.pouillard@gmail.com  Sat Aug 29 12:45:29 2009
  10707 From: nicolas.pouillard@gmail.com (Nicolas Pouillard)
  10708 Date: Sat, 29 Aug 2009 18:45:29 +0200
  10709 Subject: [sup-talk] Crash while syncing
  10710 In-Reply-To: <1251563082-sup-3525@zyrg.net>
  10711 References: <cd67f63a0908290218g30a737a9pd46d902cdf5399bb@mail.gmail.com>
  10712 	<cd67f63a0908290503g37ab5575ibb6162d06f7528af@mail.gmail.com>
  10713 	<1251563082-sup-3525@zyrg.net>
  10714 Message-ID: <cd67f63a0908290945j2007c75cyc56ab6c1dcfdbbb1@mail.gmail.com>
  10715 
  10716 On Sat, Aug 29, 2009 at 6:25 PM, Rich Lane<rlane at club.cc.cmu.edu> wrote:
  10717 > Excerpts from Nicolas Pouillard's message of Sat Aug 29 08:03:04 -0400 2009:
  10718 >> On Sat, Aug 29, 2009 at 11:18 AM, Nicolas Pouillard<nicolas.pouillard at gmail.com> wrote:
  10719 >> > Hello,
  10720 >> >
  10721 >> > While doing a from scratch sup-sync to benefit for the new version of
  10722 >> > the xapian index, sup-sync
  10723 >> > crashed like this:
  10724 >> >
  10725 
  10726 [...]
  10727 
  10728 > Are you using the Flint or Chert Xapian backend?
  10729 
  10730 The Chert one.
  10731 
  10732 -- 
  10733 Nicolas Pouillard aka Ertai
  10734 
  10735 From rlane@club.cc.cmu.edu  Sat Aug 29 12:59:59 2009
  10736 From: rlane@club.cc.cmu.edu (Rich Lane)
  10737 Date: Sat, 29 Aug 2009 12:59:59 -0400
  10738 Subject: [sup-talk] Crash while syncing
  10739 In-Reply-To: <cd67f63a0908290945j2007c75cyc56ab6c1dcfdbbb1@mail.gmail.com>
  10740 References: <cd67f63a0908290218g30a737a9pd46d902cdf5399bb@mail.gmail.com>
  10741 	<cd67f63a0908290503g37ab5575ibb6162d06f7528af@mail.gmail.com>
  10742 	<1251563082-sup-3525@zyrg.net>
  10743 	<cd67f63a0908290945j2007c75cyc56ab6c1dcfdbbb1@mail.gmail.com>
  10744 Message-ID: <1251564961-sup-5855@zyrg.net>
  10745 
  10746 Excerpts from Nicolas Pouillard's message of Sat Aug 29 12:45:29 -0400 2009:
  10747 > > Are you using the Flint or Chert Xapian backend?
  10748 > 
  10749 > The Chert one.
  10750 
  10751 Could you try it with Flint? I've seen this (nondeterministic) bug when
  10752 using Chert.
  10753 
  10754 From nicolas.pouillard@gmail.com  Sat Aug 29 13:05:33 2009
  10755 From: nicolas.pouillard@gmail.com (Nicolas Pouillard)
  10756 Date: Sat, 29 Aug 2009 19:05:33 +0200
  10757 Subject: [sup-talk] Crash while syncing
  10758 In-Reply-To: <1251564961-sup-5855@zyrg.net>
  10759 References: <cd67f63a0908290218g30a737a9pd46d902cdf5399bb@mail.gmail.com>
  10760 	<cd67f63a0908290503g37ab5575ibb6162d06f7528af@mail.gmail.com>
  10761 	<1251563082-sup-3525@zyrg.net>
  10762 	<cd67f63a0908290945j2007c75cyc56ab6c1dcfdbbb1@mail.gmail.com>
  10763 	<1251564961-sup-5855@zyrg.net>
  10764 Message-ID: <cd67f63a0908291005m5a53b2cei71bfa48e4bc1d658@mail.gmail.com>
  10765 
  10766 On Sat, Aug 29, 2009 at 6:59 PM, Rich Lane<rlane at club.cc.cmu.edu> wrote:
  10767 > Excerpts from Nicolas Pouillard's message of Sat Aug 29 12:45:29 -0400 2009:
  10768 >> > Are you using the Flint or Chert Xapian backend?
  10769 >>
  10770 >> The Chert one.
  10771 >
  10772 > Could you try it with Flint? I've seen this (nondeterministic) bug when
  10773 > using Chert.
  10774 
  10775 I was currently running it again with no problems so far.
  10776 
  10777 Are the nondeterministic bugs only during sync?
  10778 
  10779 Chert is supposed to faster?
  10780 
  10781 Thanks for your help,
  10782 
  10783 -- 
  10784 Nicolas Pouillard
  10785 
  10786 From bwalton@artsci.utoronto.ca  Sat Aug 29 14:35:03 2009
  10787 From: bwalton@artsci.utoronto.ca (Ben Walton)
  10788 Date: Sat, 29 Aug 2009 14:35:03 -0400
  10789 Subject: [sup-talk] exception while importing to xapian
  10790 Message-ID: <1251570765-sup-4265@ntdws12.chass.utoronto.ca>
  10791 
  10792 
  10793 I just tried again to switch to xapian and I got the following:
  10794 
  10795 $ SUP_INDEX=xapian ruby -Ilib bin/sup-sync --all --all-sources --restore ~/.sup/dumpfile 
  10796 Loading state dump from /cquest/roger/staff0/systems/bwalton/.sup/dumpfile...
  10797 Read 72360 entries from dump file.
  10798 Scanning maildir:///u/bwalton/Maildir/...
  10799 [Sat Aug 29 14:29:11 -0400 2009] hook: read 'before-add-message' from
  10800 /cquest/roger/staff0/systems/bwalton/.sup/hooks/before-add-message.rb
  10801 ./lib/sup/xapian_index.rb:365:in `find_docid': undefined method `tap'
  10802 for []:Array (NoMethodError)
  10803         from ./lib/sup/xapian_index.rb:369:in `find_doc'
  10804         from ./lib/sup/xapian_index.rb:379:in `get_entry'
  10805         from ./lib/sup/xapian_index.rb:68:in `build_message'
  10806         from /usr/lib/ruby/1.8/monitor.rb:238:in `synchronize'
  10807         from ./lib/sup/xapian_index.rb:388:in `synchronize'
  10808         from ./lib/sup/xapian_index.rb:68:in `build_message'
  10809         from bin/sup-sync:149
  10810         from ./lib/sup/poll.rb:160:in `each_message_from'
  10811          ... 8 levels...
  10812         from ./lib/sup/util.rb:520:in `method_missing'
  10813         from bin/sup-sync:146
  10814         from bin/sup-sync:141:in `each'
  10815         from bin/sup-sync:141
  10816 
  10817 This happened with 806a067 (the current tip of next).  Exception log
  10818 attached.
  10819 
  10820 Thanks
  10821 -Ben
  10822 -- 
  10823 Ben Walton
  10824 Systems Programmer - CHASS
  10825 University of Toronto
  10826 C:416.407.5610 | W:416.978.4302
  10827 
  10828 GPG Key Id: 8E89F6D2; Key Server: pgp.mit.edu
  10829 Contact me to arrange for a CAcert assurance meeting.
  10830 -------------- next part --------------
  10831 An embedded and charset-unspecified text was scrubbed...
  10832 Name: sup-exception-log.txt
  10833 URL: <http://rubyforge.org/pipermail/sup-talk/attachments/20090829/c6d25c82/attachment.txt>
  10834 -------------- next part --------------
  10835 A non-text attachment was scrubbed...
  10836 Name: signature.asc
  10837 Type: application/pgp-signature
  10838 Size: 189 bytes
  10839 Desc: not available
  10840 URL: <http://rubyforge.org/pipermail/sup-talk/attachments/20090829/c6d25c82/attachment.bin>
  10841 
  10842 From rlane@club.cc.cmu.edu  Sat Aug 29 20:22:15 2009
  10843 From: rlane@club.cc.cmu.edu (Rich Lane)
  10844 Date: Sat, 29 Aug 2009 20:22:15 -0400
  10845 Subject: [sup-talk] Crash while syncing
  10846 In-Reply-To: <cd67f63a0908291005m5a53b2cei71bfa48e4bc1d658@mail.gmail.com>
  10847 References: <cd67f63a0908290218g30a737a9pd46d902cdf5399bb@mail.gmail.com>
  10848 	<cd67f63a0908290503g37ab5575ibb6162d06f7528af@mail.gmail.com>
  10849 	<1251563082-sup-3525@zyrg.net>
  10850 	<cd67f63a0908290945j2007c75cyc56ab6c1dcfdbbb1@mail.gmail.com>
  10851 	<1251564961-sup-5855@zyrg.net>
  10852 	<cd67f63a0908291005m5a53b2cei71bfa48e4bc1d658@mail.gmail.com>
  10853 Message-ID: <1251565999-sup-7892@zyrg.net>
  10854 
  10855 Excerpts from Nicolas Pouillard's message of Sat Aug 29 13:05:33 -0400 2009:
  10856 > Are the nondeterministic bugs only during sync?
  10857 
  10858 I've only seen it during sup-sync, but I'd guess if you ran sup long
  10859 enough you'd see it there too (after changing labels / polling).
  10860 
  10861 > Chert is supposed to faster?
  10862 
  10863 Yes, and more space efficient.
  10864 
  10865 From bburky@bburky.com  Sun Aug 30 16:14:56 2009
  10866 From: bburky@bburky.com (Blake Burkhart)
  10867 Date: Sun, 30 Aug 2009 15:14:56 -0500
  10868 Subject: [sup-talk] exception while importing to xapian
  10869 In-Reply-To: <1251570765-sup-4265@ntdws12.chass.utoronto.ca>
  10870 References: <1251570765-sup-4265@ntdws12.chass.utoronto.ca>
  10871 Message-ID: <1251662840-sup-4363@Backspace.local>
  10872 
  10873 Excerpts from Ben Walton's message of Sat Aug 29 13:35:03 -0500 2009:
  10874 > 
  10875 > I just tried again to switch to xapian and I got the following:
  10876 > 
  10877 > $ SUP_INDEX=xapian ruby -Ilib bin/sup-sync --all --all-sources --restore
  10878 > ~/.sup/dumpfile 
  10879 > Loading state dump from /cquest/roger/staff0/systems/bwalton/.sup/dumpfile...
  10880 > Read 72360 entries from dump file.
  10881 > Scanning maildir:///u/bwalton/Maildir/...
  10882 > [Sat Aug 29 14:29:11 -0400 2009] hook: read 'before-add-message' from
  10883 > /cquest/roger/staff0/systems/bwalton/.sup/hooks/before-add-message.rb
  10884 > ./lib/sup/xapian_index.rb:365:in `find_docid': undefined method `tap'
  10885 > for []:Array (NoMethodError)
  10886 >
  10887 >  [...]
  10888 > 
  10889 
  10890 I am getting this same error myself. I'm running Mac OS 10.5 with ruby 1.8.6.
  10891 Are you also using ruby 1.8.6? I think the tap method is in ruby 1.8.7 and
  10892 later. Actually a quick google shows it may even be ruby 1.9 only, or 1.9 and
  10893 backported from there.
  10894 
  10895 Is it necessary to use this method? Is there an alternate way to do this?
  10896 
  10897 -- Blake Burkhart
  10898 
  10899 From bwalton@artsci.utoronto.ca  Sun Aug 30 16:21:30 2009
  10900 From: bwalton@artsci.utoronto.ca (Ben Walton)
  10901 Date: Sun, 30 Aug 2009 16:21:30 -0400
  10902 Subject: [sup-talk] exception while importing to xapian
  10903 In-Reply-To: <1251662840-sup-4363@Backspace.local>
  10904 References: <1251570765-sup-4265@ntdws12.chass.utoronto.ca>
  10905 	<1251662840-sup-4363@Backspace.local>
  10906 Message-ID: <1251663644-sup-5538@ntdws12.chass.utoronto.ca>
  10907 
  10908 Excerpts from Blake Burkhart's message of Sun Aug 30 16:14:56 -0400 2009:
  10909 
  10910 > I am getting this same error myself. I'm running Mac OS 10.5 with ruby 1.8.6.
  10911 > Are you also using ruby 1.8.6? I think the tap method is in ruby 1.8.7 and
  10912 > later. Actually a quick google shows it may even be ruby 1.9 only, or 1.9 and
  10913 > backported from there.
  10914 
  10915 Actually, I'm on 1.8.5 (the version shipped with rhel5).  Sup may
  10916 finally force me to update it though.
  10917 
  10918 -Ben
  10919 
  10920 -- 
  10921 Ben Walton
  10922 Systems Programmer - CHASS
  10923 University of Toronto
  10924 C:416.407.5610 | W:416.978.4302
  10925 
  10926 GPG Key Id: 8E89F6D2; Key Server: pgp.mit.edu
  10927 Contact me to arrange for a CAcert assurance meeting.
  10928 -------------- next part --------------
  10929 A non-text attachment was scrubbed...
  10930 Name: signature.asc
  10931 Type: application/pgp-signature
  10932 Size: 189 bytes
  10933 Desc: not available
  10934 URL: <http://rubyforge.org/pipermail/sup-talk/attachments/20090830/fa051bea/attachment.bin>
  10935 
  10936 From rlane@club.cc.cmu.edu  Sun Aug 30 16:28:55 2009
  10937 From: rlane@club.cc.cmu.edu (Rich Lane)
  10938 Date: Sun, 30 Aug 2009 13:28:55 -0700
  10939 Subject: [sup-talk] [PATCH] remove use of Object#tap
  10940 Message-ID: <1251664135-1383-1-git-send-email-rlane@club.cc.cmu.edu>
  10941 
  10942 ---
  10943  lib/sup/xapian_index.rb |    4 +++-
  10944  1 files changed, 3 insertions(+), 1 deletions(-)
  10945 
  10946 diff --git a/lib/sup/xapian_index.rb b/lib/sup/xapian_index.rb
  10947 index c260728..1395601 100644
  10948 --- a/lib/sup/xapian_index.rb
  10949 +++ b/lib/sup/xapian_index.rb
  10950 @@ -362,7 +362,9 @@ class XapianIndex < BaseIndex
  10951    end
  10952  
  10953    def find_docid id
  10954 -    term_docids(mkterm(:msgid,id)).tap { |x| fail unless x.size <= 1 }.first
  10955 +    docids = term_docids(mkterm(:msgid,id))
  10956 +    fail unless docids.size <= 1
  10957 +    docids.first
  10958    end
  10959  
  10960    def find_doc id
  10961 -- 
  10962 1.6.0.4
  10963 
  10964 
  10965 From bburky@bburky.com  Sun Aug 30 16:45:48 2009
  10966 From: bburky@bburky.com (Blake Burkhart)
  10967 Date: Sun, 30 Aug 2009 15:45:48 -0500
  10968 Subject: [sup-talk] [PATCH] remove use of Object#tap
  10969 In-Reply-To: <1251664135-1383-1-git-send-email-rlane@club.cc.cmu.edu>
  10970 References: <1251664135-1383-1-git-send-email-rlane@club.cc.cmu.edu>
  10971 Message-ID: <1251664798-sup-8169@Backspace.local>
  10972 
  10973 Excerpts from Rich Lane's message of Sun Aug 30 15:28:55 -0500 2009:
  10974 > ---
  10975 >  lib/sup/xapian_index.rb |    4 +++-
  10976 >  1 files changed, 3 insertions(+), 1 deletions(-)
  10977 > 
  10978 > diff --git a/lib/sup/xapian_index.rb b/lib/sup/xapian_index.rb
  10979 > index c260728..1395601 100644
  10980 > --- a/lib/sup/xapian_index.rb
  10981 > +++ b/lib/sup/xapian_index.rb
  10982 > @@ -362,7 +362,9 @@ class XapianIndex < BaseIndex
  10983 >    end
  10984 >  
  10985 >    def find_docid id
  10986 > -    term_docids(mkterm(:msgid,id)).tap { |x| fail unless x.size <= 1 }.first
  10987 > +    docids = term_docids(mkterm(:msgid,id))
  10988 > +    fail unless docids.size <= 1
  10989 > +    docids.first
  10990 >    end
  10991 >  
  10992 >    def find_doc id
  10993 
  10994 After applying this on next in hopes it lets me run sup on ruby 1.8.6, it
  10995 doesn't work.
  10996 
  10997 It crashed with this log:
  10998 $ SUP_INDEX=xapian ruby -Ilib bin/sup-sync --all --all-sources --restore ~/dumpfile
  10999 Loading state dump from /Users/blake/dumpfile...
  11000 Read 6790 entries from dump file.
  11001 Scanning maildir:/Users/blake/Mail/bburky/INBOX...
  11002 [Sun Aug 30 15:38:57 -0500 2009] hook: read 'before-add-message' from /Users/blake/.sup/hooks/before-add-message.rb
  11003 [Sun Aug 30 15:38:57 -0500 2009] hook[before-add-message]: Marking message 1234774373-sup-1128 at zo as suptalk, subject is 'Re: [sup-talk] (no subject)'
  11004 ./lib/sup/label.rb:64:in `<<': expecting a symbol (ArgumentError)
  11005 	from ./lib/sup/util.rb:520:in `send'
  11006 	from ./lib/sup/util.rb:520:in `method_missing'
  11007 	from ./lib/sup/xapian_index.rb:114:in `sync_message'
  11008 	from /System/Library/Frameworks/Ruby.framework/Versions/1.8/usr/lib/ruby/1.8/set.rb:189:in `each'
  11009 	from /System/Library/Frameworks/Ruby.framework/Versions/1.8/usr/lib/ruby/1.8/set.rb:189:in `each_key'
  11010 	from /System/Library/Frameworks/Ruby.framework/Versions/1.8/usr/lib/ruby/1.8/set.rb:189:in `each'
  11011 	from ./lib/sup/xapian_index.rb:114:in `sync_message'
  11012 	from ./lib/sup/xapian_index.rb:87:in `add_message'
  11013 	 ... 10 levels...
  11014 	from ./lib/sup/util.rb:520:in `method_missing'
  11015 	from bin/sup-sync:146
  11016 	from bin/sup-sync:141:in `each'
  11017 	from bin/sup-sync:141
  11018 
  11019 However, I'm having other odd problems too with labels anyway. On the ferret
  11020 version of sup, I'm not able to apply labels with the 'l' command. However, I
  11021 have a hook for applying a label from the List-ID that does still work. So
  11022 this patch may or may not work, I think I'm possibly having problems of my
  11023 own.
  11024 
  11025 Actually, I haven't tried to restore from a dumpfile for ferret. I'll do that
  11026 later and see if it works.
  11027 
  11028 -- Blake Burkhart
  11029 
  11030 From rlane@club.cc.cmu.edu  Sun Aug 30 16:47:59 2009
  11031 From: rlane@club.cc.cmu.edu (Rich Lane)
  11032 Date: Sun, 30 Aug 2009 16:47:59 -0400
  11033 Subject: [sup-talk] exception while importing to xapian
  11034 In-Reply-To: <1251662840-sup-4363@Backspace.local>
  11035 References: <1251570765-sup-4265@ntdws12.chass.utoronto.ca>
  11036 	<1251662840-sup-4363@Backspace.local>
  11037 Message-ID: <1251664201-sup-9803@zyrg.net>
  11038 
  11039 Excerpts from Blake Burkhart's message of Sun Aug 30 16:14:56 -0400 2009:
  11040 > I am getting this same error myself. I'm running Mac OS 10.5 with ruby 1.8.6.
  11041 > Are you also using ruby 1.8.6? I think the tap method is in ruby 1.8.7 and
  11042 > later. Actually a quick google shows it may even be ruby 1.9 only, or 1.9 and
  11043 > backported from there.
  11044 > 
  11045 > Is it necessary to use this method? Is there an alternate way to do this?
  11046 
  11047 Yeah, this was just a 1.8.7-ism. I've sent a patch to fix it.
  11048 
  11049 From bburky@bburky.com  Sun Aug 30 17:50:09 2009
  11050 From: bburky@bburky.com (Blake Burkhart)
  11051 Date: Sun, 30 Aug 2009 16:50:09 -0500
  11052 Subject: [sup-talk] [PATCH] remove use of Object#tap
  11053 In-Reply-To: <1251664798-sup-8169@Backspace.local>
  11054 References: <1251664135-1383-1-git-send-email-rlane@club.cc.cmu.edu>
  11055 	<1251664798-sup-8169@Backspace.local>
  11056 Message-ID: <1251668806-sup-7253@Backspace.local>
  11057 
  11058 Excerpts from Blake Burkhart's message of Sun Aug 30 15:45:48 -0500 2009:
  11059 > After applying this on next in hopes it lets me run sup on ruby 1.8.6, it
  11060 > doesn't work.
  11061 > 
  11062 > It crashed with this log:
  11063 > $ SUP_INDEX=xapian ruby -Ilib bin/sup-sync --all --all-sources --restore
  11064 > ~/dumpfile
  11065 > Loading state dump from /Users/blake/dumpfile...
  11066 > Read 6790 entries from dump file.
  11067 > Scanning maildir:/Users/blake/Mail/bburky/INBOX...
  11068 > [Sun Aug 30 15:38:57 -0500 2009] hook: read 'before-add-message' from
  11069 > /Users/blake/.sup/hooks/before-add-message.rb
  11070 > [Sun Aug 30 15:38:57 -0500 2009] hook[before-add-message]: Marking message
  11071 > 1234774373-sup-1128 at zo as suptalk, subject is 'Re: [sup-talk] (no subject)'
  11072 > ./lib/sup/label.rb:64:in `<<': expecting a symbol (ArgumentError)
  11073 >     from ./lib/sup/util.rb:520:in `send'
  11074 >     from ./lib/sup/util.rb:520:in `method_missing'
  11075 >     from ./lib/sup/xapian_index.rb:114:in `sync_message'
  11076 >     from
  11077 > /System/Library/Frameworks/Ruby.framework/Versions/1.8/usr/lib/ruby/1.8/set.rb:1
  11078 > 89:in `each'
  11079 >     from
  11080 > /System/Library/Frameworks/Ruby.framework/Versions/1.8/usr/lib/ruby/1.8/set.rb:1
  11081 > 89:in `each_key'
  11082 >     from
  11083 > /System/Library/Frameworks/Ruby.framework/Versions/1.8/usr/lib/ruby/1.8/set.rb:1
  11084 > 89:in `each'
  11085 >     from ./lib/sup/xapian_index.rb:114:in `sync_message'
  11086 >     from ./lib/sup/xapian_index.rb:87:in `add_message'
  11087 >      ... 10 levels...
  11088 >     from ./lib/sup/util.rb:520:in `method_missing'
  11089 >     from bin/sup-sync:146
  11090 >     from bin/sup-sync:141:in `each'
  11091 >     from bin/sup-sync:141
  11092 > 
  11093 > However, I'm having other odd problems too with labels anyway. On the ferret
  11094 > version of sup, I'm not able to apply labels with the 'l' command. However, I
  11095 > have a hook for applying a label from the List-ID that does still work. So
  11096 > this patch may or may not work, I think I'm possibly having problems of my
  11097 > own.
  11098 I got it to work. Mostly a least. What does a sup-dump file actually store? I
  11099 lost all read/unread statuses and all labels (including the spam label thing,
  11100 I assume it's just a normal label).
  11101 
  11102 To get it to work, I removed my before-add-message hook. It has worked for a
  11103 long time, through different versions of sup, etc. However, It doesn't seem to
  11104 be working with xapian.
  11105 
  11106 I don't actually know where this code came from, possibly this list, or maybe
  11107 else where. I may have even modified it, I don't really remember. The hook is
  11108 this:
  11109 
  11110 listIdMatch = message.raw_header.match(/List-Id:.*?<(.*?)>\s*$/i)
  11111 
  11112 if(listIdMatch)
  11113   listIdLabel = listIdMatch[1].split(/\./).first.sub(/[^0-9A-Za-z]/, "")
  11114   message.add_label listIdLabel
  11115   log "Marking message #{message.id} as #{listIdLabel}, subject is '#{message.subj}'"
  11116 end
  11117 
  11118 > Actually, I haven't tried to restore from a dumpfile for ferret. I'll do that
  11119 > later and see if it works.
  11120 
  11121 I did try a restore from dumpfile with ferret. It worked except it didn't
  11122 remember the labels the same way xapian didn't. However, the hook did work,
  11123 and created labels on all mailing list messages.
  11124 
  11125 I think this isn't a xapian problem, because ferret is acting the same.
  11126 
  11127 If I want to recreate the sup files from scratch, what do I need to have? My
  11128 config.yaml, sources.yaml, sent.mbox and a dumpfile? Is that all?
  11129 
  11130 From bwalton@artsci.utoronto.ca  Sun Aug 30 19:55:56 2009
  11131 From: bwalton@artsci.utoronto.ca (Ben Walton)
  11132 Date: Sun, 30 Aug 2009 19:55:56 -0400
  11133 Subject: [sup-talk] [PATCH] remove use of Object#tap
  11134 In-Reply-To: <1251668806-sup-7253@Backspace.local>
  11135 References: <1251664135-1383-1-git-send-email-rlane@club.cc.cmu.edu>
  11136 	<1251664798-sup-8169@Backspace.local>
  11137 	<1251668806-sup-7253@Backspace.local>
  11138 Message-ID: <1251676342-sup-7038@ntdws12.chass.utoronto.ca>
  11139 
  11140 Excerpts from Blake Burkhart's message of Sun Aug 30 17:50:09 -0400 2009:
  11141 
  11142 > I got it to work. Mostly a least. What does a sup-dump file actually store? I
  11143 > lost all read/unread statuses and all labels (including the spam label thing,
  11144 > I assume it's just a normal label).
  11145 
  11146 I also lost labels on my first attempt at switching to xapian.  I gave
  11147 up for a few days as there were other issues with labels at the time.
  11148 Losing labels during the switch would be a deal breaker, but I assume
  11149 this isn't intended (as that would be madness, madness, I say)...is
  11150 there a step I'm missing in the following (assuming HEAD of next)?
  11151 
  11152 4. cp ~/.sup/sources.yaml{,.bak}
  11153 5. ruby -Ilib bin/sup-dump > dumpfile
  11154 6. SUP_INDEX=xapian ruby -Ilib bin/sup-sync --all --all-sources
  11155    --restore dumpfile
  11156 7. SUP_INDEX=xapian ruby -Ilib bin/sup -o
  11157 
  11158 Thanks
  11159 -Ben
  11160 
  11161 
  11162 -- 
  11163 Ben Walton
  11164 Systems Programmer - CHASS
  11165 University of Toronto
  11166 C:416.407.5610 | W:416.978.4302
  11167 
  11168 GPG Key Id: 8E89F6D2; Key Server: pgp.mit.edu
  11169 Contact me to arrange for a CAcert assurance meeting.
  11170 -------------- next part --------------
  11171 A non-text attachment was scrubbed...
  11172 Name: signature.asc
  11173 Type: application/pgp-signature
  11174 Size: 189 bytes
  11175 Desc: not available
  11176 URL: <http://rubyforge.org/pipermail/sup-talk/attachments/20090830/1955cef2/attachment.bin>
  11177 
  11178 From rlane@club.cc.cmu.edu  Sun Aug 30 20:50:34 2009
  11179 From: rlane@club.cc.cmu.edu (Rich Lane)
  11180 Date: Sun, 30 Aug 2009 17:50:34 -0700
  11181 Subject: [sup-talk] [PATCH] sup-sync: restore state on messages that dont
  11182 	already exist
  11183 Message-ID: <1251679834-5313-1-git-send-email-rlane@club.cc.cmu.edu>
  11184 
  11185 ---
  11186  bin/sup-sync |    5 +++++
  11187  1 files changed, 5 insertions(+), 0 deletions(-)
  11188 
  11189 diff --git a/bin/sup-sync b/bin/sup-sync
  11190 index 2aa00c3..003a72d 100755
  11191 --- a/bin/sup-sync
  11192 +++ b/bin/sup-sync
  11193 @@ -174,7 +174,12 @@ begin
  11194        ## decide what to do based on message labels and the operation we're performing
  11195        dothis, new_labels = case
  11196        when (op == :restore) && restored_state[m.id] && old_m && (old_m.labels != restored_state[m.id])
  11197 +        num_restored += 1
  11198          [:update_message_state, restored_state[m.id]]
  11199 +      when (op == :restore) && restored_state[m.id] && !old_m
  11200 +        num_restored += 1
  11201 +        m.labels = restored_state[m.id]
  11202 +        :add_message
  11203        when op == :discard
  11204          if old_m && (old_m.labels != m.labels)
  11205            [:update_message_state, m.labels]
  11206 -- 
  11207 1.6.4
  11208 
  11209 
  11210 From rlane@club.cc.cmu.edu  Sun Aug 30 20:50:46 2009
  11211 From: rlane@club.cc.cmu.edu (Rich Lane)
  11212 Date: Sun, 30 Aug 2009 20:50:46 -0400
  11213 Subject: [sup-talk] [PATCH] remove use of Object#tap
  11214 In-Reply-To: <1251676342-sup-7038@ntdws12.chass.utoronto.ca>
  11215 References: <1251664135-1383-1-git-send-email-rlane@club.cc.cmu.edu>
  11216 	<1251664798-sup-8169@Backspace.local>
  11217 	<1251668806-sup-7253@Backspace.local>
  11218 	<1251676342-sup-7038@ntdws12.chass.utoronto.ca>
  11219 Message-ID: <1251677009-sup-2661@zyrg.net>
  11220 
  11221 Excerpts from Ben Walton's message of Sun Aug 30 19:55:56 -0400 2009:
  11222 > Excerpts from Blake Burkhart's message of Sun Aug 30 17:50:09 -0400 2009:
  11223 > 
  11224 > > I got it to work. Mostly a least. What does a sup-dump file actually store? I
  11225 > > lost all read/unread statuses and all labels (including the spam label thing,
  11226 > > I assume it's just a normal label).
  11227 > 
  11228 > I also lost labels on my first attempt at switching to xapian.  I gave
  11229 > up for a few days as there were other issues with labels at the time.
  11230 > Losing labels during the switch would be a deal breaker, but I assume
  11231 > this isn't intended (as that would be madness, madness, I say)...is
  11232 > there a step I'm missing in the following (assuming HEAD of next)?
  11233 > 
  11234 > 4. cp ~/.sup/sources.yaml{,.bak}
  11235 > 5. ruby -Ilib bin/sup-dump > dumpfile
  11236 > 6. SUP_INDEX=xapian ruby -Ilib bin/sup-sync --all --all-sources
  11237 >    --restore dumpfile
  11238 > 7. SUP_INDEX=xapian ruby -Ilib bin/sup -o
  11239 > 
  11240 > Thanks
  11241 > -Ben
  11242 > 
  11243 
  11244 This is an issue that was introduced in 906ab35e. I've just resent a
  11245 patch for it.
  11246 -------------- next part --------------
  11247 A non-text attachment was scrubbed...
  11248 Name: restore-state-fix
  11249 Type: application/octet-stream
  11250 Size: 3534 bytes
  11251 Desc: not available
  11252 URL: <http://rubyforge.org/pipermail/sup-talk/attachments/20090830/5be2a745/attachment.obj>
  11253 
  11254 From bburky@bburky.com  Sun Aug 30 21:48:50 2009
  11255 From: bburky@bburky.com (Blake Burkhart)
  11256 Date: Sun, 30 Aug 2009 20:48:50 -0500
  11257 Subject: [sup-talk] [PATCH] sup-sync: restore state on messages that
  11258 	dont already exist
  11259 In-Reply-To: <1251679834-5313-1-git-send-email-rlane@club.cc.cmu.edu>
  11260 References: <1251679834-5313-1-git-send-email-rlane@club.cc.cmu.edu>
  11261 Message-ID: <1251683226-sup-7685@Backspace.local>
  11262 
  11263 Excerpts from Rich Lane's message of Sun Aug 30 19:50:34 -0500 2009:
  11264 > ---
  11265 >  bin/sup-sync |    5 +++++
  11266 >  1 files changed, 5 insertions(+), 0 deletions(-)
  11267 > 
  11268 > diff --git a/bin/sup-sync b/bin/sup-sync
  11269 > index 2aa00c3..003a72d 100755
  11270 > --- a/bin/sup-sync
  11271 > +++ b/bin/sup-sync
  11272 > @@ -174,7 +174,12 @@ begin
  11273 >        ## decide what to do based on message labels and the operation we're
  11274 > performing
  11275 >        dothis, new_labels = case
  11276 >        when (op == :restore) && restored_state[m.id] && old_m && (old_m.labels
  11277 > != restored_state[m.id])
  11278 > +        num_restored += 1
  11279 >          [:update_message_state, restored_state[m.id]]
  11280 > +      when (op == :restore) && restored_state[m.id] && !old_m
  11281 > +        num_restored += 1
  11282 > +        m.labels = restored_state[m.id]
  11283 > +        :add_message
  11284 >        when op == :discard
  11285 >          if old_m && (old_m.labels != m.labels)
  11286 >            [:update_message_state, m.labels]
  11287 
  11288 Yay, thank you. Everything works now I think. I now have xapian working correctly I think.
  11289 
  11290 From rlane@club.cc.cmu.edu  Mon Aug 31 00:16:03 2009
  11291 From: rlane@club.cc.cmu.edu (Rich Lane)
  11292 Date: Mon, 31 Aug 2009 00:16:03 -0400
  11293 Subject: [sup-talk] [PATCH] index log
  11294 In-Reply-To: <1251116226-sup-1373@peray>
  11295 References: <1250491123-19240-1-git-send-email-rlane@club.cc.cmu.edu>
  11296 	<1250948551-sup-2052@masanjin.net> <1251116226-sup-1373@peray>
  11297 Message-ID: <1251691269-sup-246@zyrg.net>
  11298 
  11299 Excerpts from Nicolas Pouillard's message of Mon Aug 24 08:20:20 -0400 2009:
  11300 > Excerpts from William Morgan's message of Sat Aug 22 15:46:27 +0200 2009:
  11301 > > Reformatted excerpts from Rich Lane's message of 2009-08-16:
  11302 > > > Add a YAML logfile that records changes to the index and modify
  11303 > > > sup-dump to use this rather than the normal database.
  11304 > > 
  11305 > > I like this. I'm going to wait to apply it until the api refactoring
  11306 > > stuff is merged down to master though. Should be soon.
  11307 > 
  11308 > I'm wondering if a simpler format would not be better, I've patch
  11309 > in my sup copy do feed a file called ~/.sup/labels-mapping.log with
  11310 > lines like those:
  11311 > 
  11312 > 000e0cd20f80143822047118693d at google.com (unread inbox -> )
  11313 > 20090813213654.GA30223 at community.haskell.org (unread inbox patch -> patch)
  11314 > 1250148617-sup-6053 at oz.taruti.net (unread inbox sup -> sup)
  11315 > 1250281208-sup-4199 at masanjin.net (unread inbox sup -> sup)
  11316 > 
  11317 > Their are in the style of sup-dump output and there are pretty easy to manage
  11318 > by any tools.
  11319 > 
  11320 > Not to say that I don't like YAML, I am a pretty big fan of it; but here it
  11321 > seems overkill.
  11322 > 
  11323 > Best regards,
  11324 > 
  11325 
  11326 I agree that YAML is overkill for what we're currently storing in the
  11327 log. The intention was to make this as foolproof for future expansion as
  11328 possible, but after some time thinking about it I haven't come up with
  11329 more fields to add (not that there still couldn't be, but I think it's
  11330 unlikely). I'll submit a simpler patch.
  11331 
  11332 What do people think about replacing the current undo system with one
  11333 based on the label log? This would only be possible once we have
  11334 immediate label changes. I think it would simplify a lot of code.
  11335 
  11336 From bwalton@artsci.utoronto.ca  Mon Aug 31 07:42:21 2009
  11337 From: bwalton@artsci.utoronto.ca (Ben Walton)
  11338 Date: Mon, 31 Aug 2009 07:42:21 -0400
  11339 Subject: [sup-talk] [PATCH] index log
  11340 In-Reply-To: <1251691269-sup-246@zyrg.net>
  11341 References: <1250491123-19240-1-git-send-email-rlane@club.cc.cmu.edu>
  11342 	<1250948551-sup-2052@masanjin.net> <1251116226-sup-1373@peray>
  11343 	<1251691269-sup-246@zyrg.net>
  11344 Message-ID: <1251718898-sup-2772@ntdws12.chass.utoronto.ca>
  11345 
  11346 Excerpts from Rich Lane's message of Mon Aug 31 00:16:03 -0400 2009:
  11347 
  11348 > What do people think about replacing the current undo system with one
  11349 > based on the label log? This would only be possible once we have
  11350 > immediate label changes. I think it would simplify a lot of code.
  11351 
  11352 +1 for this.  I find that more often than not, undo doesn't work as
  11353 expected anyway.  It's been suggested that this is a threading bug,
  11354 which is quite likely...
  11355 
  11356 -Ben
  11357 -- 
  11358 Ben Walton
  11359 Systems Programmer - CHASS
  11360 University of Toronto
  11361 C:416.407.5610 | W:416.978.4302
  11362 
  11363 GPG Key Id: 8E89F6D2; Key Server: pgp.mit.edu
  11364 Contact me to arrange for a CAcert assurance meeting.
  11365 -------------- next part --------------
  11366 A non-text attachment was scrubbed...
  11367 Name: signature.asc
  11368 Type: application/pgp-signature
  11369 Size: 189 bytes
  11370 Desc: not available
  11371 URL: <http://rubyforge.org/pipermail/sup-talk/attachments/20090831/8111b611/attachment.bin>
  11372 
  11373 From wmorgan-sup@masanjin.net  Mon Aug 31 22:41:06 2009
  11374 From: wmorgan-sup@masanjin.net (William Morgan)
  11375 Date: Mon, 31 Aug 2009 19:41:06 -0700
  11376 Subject: [sup-talk] [PATCH] sup-sync: restore state on messages that
  11377 	dont already exist
  11378 In-Reply-To: <1251052619-9915-1-git-send-email-rlane@club.cc.cmu.edu>
  11379 References: <1251052619-9915-1-git-send-email-rlane@club.cc.cmu.edu>
  11380 Message-ID: <1251772852-sup-5207@masanjin.net>
  11381 
  11382 Applied, thanks!
  11383 -- 
  11384 William <wmorgan-sup at masanjin.net>
  11385 
  11386 From wmorgan-sup@masanjin.net  Mon Aug 31 22:51:20 2009
  11387 From: wmorgan-sup@masanjin.net (William Morgan)
  11388 Date: Mon, 31 Aug 2009 19:51:20 -0700
  11389 Subject: [sup-talk] [PATCH] reply all keybindings
  11390 In-Reply-To: <1251053342-11859-1-git-send-email-rlane@club.cc.cmu.edu>
  11391 References: <1251053342-11859-1-git-send-email-rlane@club.cc.cmu.edu>
  11392 Message-ID: <1251773465-sup-3081@masanjin.net>
  11393 
  11394 Branch reply-all-keybindings, merged into next. Thanks!
  11395 -- 
  11396 William <wmorgan-sup at masanjin.net>
  11397 
  11398 From wmorgan-sup@masanjin.net  Mon Aug 31 22:57:54 2009
  11399 From: wmorgan-sup@masanjin.net (William Morgan)
  11400 Date: Mon, 31 Aug 2009 19:57:54 -0700
  11401 Subject: [sup-talk] [PATCH] Add UTF-8 encoding string for ArchLinux
  11402 	systems
  11403 In-Reply-To: <1251192382-sup-2350@elly>
  11404 References: <1251192382-sup-2350@elly>
  11405 Message-ID: <1251773862-sup-2194@masanjin.net>
  11406 
  11407 Reformatted excerpts from Israel Herraiz's message of 2009-08-25:
  11408 > in ArchLinux, UTF-8 encoding is identified by "utf8" instead of
  11409 > "UTF-8".
  11410 
  11411 Applied to master. Thanks!
  11412 -- 
  11413 William <wmorgan-sup at masanjin.net>
  11414 
  11415 From wmorgan-sup@masanjin.net  Mon Aug 31 22:58:47 2009
  11416 From: wmorgan-sup@masanjin.net (William Morgan)
  11417 Date: Mon, 31 Aug 2009 19:58:47 -0700
  11418 Subject: [sup-talk] [PATCH] Identify list messages by list-id if
  11419 	list-post is not present
  11420 In-Reply-To: <1251192579-sup-1849@elly>
  11421 References: <1251192579-sup-1849@elly>
  11422 Message-ID: <1251773879-sup-5227@masanjin.net>
  11423 
  11424 Reformatted excerpts from Israel Herraiz's message of 2009-08-25:
  11425 > I am subscribed to some lists that do not fill the list-post header,
  11426 > but have a list-id header. I am not sure how standard-compliant is
  11427 > that, but it would nice if Sup could identify those messages as list
  11428 > messages.
  11429 
  11430 Does this patch work for you?
  11431 
  11432 diff --git a/lib/sup/message.rb b/lib/sup/message.rb
  11433 index ed27d3d..472b9dc 100644
  11434 --- a/lib/sup/message.rb
  11435 +++ b/lib/sup/message.rb
  11436 @@ -114,12 +114,11 @@ class Message
  11437      @replytos = (header["in-reply-to"] || "").scan(/<(.+?)>/).map { |x| sanitize_me
  11438  
  11439      @replyto = Person.from_address header["reply-to"]
  11440 -    @list_address =
  11441 -      if header["list-post"]
  11442 -        @list_address = Person.from_address header["list-post"].gsub(/^<mailto:|>$/
  11443 -      else
  11444 -        nil
  11445 -      end
  11446 +    @list_address = if header["list-post"]
  11447 +      Person.from_address header["list-post"].gsub(/^<mailto:|>$/, "")
  11448 +    elsif header["list-id"]
  11449 +      Person.from_address header["list-id"].gsub(/^<:|>$/, "")
  11450 +    end
  11451  
  11452      @recipient_email = header["envelope-to"] || header["x-original-to"] || header["
  11453      @source_marked_read = header["status"] == "RO"
  11454 
  11455 -- 
  11456 William <wmorgan-sup at masanjin.net>
  11457 
  11458 From wmorgan-sup@masanjin.net  Mon Aug 31 23:06:05 2009
  11459 From: wmorgan-sup@masanjin.net (William Morgan)
  11460 Date: Mon, 31 Aug 2009 20:06:05 -0700
  11461 Subject: [sup-talk] [PATCH] Make SUP_LOG_LEVEL self-documenting.
  11462 In-Reply-To: <1251322427-sup-9184@yoom.home.cworth.org>
  11463 References: <1250745799-sup-6607@yoom.home.cworth.org>
  11464 	<1250972634-sup-6871@masanjin.net>
  11465 	<1251322427-sup-9184@yoom.home.cworth.org>
  11466 Message-ID: <1251774349-sup-4067@masanjin.net>
  11467 
  11468 Applied, thanks!
  11469 -- 
  11470 William <wmorgan-sup at masanjin.net>
  11471 
  11472 From wmorgan-sup@masanjin.net  Mon Aug 31 23:17:36 2009
  11473 From: wmorgan-sup@masanjin.net (William Morgan)
  11474 Date: Mon, 31 Aug 2009 20:17:36 -0700
  11475 Subject: [sup-talk] [PATCH] remove use of Object#tap
  11476 In-Reply-To: <1251664135-1383-1-git-send-email-rlane@club.cc.cmu.edu>
  11477 References: <1251664135-1383-1-git-send-email-rlane@club.cc.cmu.edu>
  11478 Message-ID: <1251774958-sup-5853@masanjin.net>
  11479 
  11480 Applied. Sup does define a #returning function which is equivalent to
  11481 #tap, FWIW.
  11482 -- 
  11483 William <wmorgan-sup at masanjin.net>
  11484