Gnus development mailing list
 help / color / mirror / Atom feed
From: Ralf Angeli <dev.null@iwi.uni-sb.de>
Subject: Re: Gnus losing information about what has been read
Date: Fri, 24 Sep 2004 18:30:08 +0200	[thread overview]
Message-ID: <cj1hun$2gb$1@sea.gmane.org> (raw)
In-Reply-To: <uu0tn4wer.fsf@vignette.com>

* Kevin Greiner (2004-09-24) writes:

> Are you willing/able to do a little lisp debugging for me?

Sure. (c:

> If so,
> please do the following:
> 1) Run gnus as you've described up to the point where you've seen
> the 'Added to ... agent.lib/flags' message.
> 2) Start a new emacs process.

I suppose that involves closing Gnus and Emacs and starting both
again.

> 3) Do M-x load-library<ret>gnus-agent.el<ret>
> 4) Do M-x debug-on-entry<ret>gnus-agent-possibly-synchronize-flags<ret>
> 5) Do M-x gnus
>
> The questions that I need you to answer are:

Below you can find the contents of the debugging window at the various
stages.  If I got them wrong please tell me and I'll try to provide
the right ones.  Note that the backtraces for questions 1) and 2) are
from a different session than the ones for questions 3) and 4).  As
the problem didn't change, I hope it is not significant.  I just had
to try several times until I got it right.

> 1) Is gnus-agent-possibly-synchronize-flags being called?  That is, do
>    you ever drop into the debugger?

Yes.

Debugger entered--entering a function:
* gnus-agent-possibly-synchronize-flags()
  (cond ((eq set-to gnus-plugged) nil) (set-to (setq gnus-plugged set-to) (gnus-run-hooks ...) (setcar ... ...) (gnus-agent-go-online gnus-agent-go-online) (gnus-agent-possibly-synchronize-flags)) (t (gnus-agent-close-connections) (setq gnus-plugged set-to) (gnus-run-hooks ...) (setcar ... ...)))
  gnus-agent-toggle-plugged(t)
  (let ((init-plugged gnus-plugged) (gnus-agent-go-online nil)) (setq gnus-plugged :unknown) (gnus-agent-toggle-plugged init-plugged))
  (progn (let (... ...) (setq gnus-plugged :unknown) (gnus-agent-toggle-plugged init-plugged)))
  (if (eq major-mode (quote gnus-group-mode)) (progn (let ... ... ...)))
  (when (eq major-mode (quote gnus-group-mode)) (let (... ...) (setq gnus-plugged :unknown) (gnus-agent-toggle-plugged init-plugged)))
  (let* ((buffer ...) (mode ...)) (set (make-local-variable ...) t) (set mode nil) (set (make-local-variable mode) t) (when (gnus-visual-p ... ...) (funcall ...)) (unless (assq ... minor-mode-alist) (push gnus-agent-mode-status minor-mode-alist)) (unless (assq mode minor-mode-map-alist) (push ... minor-mode-map-alist)) (when (eq major-mode ...) (let ... ... ...)) (gnus-run-hooks (quote gnus-agent-mode-hook) (intern ...)))
  gnus-agent-mode()
  run-hooks(gnus-group-mode-hook)
  apply(run-hooks gnus-group-mode-hook)
  gnus-run-hooks(gnus-group-mode-hook)
  gnus-group-mode()
  gnus-group-setup-buffer()
  gnus-group-list-groups(nil)
[byte-code stripped]
  gnus-1(nil nil nil)
  gnus(nil)
  call-interactively(gnus)
  execute-extended-command(nil)
  call-interactively(execute-extended-command)

> 2) As you step through the execution.  You should see where gnus
>    checks for the existence of the agent.lib/flags file.  There's one
>    file for each server.  Does gnus check specifically for the
>    news.gmane.org server's file?

I tested with news.individual.net:

Debugger entered--returning value: "/home/angeli/News/agent/nntp/news.individual.net/agent.lib/flags"
  expand-file-name("flags" "/home/angeli/News/agent/nntp/news.individual.net/agent.lib/")
