From mboxrd@z Thu Jan 1 00:00:00 1970 X-Spam-Checker-Version: SpamAssassin 3.4.4 (2020-01-24) on inbox.vuxu.org X-Spam-Level: X-Spam-Status: No, score=-1.1 required=5.0 tests=DKIM_ADSP_CUSTOM_MED, DKIM_INVALID,DKIM_SIGNED,FORGED_GMAIL_RCVD,FREEMAIL_FROM, RCVD_IN_DNSWL_MED,RCVD_IN_MSPIKE_H3,RCVD_IN_MSPIKE_WL autolearn=ham autolearn_force=no version=3.4.4 Received: (qmail 7388 invoked from network); 21 Jan 2021 17:02:53 -0000 Received: from mx1.math.uh.edu (129.7.128.32) by inbox.vuxu.org with ESMTPUTF8; 21 Jan 2021 17:02:53 -0000 Received: from lists1.math.uh.edu ([129.7.128.208]) by mx1.math.uh.edu with esmtps (TLS1.3) tls TLS_AES_256_GCM_SHA384 (Exim 4.94) (envelope-from ) id 1l2dM9-001hJZ-GU for ml@inbox.vuxu.org; Thu, 21 Jan 2021 11:02:49 -0600 Received: from localhost ([127.0.0.1] helo=lists.math.uh.edu) by lists1.math.uh.edu with smtp (Exim 4.94) (envelope-from ) id 1l2dM8-007crh-UI for ml@inbox.vuxu.org; Thu, 21 Jan 2021 11:02:48 -0600 Received: from mx1.math.uh.edu ([129.7.128.32]) by lists1.math.uh.edu with esmtps (TLS1.3) tls TLS_AES_256_GCM_SHA384 (Exim 4.94) (envelope-from ) id 1l2dM6-007crZ-NT for ding@lists.math.uh.edu; Thu, 21 Jan 2021 11:02:46 -0600 Received: from quimby.gnus.org ([95.216.78.240]) by mx1.math.uh.edu with esmtps (TLS1.3) tls TLS_AES_256_GCM_SHA384 (Exim 4.94) (envelope-from ) id 1l2dM4-001hJH-BX for ding@lists.math.uh.edu; Thu, 21 Jan 2021 11:02:46 -0600 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=gnus.org; s=20200322; h=Content-Transfer-Encoding:Content-Type:Mime-Version:References :Message-ID:Date:Subject:From:To:Sender:Reply-To:Cc:Content-ID: Content-Description:Resent-Date:Resent-From:Resent-Sender:Resent-To:Resent-Cc :Resent-Message-ID:In-Reply-To:List-Id:List-Help:List-Unsubscribe: List-Subscribe:List-Post:List-Owner:List-Archive; bh=Wq5+BEp+5HCsyoXWWYwZ1o5Smfb5nCFY0e4Xh0mTj90=; b=sHvrGyM12A+5WCXt8y9aspDV2Q YQpLBmgUrJ0gNA4Dw0Y/8cassg3QcTSIOsd6Ld+PW0X8mYwTguc0wo2Iu5dGRf1Va/QSt60XsVouM s1ZIlnn3MfXAlwjgRn/mKGGe/bJY5cRPaHesPzOXeEJ3qtmPvcQGYVKMr8xdRRa9LD5o=; Received: from ciao.gmane.io ([116.202.254.214]) by quimby.gnus.org with esmtps (TLS1.3:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1l2dLw-00079n-VU for ding@gnus.org; Thu, 21 Jan 2021 18:02:39 +0100 Received: from list by ciao.gmane.io with local (Exim 4.92) (envelope-from ) id 1l2dLw-0005gv-Ha for ding@gnus.org; Thu, 21 Jan 2021 18:02:36 +0100 X-Injected-Via-Gmane: http://gmane.org/ To: ding@gnus.org From: Juan =?utf-8?Q?Jos=C3=A9_Garc=C3=ADa-Ripoll?= Subject: Re: Missing first group in group list Date: Thu, 21 Jan 2021 18:02:30 +0100 Organization: Institute of Fundamental Physics, CSIC Message-ID: <86v9bqw7dl.fsf@csic.es> References: <864kjay24j.fsf@csic.es> <87h7natsaq.fsf@igel.home> Mime-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/27.1.90 (windows-nt) Cancel-Lock: sha1:sjlJkPIePCaYAady2gsNL9B890s= List-ID: Precedence: bulk Andreas Schwab writes: > On Jan 21 2021, Juan José García-Ripoll wrote: > >> Essentially the problem is in this function >> >> (defun gnus-group-prepare-flat (level &optional predicate lowest regexp) >> ... >> ;; List living groups, according to order in `gnus-group-list'. >> (dolist (g (cdr gnus-group-list)) >> (setq info (gnus-get-info g) >> group (gnus-info-group info) >> >> This function drops the first group in the list, probably because it >> assumes it is the dummy.group, but in my system it is never so. > > It looks like Gnus always tries to keep dummy.group at the head of the > group list, see the various references in gnus-start.el or > gnus-group.el. Hmmm, not really. I've debugged the gnus-group-list variable and it is changed twice: once to add dummy.group, and another one to add the subsequent group, in a chain of calls that starts in gnus-subscribe-group. The problem is this code: (defun gnus-subscribe-newsgroup (newsgroup &optional next) "Subscribe new NEWSGROUP. If NEXT is non-nil, it is inserted before NEXT. Otherwise it is made the first newsgroup." (save-excursion (goto-char (point-min)) ;; We subscribe the group by changing its level to `subscribed'. (gnus-group-change-level newsgroup gnus-level-default-subscribed gnus-level-killed (or next "dummy.group")) It is called like (gnus-subscribe-newsgroup "The-new-group" "dummy.group") Note that by default NEXT is nil. This means that the next group that is inserted will be injected _before_ dummy.group and the order is destroyed. Cheers, -- Juan José García Ripoll http://juanjose.garciaripoll.com http://quinfog.hbar.es