From mboxrd@z Thu Jan 1 00:00:00 1970 X-Msuck: nntp://news.gmane.io/gmane.emacs.gnus.general/69454 Path: news.gmane.org!not-for-mail From: Ted Zlatanov Newsgroups: gmane.emacs.gnus.general Subject: Re: Patch: Support for non-ascii characters in imap group names Date: Mon, 22 Mar 2010 05:16:05 -0500 Organization: =?utf-8?B?0KLQtdC+0LTQvtGAINCX0LvQsNGC0LDQvdC+0LI=?= @ Cienfuegos Message-ID: <871vfcveze.fsf@lifelogs.com> References: <7mljev50dc.fsf@kolon.stjernholm.org> <7m635qutf5.fsf@kolon.stjernholm.org> <87zl23dmiy.fsf@lifelogs.com> <7m1vfdmwxk.fsf@kolon.stjernholm.org> <87iq8p7bni.fsf@lifelogs.com> <7miq8pl8uz.fsf@kolon.stjernholm.org> NNTP-Posting-Host: lo.gmane.org Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii X-Trace: dough.gmane.org 1269253009 27833 80.91.229.12 (22 Mar 2010 10:16:49 GMT) X-Complaints-To: usenet@dough.gmane.org NNTP-Posting-Date: Mon, 22 Mar 2010 10:16:49 +0000 (UTC) Cc: ding@gnus.org To: Martin Stjernholm Original-X-From: ding-owner+M17849@lists.math.uh.edu Mon Mar 22 11:16:45 2010 Return-path: Envelope-to: ding-account@gmane.org Original-Received: from util0.math.uh.edu ([129.7.128.18]) by lo.gmane.org with esmtp (Exim 4.69) (envelope-from ) id 1Ntegf-0001ek-CI for ding-account@gmane.org; Mon, 22 Mar 2010 11:16:45 +0100 Original-Received: from localhost ([127.0.0.1] helo=lists.math.uh.edu) by util0.math.uh.edu with smtp (Exim 4.63) (envelope-from ) id 1Nteg8-0000qW-B2; Mon, 22 Mar 2010 05:16:12 -0500 Original-Received: from mx2.math.uh.edu ([129.7.128.33]) by util0.math.uh.edu with esmtps (TLSv1:AES256-SHA:256) (Exim 4.63) (envelope-from ) id 1Nteg6-0000qJ-3d for ding@lists.math.uh.edu; Mon, 22 Mar 2010 05:16:10 -0500 Original-Received: from quimby.gnus.org ([80.91.231.51]) by mx2.math.uh.edu with esmtp (Exim 4.69) (envelope-from ) id 1Nteg4-000107-Fw for ding@lists.math.uh.edu; Mon, 22 Mar 2010 05:16:10 -0500 Original-Received: from blockstar.com ([208.100.47.114] helo=mail.blockstar.com) by quimby with esmtp (Exim 3.36 #1 (Debian)) id 1Ntfc8-0006jA-00 for ; Mon, 22 Mar 2010 12:16:08 +0100 Original-Received: from heechee (c-98-227-29-141.hsd1.il.comcast.net [98.227.29.141]) by mail.blockstar.com (Postfix) with ESMTP id 826CBA68653; Mon, 22 Mar 2010 05:16:08 -0500 (CDT) X-Face: bd.DQ~'29fIs`T_%O%C\g%6jW)yi[zuz6;d4V0`@y-~$#3P_Ng{@m+e4o<4P'#(_GJQ%TT= D}[Ep*b!\e,fBZ'j_+#"Ps?s2!4H2-Y"sx" In-Reply-To: <7miq8pl8uz.fsf@kolon.stjernholm.org> (Martin Stjernholm's message of "Sun, 21 Mar 2010 21:26:12 +0100") User-Agent: Gnus/5.110011 (No Gnus v0.11) Emacs/24.0.50 (gnu/linux) X-Spam-Score: -2.6 (--) List-ID: Precedence: bulk Xref: news.gmane.org gmane.emacs.gnus.general:69454 Archived-At: On Sun, 21 Mar 2010 21:26:12 +0100 Martin Stjernholm wrote: MS> Ted Zlatanov wrote: >> I haven't seen it (which is probably my fault as I was not paying >> attention), can you please resend and CC me? MS> Sure, it's attached below. For me it makes the startup time go down from MS> 5 minutes or more to 10-20 seconds when I start up Gnus with my ~140 MS> imap groups over a slow mobile network. The thing is that MS> nnimap-retrieve-groups is very sensitive to high latency. The patch MS> doesn't remedy that, but it cuts down the number of groups it polls. The patch looks good and did not break anything for me so I added it. We're still in CVS land so I didn't commit your changes individually but as one big patch to avoid 3 separate commits. >> Interesting. It sounds like we should get rid of the variable in code >> completely and always use an accessor function with a "decoding" >> parameter (so we can get the encoded or the unencoded name). I don't >> like the current hidden behavior. Do you agree? MS> You're right, using the variable instead in situations where the MS> encoding isn't relevant is arguably a sort of micro-optimization. It MS> shouldn't be a significant performance hit to use the function instead. MS> Or if it is, the right solution would be to optimize in imap.el by MS> keeping the decoded mailbox name in a variable. MS> I don't really see the point with adding a "decoding" parameter though. MS> The utf-7 encoding is just for transport in the imap protocol, and I MS> can't see any reason why higher code would be interested in that. If MS> anything, it'd be reasonable to change imap-current-mailbox (and MS> possibly other variables) to contain decoded mailbox names instead, but MS> that'd of course have compatibility implications which probably don't MS> make it worth the hassle. Only nnimap.el and imap.el use it directly so I think it's OK to change it. mail-source.el and nnir.el also may need a slight adjustment for their use of imap-mailbox-*. It would simplify the code a little and make the variable more sensible IMO (but if anyone else disagrees, please speak up). If you or anyone else is interested in doing it as you propose, keeping the decoded variable and encoding it on the fly, go ahead. Ted