From mboxrd@z Thu Jan 1 00:00:00 1970 X-Msuck: nntp://news.gmane.io/gmane.emacs.gnus.general/62900 Path: news.gmane.org!not-for-mail From: Simon Josefsson Newsgroups: gmane.emacs.gnus.general Subject: Re: nnimap: gnus-gcc-mark-as-read not working Date: Tue, 18 Apr 2006 12:34:26 +0200 Message-ID: <87lku3rx3h.fsf@latte.josefsson.org> References: <86sloh3ua8.fsf@student.uni-magdeburg.de> <86ek0036wb.fsf@student.uni-magdeburg.de> NNTP-Posting-Host: main.gmane.org Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii X-Trace: sea.gmane.org 1145356513 3687 80.91.229.2 (18 Apr 2006 10:35:13 GMT) X-Complaints-To: usenet@sea.gmane.org NNTP-Posting-Date: Tue, 18 Apr 2006 10:35:13 +0000 (UTC) Cc: ding@gnus.org Original-X-From: ding-owner+m11427@lists.math.uh.edu Tue Apr 18 12:35:12 2006 Return-path: Envelope-to: ding-account@gmane.org Original-Received: from malifon.math.uh.edu ([129.7.128.13]) by ciao.gmane.org with esmtp (Exim 4.43) id 1FVnY5-0005hr-KG for ding-account@gmane.org; Tue, 18 Apr 2006 12:35:10 +0200 Original-Received: from localhost ([127.0.0.1] helo=lists.math.uh.edu ident=lists) by malifon.math.uh.edu with smtp (Exim 3.20 #1) id 1FVnXz-0003l0-00; Tue, 18 Apr 2006 05:35:03 -0500 Original-Received: from nas01.math.uh.edu ([129.7.128.39]) by malifon.math.uh.edu with esmtp (Exim 3.20 #1) id 1FVnXb-0003kv-00 for ding@lists.math.uh.edu; Tue, 18 Apr 2006 05:34:39 -0500 Original-Received: from quimby.gnus.org ([80.91.224.244]) by nas01.math.uh.edu with esmtp (Exim 4.52) id 1FVnXX-0001P0-67 for ding@lists.math.uh.edu; Tue, 18 Apr 2006 05:34:39 -0500 Original-Received: from 178.230.13.217.in-addr.dgcsystems.net ([217.13.230.178] helo=yxa.extundo.com) by quimby.gnus.org with esmtp (Exim 3.35 #1 (Debian)) id 1FVnXW-0008OD-00 for ; Tue, 18 Apr 2006 12:34:34 +0200 Original-Received: from localhost.localdomain (yxa.extundo.com [217.13.230.178]) (authenticated bits=0) by yxa.extundo.com (8.13.4/8.13.4/Debian-3sarge1) with ESMTP id k3IAYQmc009750; Tue, 18 Apr 2006 12:34:29 +0200 Original-To: Wolfram Fenske OpenPGP: id=B565716F; url=http://josefsson.org/key.txt X-Hashcash: 1:21:060418:ding@gnus.org::ju7tH2q+59vaLktR:1MgQ X-Hashcash: 1:21:060418:wolfram.fenske@student.uni-magdeburg.de::+fEOf4GYGF4bCMP5:A2JI In-Reply-To: <86ek0036wb.fsf@student.uni-magdeburg.de> (Wolfram Fenske's message of "Fri, 14 Apr 2006 10:20:36 +0200") User-Agent: Gnus/5.110005 (No Gnus v0.5) Emacs/22.0.50 (gnu/linux) X-Spam-Status: No, score=-2.5 required=5.0 tests=AWL,BAYES_00, FORGED_RCVD_HELO autolearn=ham version=3.1.0 X-Spam-Checker-Version: SpamAssassin 3.1.0 (2005-09-13) on yxa-iv X-Virus-Scanned: ClamAV version 0.88, clamav-milter version 0.87 on yxa.extundo.com X-Virus-Status: Clean X-Spam-Score: -2.5 (--) Precedence: bulk Original-Sender: ding-owner@lists.math.uh.edu Xref: news.gmane.org gmane.emacs.gnus.general:62900 Archived-At: Wolfram Fenske writes: > Wolfram Fenske writes: > >> Hello! >> >> I have sent mail Gcc-ed to a folder on my IMAP-server. This mostly >> works, but the copy in the sent-mail folder is never marked as read. >> In my .gnus.el I have: >> >> --8<---------------cut here---------------start------------->8--- >> (setq gnus-message-archive-group "nnimap+uni:INBOX.sent-mail" >> gnus-gcc-mark-as-read t) >> --8<---------------cut here---------------end--------------->8--- >> >> If I use nnfolder [...], archiving works as it should. > > I've tracked it down. The error occurs here: > > (defun gnus-group-make-articles-read (group articles) > "Update the info of GROUP to say that ARTICLES are read." > (let* ((num 0) > (entry (gnus-gethash group gnus-newsrc-hashtb)) > ... ; some more initializing > (when entry > ... ; do all the work > > For my IMAP sent-mail group, "entry" is always "nil" because "group" > is "nnimap+uni:INBOX.sent-mail" but my ~/.newsrc.eld contains only > entries like "INBOX.sent-mail", i. e. the prefix "nnimap+uni:" is > missing. Doesn't it work to simply drop the 'nnimap+uni:' part above? > Now the question is: why don't I have the prefixes in ~/.newsrc.eld? > Is this because nnimap is my primary gnus-select-method? A while back > I had nnimap as my secondary select method and I think I didn't have > this problem then. > > Also: is there a bug in "gnus-group-make-articles-read" or is it my > config? I tought > > (setq gnus-message-archive-method '(nnimap "my.imap.server.de") > gnus-message-archive-group "INBOX.sent-mail") > > might do the trick, but this didn't fix it, either. > > If there really is a bug, and someone can tell me what's going on with > those prefixes, I'd be happy to write a patch. Until then, I'm using > this workaround: I've found that the easiest is to use a nnnil method as the primary method, and then have all methods being equal. > *** gnus-sum.el.orig Fri Apr 14 08:01:20 2006 > --- gnus-sum.el Fri Apr 14 10:04:05 2006 > *************** > *** 5744,5749 **** > --- 5744,5754 ---- > "Update the info of GROUP to say that ARTICLES are read." > (let* ((num 0) > (entry (gnus-gethash group gnus-newsrc-hashtb)) > + (entry (or entry > + ;; strip the backend prefix and try again > + (when (string-match "\\([^+]+\\+[^:]+:\\)?\\(.+\\)" group) > + (setq group (match-string 2 group)) > + (gnus-gethash group gnus-newsrc-hashtb)))) > (info (nth 2 entry)) > (active (gnus-active group)) > range) > > > Regards > Wolfram > > -- > A: Yes. >>Q: Are you sure? >>>A: Because it reverses the logical flow of conversation. >>>>Q: Why is top posting frowned upon?