info-gnus-english
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Gnus fetch freezes emacs


From: Stephen Berman
Subject: Re: Gnus fetch freezes emacs
Date: Fri, 30 Jun 2023 21:33:08 +0200
User-agent: Gnus/5.13 (Gnus v5.13)

On Fri, 30 Jun 2023 20:03:11 +0530 Prashant Tak <prashantrameshtak@gmail.com> 
wrote:

> Gnus has been freezing sporadically when `gnus-group-get-new-news` is run.
> And it keeps on going for hours, I have to manually intercept and signal
> `keyboard-quit` and then perform the fetch operation again. This happens
> in a very unpredictable manner, so it's hard to replicate. I did manage
> to get a profiler report when that happened.
>
>         7367  99% - command-execute
>         7367  99%  - call-interactively
>         7070  95%   - funcall-interactively
>         7070  95%    - gnus-group-get-new-news
>         7063  95%     - gnus-get-unread-articles
>         7063  95%      - gnus-read-active-for-groups
>         7063  95%       - gnus-finish-retrieve-group-infos
>         7063  95%        - nntp-finish-retrieve-group-infos
>         7063  95%         - nntp-with-open-group-function
>         6851  92%          - #<compiled -0x1643a6a03cf748e>
>         6416  86%           - nntp-accept-response
>         6068  82%            - nntp-accept-process-output
>         5873  79%             - nnheader-accept-process-output
>           19   0%              + accept-process-output
>           34   0%               nntp-find-connection-buffer
>            7   0%       gnus-parent-read-child-newsrc
>          297   4%   - byte-code
>          297   4%    + read-extended-command
>           15   0% + ...
>
> The main culprit seems to be `nnheader-accept-process-output` but I
> don't know how to proceed further. Appreciate any help/input into the matter.

This sounds like the issue I've been having with gnus-group-get-new-news
and similar Gnus commands for more than a year and a half, see
bug#52735.  As reported there, I did some debugging but couldn't
pinpoint the problem, nor have I tried profiling yet.  But as a
workaround, I've been using the following replacement for
gnus-group-get-new-news:

(defun srb-gnus-group-get-new-news (&optional arg one-level)
  (interactive "P")
  (with-timeout (1 (kill-buffer (nntp-find-connection-buffer 
nntp-server-buffer))
                   (gnus-group-get-new-news))
    (gnus-group-get-new-news arg one-level)))

(define-key gnus-group-mode-map "g" 'srb-gnus-group-get-new-news)

This usually suffices but not always.  When Gnus (and hence Emacs) hangs
even when using this workaround, I've resorted to manually killing the
server buffer " *server news.gmane.io nntp *nntpd**" and then typing `g'
pretty reliably works again.

This is a very annoying issue, and if what you're experiencing is the
same, I commiserate with you, but your report also gives me hope that
it's not just some quirk of my setup or network connection.  Now we just
need some Gnus expert to chime in and guide us to try and track down the
cause of this issue and get it fixed.

Steve Berman



reply via email to

[Prev in Thread] Current Thread [Next in Thread]