sup

A curses threads-with-tags style email client

sup-website.git

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

community/pipermail-archives/sup-devel/2013-06.txt (10521B) - raw

      1 From hsanson@gmail.com  Sun Jun  2 02:45:47 2013
      2 From: hsanson@gmail.com (Horacio Sanson)
      3 Date: Sun, 2 Jun 2013 11:45:47 +0900
      4 Subject: [sup-devel] Experimental Gmail Source
      5 In-Reply-To: <1369172802-sup-2003@kpad>
      6 References: <CAHWBo_Y6jEWCH8O+m1iw5_p4qd8ghxgvCsa1+15xR7fh+6S0nA@mail.gmail.com>
      7 	<518E1A2B.2080903@gaute.vetsj.com>
      8 	<CAHWBo_ZMce1GV=ChkLrSNbz9Lf-DtPb4W479kChXmUFMQf5qpw@mail.gmail.com>
      9 	<CAHWBo_ZY7bWTxfqbQ1H3hu-q6mzKZm-YYe-+t0b-0M7xwUDfYQ@mail.gmail.com>
     10 	<1369172802-sup-2003@kpad>
     11 Message-ID: <CAHWBo_acPoWYtBrcd+NTkOit7L7Vx_=Tkxequ-iQimPugWjsJQ@mail.gmail.com>
     12 
     13 Thanks for checking the source and sorry for the late response... I can
     14 only look into this on rare free weekends.
     15 
     16 
     17 On Wed, May 22, 2013 at 6:47 AM, Matthieu Rakotojaona <
     18 matthieu.rakotojaona at gmail.com> wrote:
     19 
     20 > Hey Horacio,
     21 >
     22 > I took a stab at your gmail_source branch, and made a few
     23 > fixes/improvements [0]:
     24 >
     25 > - Add configuration option in sup-add
     26 > - Dump the LevelDB path in the sources.yaml
     27 > - Add a load_from_yaml method for a source to initialize its working
     28 >   values (for instance, the @db cannot be serialized, it needs to be
     29 >   reconstructed)
     30 > - Fixed the msg_att monkey-patch for imap.rb
     31 >
     32 >
     33 Great, I will add these changes to my branch....
     34 
     35 
     36 > All in all, the gmail source seems to work. I tested it on my usual
     37 > gmail account, I haven't tried to download it all, but I did download a
     38 > few dozens of emails without a problem. I'd like to warn users about
     39 > LevelDB though: it's sad to say, but as other wmorgan's stuff, it looks
     40 > abandoned. There are at least 2 bugs you will encounter if you try it: a
     41 > pb in configuration (fixed in [1]) and you need the `snappy` gem to make
     42 > it work if your db is more than 4MB large [2]. There are some up-to-date
     43 > forks, though.
     44 
     45 
     46 
     47 >
     48 >
     49 I see LevelDB is used mostly for storing messages and mailboxes
     50 > uid{validity/last}, but if we are to use gmail (it's the only IMAP
     51 > provider that makes sense for sup), I believe we would stick to the All
     52 > Mail label, right ? So, no need for storing this in db, rather in the
     53 > sources.yaml file. Also, if leveldb-ruby is unreliable (I did encounter
     54 > some issues way back about something with glibc...), and we want to use
     55 > it for caching messages, I think we can salvage heliotrope's zmbox [3]
     56 > because it's so simple to use yet far better than simple mbox.
     57 
     58 
     59 Using zmbox, mbox, maildir or any other mail storage (mix?) means I need to
     60 keep track of three indexes to allow two way sync between the Gmail source
     61 and the Sup index. I would need the Sup index id, the store id (e.g. zmbox
     62 file index) and the Gmail X-GM-MSGID. That complicates things a lot.
     63 
     64 Using key/value stores like LevelDB allows me to directly store the
     65 messages and associate them directly with the Gmail X-GM-MSGID. Also
     66 LevelDB comes with high compression for text data, perfect for emails, and
     67 high performance [1]. The issues you mention seem to be on the ruby library
     68 rather than LevelDB itself and they are fixable. If there are no bigger
     69 issues (e.g. data corruption/loss) I will stick with LevelDB.
     70 
     71 Regarding your ids questions, if you want to access the sup's messages
     72 > from the gmail source, you could use the mail's Message-ID header and
     73 > apply the same logic as in Message.sanitize_message_id. Caution,
     74 > however: I've already encountered the case where multiple messages in
     75 > GMail (i.e multiple X-GM-MSGID) have the same Message-ID, so they would
     76 > be considered the same in sup/heliotrope... yeah, that's annoying as
     77 > hell, and I don't know how we can solve this in the case of multiple
     78 > sources.
     79 >
     80 >
     81 Thanks, this comment put me on track and I found a way to get the emails
     82 from the index using the message id provided by the source. All I need to
     83 do is call Message.build_from_source(source, info) where info is the
     84 message id provided by the source. In my case this would be the X-GM-MSGID
     85 string.
     86 
     87 If you want to sync-back, maybe sup can call a source-level "sync_back"
     88 > method with the current known state ? Speaking of which, for general
     89 > synchronization we could reuse the elegant offlineimap's sync algorithm
     90 > [4]. The idea is basic: have each source class store a snapshot of the
     91 > state.  When a message is modified on the source, diff the change with
     92 > the known status and propagate to sup; when a message is modified in
     93 > sup, diff with the known status and propagate to the source.
     94 >
     95 >
     96 Interesting and simple algorithm. Let me study it a little more and see how
     97 it is applicable to Sup.
     98 
     99 [1]  http://leveldb.googlecode.com/svn/trunk/doc/benchmark.html
    100 
    101 regards,
    102 Horacio
    103 
    104 Just a brain dump.
    105 >
    106 > [0] https://github.com/rakoo/sup/tree/gmail_source
    107 > [1] https://github.com/wmorgan/leveldb-ruby/pull/27
    108 > [2] https://github.com/wmorgan/leveldb-ruby/issues/23
    109 > [3]
    110 > https://github.com/sup-heliotrope/heliotrope/blob/64d4b50d5649ec616a311a4cf6955137fdaeb13d/lib/heliotrope/zmbox.rb
    111 > [4] http://offlineimap.org/howitworks.html
    112 >
    113 > Regards,
    114 >
    115 > --
    116 > Matthieu Rakotojaona
    117 >
    118 > _______________________________________________
    119 > Sup-devel mailing list
    120 > Sup-devel at rubyforge.org
    121 > http://rubyforge.org/mailman/listinfo/sup-devel
    122 >
    123 >
    124 -------------- next part --------------
    125 An HTML attachment was scrubbed...
    126 URL: <http://rubyforge.org/pipermail/sup-devel/attachments/20130602/acec77c1/attachment.html>
    127 
    128 From eg@gaute.vetsj.com  Thu Jun 13 20:33:28 2013
    129 From: eg@gaute.vetsj.com (Gaute Hope)
    130 Date: Thu, 13 Jun 2013 22:33:28 +0200
    131 Subject: [sup-devel] going for 0.13.1 and possibly 0.14?
    132 Message-ID: <1371155525-sup-5029@qwerzila>
    133 
    134 Greetings,
    135 
    136 as briefly discussed in #75 [1] some adjustments to the original plan should
    137 be made. We were thinking:
    138 
    139   - Release another release in line-0.13 compatible with ruby 1.8 since
    140     we are starting to diverge in develop now. any efforts in fixing and
    141     maintaining ruby 1.8 support should be backported to this branch.
    142 
    143   - Work towards a 0.14 release with ruby 1.9 support on 'develop' and not
    144     necessarily with ruby 2.0 support yet. Already a several fixes have
    145     been done that have break ruby 1.8 which would be nice to get
    146     released in not too long.
    147 
    148 
    149 Any thoughts?
    150 
    151 
    152 Ruby 2.0: I am currently writing this from the tip of #61,
    153 rmail-to-mail-inital [2]. Having successfully indexed >30k (except 1..)
    154 of highly heterogeneous mails in all kinds of encodings. Tests are now
    155 also working, as well as sending email obviously. Still lots of parts are
    156 incomplete (e.g. no attachments yet..).
    157 
    158 The effort to get to a sup with ruby 2.0 support (with maildir-syncback,
    159 Mail - not RMail) has not reached a stable level. But I hope it could
    160 get to a state where it makes sense to include it in a separate branch
    161 in 'origin' so that it gets more available and easier to work against
    162 for everybody.
    163 
    164 Regards, Gaute
    165 
    166 [1] https://github.com/sup-heliotrope/sup/pull/75
    167 [2] https://github.com/sup-heliotrope/sup/pull/61
    168 
    169 
    170 From eg@gaute.vetsj.com  Fri Jun 21 12:07:19 2013
    171 From: eg@gaute.vetsj.com (Gaute Hope)
    172 Date: Fri, 21 Jun 2013 14:07:19 +0200
    173 Subject: [sup-devel] Release 0.13.1
    174 Message-ID: <1371816327-sup-6968@qwerzila>
    175 
    176 Greetings,
    177 
    178 I have just pushed version 0.13.1 of Sup to rubygems. This release holds
    179 should still be Ruby 1.8 compatible and holds the backported patches
    180 since the last release. 
    181 
    182 No big changes, but a number of fixes has been applied.
    183 
    184 Regards, Gaute
    185 
    186 
    187 From eg@gaute.vetsj.com  Sat Jun 22 10:48:13 2013
    188 From: eg@gaute.vetsj.com (Gaute Hope)
    189 Date: Sat, 22 Jun 2013 12:48:13 +0200
    190 Subject: [sup-devel] [sup-talk] Release 0.13.1
    191 In-Reply-To: <CA+ds9gJCfauTgS1LvrsOF0QREAKh9pKy=a550nj=1ZNi7wBvzA@mail.gmail.com>
    192 References: <1371816327-sup-6968@qwerzila>
    193 	<CA+ds9gJCfauTgS1LvrsOF0QREAKh9pKy=a550nj=1ZNi7wBvzA@mail.gmail.com>
    194 Message-ID: <1371897680-sup-4189@qwerzila>
    195 
    196 Excerpts from James Pearson's message of 2013-06-22 04:10:29 +0200:
    197 > I was going to ask why the tags on the Gitorious repo[0] hadn't been
    198 > updated, when I visited the (new!) website and saw that development has
    199 > moved onto Github[1] (and restarted!).  I'm apparently very behind the
    200 > times - and perhaps now I should dig out those changes I made and submit
    201 > them...
    202 > 
    203 > Glad to see things moving along again.
    204 >  - P
    205 > 
    206 > [0]: http://gitorious.org/sup/mainline
    207 > [1]: https://github.com/sup-heliotrope/sup
    208 
    209 Yup! Dig 'em up. We generally prefer pull requests [0] now a days. Also,
    210 we've collected contribution/development resources in the new wiki [1].
    211 
    212 
    213 I have asked William if he would agree to redirect to/mention the new setup
    214 in the old gitorious repo. He gave me access to the sup-team, but I am
    215 unfortunately not allowed to make any admin changes to the repository.
    216 
    217 
    218 Regards, Gaute
    219 
    220 
    221 [0] https://github.com/sup-heliotrope/sup/pulls
    222 [1] https://github.com/sup-heliotrope/sup/wiki/Development
    223 
    224 
    225 From eg@gaute.vetsj.com  Wed Jun 26 12:38:00 2013
    226 From: eg@gaute.vetsj.com (Gaute Hope)
    227 Date: Wed, 26 Jun 2013 14:38:00 +0200
    228 Subject: [sup-devel] Release Sup 0.13.2 and ncursesw-sup 1.3.1.3
    229 Message-ID: <1372250076-sup-9668@qwerzila>
    230 
    231 Greetings,
    232 
    233 another release in the 0.13-line. Together with a new release of
    234 ncursesw-sup with help from Steven Lawrance Sup should now work on
    235 FreeBSD 10 (a wiki page with more info is in the works).
    236 
    237 $ gem install ncursesw-sup
    238 $ gem install sup
    239 
    240 
    241 Thanks to all contributors!
    242 
    243 
    244 Cheers,
    245 Gaute
    246 
    247 
    248 From dmishd@gmail.com  Sun Jun 30 21:22:34 2013
    249 From: dmishd@gmail.com (Hamish D)
    250 Date: Sun, 30 Jun 2013 22:22:34 +0100
    251 Subject: [sup-devel] [sup-talk] Release 0.13.1
    252 In-Reply-To: <1371897680-sup-4189@qwerzila>
    253 References: <1371816327-sup-6968@qwerzila>
    254 	<CA+ds9gJCfauTgS1LvrsOF0QREAKh9pKy=a550nj=1ZNi7wBvzA@mail.gmail.com>
    255 	<1371897680-sup-4189@qwerzila>
    256 Message-ID: <CAOxvSbdps4S0g=iEANYpjEDvN6xy78+j_-ifvXaXU8TarN6BVg@mail.gmail.com>
    257 
    258 > I have asked William if he would agree to redirect to/mention the new setup
    259 > in the old gitorious repo. He gave me access to the sup-team, but I am
    260 > unfortunately not allowed to make any admin changes to the repository.
    261 >
    262 
    263 In lieu of anything better, I've updated the readme.txt in the gitorious
    264 copy, but I can't edit the description either.
    265 
    266 Hamish
    267 
    268 
    269 >
    270 >
    271 > Regards, Gaute
    272 >
    273 >
    274 > [0] https://github.com/sup-heliotrope/sup/pulls
    275 > [1] https://github.com/sup-heliotrope/sup/wiki/Development
    276 >
    277 > _______________________________________________
    278 > Sup-devel mailing list
    279 > Sup-devel at rubyforge.org
    280 > http://rubyforge.org/mailman/listinfo/sup-devel
    281 >
    282 -------------- next part --------------
    283 An HTML attachment was scrubbed...
    284 URL: <http://rubyforge.org/pipermail/sup-devel/attachments/20130630/f7daad95/attachment.html>
    285