all messages for Emacs-related lists mirrored at yhetil.org
 help / color / mirror / code / Atom feed
* bug#14718: 24.3.50; Endless loop in "package-read-all-archive-contents"
@ 2013-06-25 20:19 Sebastian Wiesner
  2013-06-26  0:45 ` Stefan Monnier
  0 siblings, 1 reply; 2+ messages in thread
From: Sebastian Wiesner @ 2013-06-25 20:19 UTC (permalink / raw)
  To: 14718

If a package is contained in two or more archives,
"package-read-all-archive-contents" hangs in an endless loop.  For
instance, in "emacs -Q":

ELISP> package-archives
(("gnu" . "http://elpa.gnu.org/packages/"))

ELISP> (package-refresh-contents)
nil
ELISP> (add-to-list 'package-archives
  '("melpa" . "http://melpa.milkbox.net/packages/") t)
(("gnu" . "http://elpa.gnu.org/packages/")
 ("melpa" . "http://melpa.milkbox.net/packages/"))

ELISP> package-archives
(("gnu" . "http://elpa.gnu.org/packages/")
 ("melpa" . "http://melpa.milkbox.net/packages/"))

ELISP> (package-refresh-contents)
*** Eval error ***  Quit during evaluation

The last invocation continues forever.  "Quit during evaluation" is the
result of repeatedly pressing "C-g".

I inserted some "message" calls into functions called by
"package-refresh-contents", which indicate that the "while" loop at the
bottom of "package--add-to-archive-contents" is the root cause.  This
loop seems to continue forever if "package--add-to-archive-contents" is
invoked with a "package" which is already contained in another archive.

Inserting a "(message "DEBUG: Looping for %s" package)" at the beginning
of the body of this loop repeats this message a few thousand times
before C-g succeeds in interrupting the evaluation.  In my case, this
was the "yasnippet" package which is contained in GNU as well as in
MELPA.

Apparently the test of this loop is wrong, but since I do not understand
what the loop is supposed to do, I can't say how it is wrong.





^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2013-06-26  0:45 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2013-06-25 20:19 bug#14718: 24.3.50; Endless loop in "package-read-all-archive-contents" Sebastian Wiesner
2013-06-26  0:45 ` Stefan Monnier

Code repositories for project(s) associated with this external index

	https://git.savannah.gnu.org/cgit/emacs.git
	https://git.savannah.gnu.org/cgit/emacs/org-mode.git

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.