* gnus-agent-lib-file("flags")
* (file-exists-p (gnus-agent-lib-file "flags"))
* (if (file-exists-p (gnus-agent-lib-file "flags")) (progn (gnus-agent-possibly-synchronize-flags-server gnus-command-method)))
* (when (file-exists-p (gnus-agent-lib-file "flags")) (gnus-agent-possibly-synchronize-flags-server gnus-command-method))
* (while --dolist-temp--21402 (setq gnus-command-method (car --dolist-temp--21402)) (when (file-exists-p ...) (gnus-agent-possibly-synchronize-flags-server gnus-command-method)) (setq --dolist-temp--21402 (cdr --dolist-temp--21402)))
* (let ((--dolist-temp--21402 ...) gnus-command-method) (while --dolist-temp--21402 (setq gnus-command-method ...) (when ... ...) (setq --dolist-temp--21402 ...)) nil)
* (catch (quote --cl-block-nil--) (let (... gnus-command-method) (while --dolist-temp--21402 ... ... ...) nil))
* (cl-block-wrapper (catch (quote --cl-block-nil--) (let ... ... nil)))
* (block nil (let (... gnus-command-method) (while --dolist-temp--21402 ... ... ...) nil))
* (dolist (gnus-command-method (gnus-agent-covered-methods)) (when (file-exists-p ...) (gnus-agent-possibly-synchronize-flags-server gnus-command-method)))
* (save-excursion (dolist (gnus-command-method ...) (when ... ...)))
* gnus-agent-possibly-synchronize-flags()

> 3) If the file is found, gnus will attempt to open the server.  Does
>    that open succeed?

Debugger entered--returning value: open
  process-status(#<process nntpd>)
* nntp-open-server("news.individual.net" nil)
[byte-code stripped]
* gnus-open-server((nntp "news.individual.net"))
[byte-code stripped]
* gnus-check-server((nntp "news.individual.net"))
* (null (gnus-check-server gnus-command-method))
* (cond ((null gnus-plugged) (gnus-message 1 "You must be plugged to synchronize flags with server %s" ...)) ((null ...) (gnus-message 1 "Couldn't open server %s" ...)) (t (while ... ...) (delete-file ...)))
* (progn (set-buffer (get-buffer-create " *Gnus Agent flag synchronize*")) (erase-buffer) (nnheader-insert-file-contents (gnus-agent-lib-file "flags")) (cond (... ...) (... ...) (t ... ...)) (kill-buffer nil))
* (if (file-exists-p (gnus-agent-lib-file "flags")) (progn (set-buffer ...) (erase-buffer) (nnheader-insert-file-contents ...) (cond ... ... ...) (kill-buffer nil)))
* (when (file-exists-p (gnus-agent-lib-file "flags")) (set-buffer (get-buffer-create " *Gnus Agent flag synchronize*")) (erase-buffer) (nnheader-insert-file-contents (gnus-agent-lib-file "flags")) (cond (... ...) (... ...) (t ... ...)) (kill-buffer nil))
* (let ((gnus-command-method method) (gnus-agent nil)) (when (file-exists-p ...) (set-buffer ...) (erase-buffer) (nnheader-insert-file-contents ...) (cond ... ... ...) (kill-buffer nil)))
* gnus-agent-synchronize-flags-server((nntp "news.individual.net"))
* (progn (gnus-agent-synchronize-flags-server method))
* (if (or (and gnus-agent-synchronize-flags ...) (and ... ...)) (progn (gnus-agent-synchronize-flags-server method)))
* (when (or (and gnus-agent-synchronize-flags ...) (and ... ...)) (gnus-agent-synchronize-flags-server method))
* gnus-agent-possibly-synchronize-flags-server((nntp "news.individual.net"))
* (progn (gnus-agent-possibly-synchronize-flags-server gnus-command-method))
* (if (file-exists-p (gnus-agent-lib-file "flags")) (progn (gnus-agent-possibly-synchronize-flags-server gnus-command-method)))
* (when (file-exists-p (gnus-agent-lib-file "flags")) (gnus-agent-possibly-synchronize-flags-server gnus-command-method))
* (while --dolist-temp--20402 (setq gnus-command-method (car --dolist-temp--20402)) (when (file-exists-p ...) (gnus-agent-possibly-synchronize-flags-server gnus-command-method)) (setq --dolist-temp--20402 (cdr --dolist-temp--20402)))
* (let ((--dolist-temp--20402 ...) gnus-command-method) (while --dolist-temp--20402 (setq gnus-command-method ...) (when ... ...) (setq --dolist-temp--20402 ...)) nil)
* (catch (quote --cl-block-nil--) (let (... gnus-command-method) (while --dolist-temp--20402 ... ... ...) nil))
* (cl-block-wrapper (catch (quote --cl-block-nil--) (let ... ... nil)))
* (block nil (let (... gnus-command-method) (while --dolist-temp--20402 ... ... ...) nil))
* (dolist (gnus-command-method (gnus-agent-covered-methods)) (when (file-exists-p ...) (gnus-agent-possibly-synchronize-flags-server gnus-command-method)))
* (save-excursion (dolist (gnus-command-method ...) (when ... ...)))
* gnus-agent-possibly-synchronize-flags()

> 4) Finally, a (eval (read (current-buffer))) expression is performed
>    several times.  Does it seem to return normally or does it signal
>    an error?

