Gnus development mailing list
 help / color / mirror / Atom feed
From: Daiki Ueno <ueno@gnu.org>
To: Lars Ingebrigtsen <larsi@gnus.org>
Cc: Andreas Schwab <schwab@linux-m68k.org>,  ding@gnus.org
Subject: Re: M-g doesn't work with gnus-no-server
Date: Tue, 09 Feb 2016 17:42:53 +0900	[thread overview]
Message-ID: <m3egcml1f6.fsf-ueno@gnu.org> (raw)
In-Reply-To: <87fux3eohi.fsf@gnus.org> (Lars Ingebrigtsen's message of "Mon, 08 Feb 2016 16:54:17 +1100")

[-- Attachment #1: Type: text/plain, Size: 1829 bytes --]

Lars Ingebrigtsen <larsi@gnus.org> writes:

> Daiki Ueno <ueno@gnu.org> writes:
>
>> Lars Ingebrigtsen <larsi@gnus.org> writes:
>>
>>> Debugger entered--Lisp error: (error "Unknown service: 993")
>>>   make-network-process(:name "*nnimap*" :buffer #<buffer *nnimap nil
>>> nil *nntpd**-409419> :host nil :service "993" :nowait nil)
>>>
>>> [...]
>>>
>>>   nnimap-change-group(nil "server")
>>>
>>> Still the literal string "server", which surely has to be wrong...
>
> [...]
>
>>       gnus-secondary-select-methods
>>       '((nnimap "server"
>> 		(nnimap-address "......")
>> 		(nnir-search-engine imap))))
>
> Oh, your nnimap server is actually called "server".  :-)  Then the
>
>>>   nnimap-change-group(nil "server")
>
> part of the backtrace is as it should be.  I think.  But the right
> nnimap-address still isn't set.  Hm...

I had a bit closer look at this, comparing the backtraces taken from
24.5 (works ok) and the git master (doesn't work).

The call sequences until `nnimap-open-server' are:

24.5:
  gnus-group-get-new-news-this-group
    -> gnus-activate-group
      -> gnus-open-server
        -> nnimap-open-server

master:
  gnus-group-get-new-news-this-group
    -> gnus-request-group-scan
      -> nnimap-request-group-scan
        -> nnimap-change-group
          -> nnimap-open-server

In the former case, `nnimap-open-server' is called with an alist entry
containing `nnimap-address', etc., while in the latter case, the
function takes "server", nil, nil.

So I guess a simple work around would be to replicate the same sequence
starting from `gnus-activate-group', if server is not opened.

Does the attached patch look correct?

To be honest, this issue is no longer priority for myself, since I
changed my habit to always use M-x gnus, as nnimap is fast enough these
days :-)

Regards,
-- 
Daiki Ueno

[-- Warning: decoded text below may be mangled, UTF-8 assumed --]
[-- Attachment #2: 0001-gnus-Make-M-g-work-with-gnus-no-server.patch --]
[-- Type: text/x-patch, Size: 951 bytes --]

From e1d28517a47b6b2fb4e820d5a2b9e12f2087366a Mon Sep 17 00:00:00 2001
From: Daiki Ueno <ueno@gnu.org>
Date: Tue, 9 Feb 2016 17:37:59 +0900
Subject: [PATCH] gnus: Make M-g work with gnus-no-server

* lisp/gnus/gnus-group.el: Don't call `gnus-request-group-scan' if
server is not opened.
---
 lisp/gnus/gnus-group.el | 1 +
 1 file changed, 1 insertion(+)

diff --git a/lisp/gnus/gnus-group.el b/lisp/gnus/gnus-group.el
index 1cd16a4..4e1efab 100644
--- a/lisp/gnus/gnus-group.el
+++ b/lisp/gnus/gnus-group.el
@@ -4110,6 +4110,7 @@ gnus-group-get-new-news-this-group
       ;; Bypass any previous denials from the server.
       (gnus-remove-denial (setq method (gnus-find-method-for-group group)))
       (if (or (and (not dont-scan)
+		   (gnus-server-opened method)
 		   (gnus-request-group-scan group (gnus-get-info group)))
 	      (gnus-activate-group group (if dont-scan nil 'scan) nil method))
 	  (let ((info (gnus-get-info group))
-- 
2.5.0


  reply	other threads:[~2016-02-09  8:42 UTC|newest]

Thread overview: 17+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2015-03-17  9:06 Daiki Ueno
2015-04-17 20:00 ` Ted Zlatanov
2016-02-07  3:02 ` Lars Ingebrigtsen
2016-02-07  8:54   ` Andreas Schwab
2016-02-07  9:26   ` Andreas Schwab
2016-02-07 12:32   ` Andreas Schwab
2016-02-07 18:03     ` Daiki Ueno
2016-02-07 18:27       ` Dave Goldberg
2016-02-08  5:10       ` Lars Ingebrigtsen
2016-02-08  5:47         ` Daiki Ueno
2016-02-08  5:54           ` Lars Ingebrigtsen
2016-02-09  8:42             ` Daiki Ueno [this message]
2016-02-09 23:34               ` Lars Ingebrigtsen
2016-02-10  4:20                 ` Daiki Ueno
2016-02-12 10:47                   ` Andreas Schwab
2016-02-13  6:43                   ` Lars Ingebrigtsen
2016-02-13  7:21                     ` Daiki Ueno

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=m3egcml1f6.fsf-ueno@gnu.org \
    --to=ueno@gnu.org \
    --cc=ding@gnus.org \
    --cc=larsi@gnus.org \
    --cc=schwab@linux-m68k.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).