Nope.  Here are some partial backtraces at various stages of
execution:

Debugger entered--returning value: (nntp-request-set-mark "comp.text.tex" (quote ((((311807 . 311810)) add (read)))) "news.individual.net")
  read(#<buffer  *Gnus Agent flag synchronize*>)
* (eval (read (current-buffer)))
* (null (eval (read ...)))
* (if (null (eval ...)) (gnus-delete-line) (write-file (gnus-agent-lib-file "flags")) (error "Couldn't set flags from file %s" (gnus-agent-lib-file "flags")))
* (while (not (eobp)) (if (null ...) (gnus-delete-line) (write-file ...) (error "Couldn't set flags from file %s" ...)))

...later...

Debugger entered--beginning evaluation of function call form:
* (nntp-request-set-mark "comp.text.tex" (quote (...)) "news.individual.net")
* eval((nntp-request-set-mark "comp.text.tex" (quote (...)) "news.individual.net"))
* (null (eval (read ...)))
* (if (null (eval ...)) (gnus-delete-line) (write-file (gnus-agent-lib-file "flags")) (error "Couldn't set flags from file %s" (gnus-agent-lib-file "flags")))
* (while (not (eobp)) (if (null ...) (gnus-delete-line) (write-file ...) (error "Couldn't set flags from file %s" ...)))

...even later...

Debugger entered--returning value: t
  null(nil)
* (if (null (eval ...)) (gnus-delete-line) (write-file (gnus-agent-lib-file "flags")) (error "Couldn't set flags from file %s" (gnus-agent-lib-file "flags")))
* (while (not (eobp)) (if (null ...) (gnus-delete-line) (write-file ...) (error "Couldn't set flags from file %s" ...)))

-- 
Ralf




  parent reply	other threads:[~2004-09-24 16:30 UTC|newest]

Thread overview: 26+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2004-09-04 16:18 Jan Rychter
2004-09-20 23:18 ` Jan Rychter
2004-09-21  6:39   ` Jonas Steverud
2004-09-22 17:20     ` Jan Rychter
2004-09-23  6:32       ` Xavier Maillard
2004-09-21  8:52   ` Ralf Angeli
2004-09-22  3:12     ` Kevin Greiner
2004-09-22 13:21       ` Ralf Angeli
2004-09-23  0:59         ` Kevin Greiner
2004-09-23  7:59           ` Ralf Angeli
2004-09-23 13:28             ` Kevin Greiner
2004-09-23 14:00               ` Ralf Angeli
2004-09-24  3:52                 ` Kevin Greiner
2004-09-24  7:43                   ` Ralf Angeli
2004-09-24 12:22                     ` Kevin Greiner
2004-09-24 12:32                       ` Ralf Angeli
2004-09-24 13:41                         ` Kevin Greiner
2004-09-24 16:29                           ` Kevin Greiner
2004-09-24 16:30                           ` Ralf Angeli [this message]
2004-09-23 20:07           ` Jan Rychter
2004-09-24  3:58             ` Kevin Greiner
2004-10-11 20:22               ` Jan Rychter
2004-10-13  3:01                 ` Kevin Greiner
2004-10-15  1:12                   ` Jan Rychter
2004-09-22 17:13       ` Jan Rychter
2004-09-22 16:29   ` Xavier Maillard

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='cj1hun$2gb$1@sea.gmane.org' \
    --to=dev.null@iwi.uni-sb.de \
    --cc=angeli@iwi.uni-sb.de \
    /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).