GNU bug report logs -
#14718
24.3.50; Endless loop in "package-read-all-archive-contents"
Previous Next
Reported by: Sebastian Wiesner <lunaryorn <at> gmail.com>
Date: Tue, 25 Jun 2013 20:20:05 UTC
Severity: normal
Found in version 24.3.50
Done: Glenn Morris <rgm <at> gnu.org>
Bug is archived. No further changes may be made.
To add a comment to this bug, you must first unarchive it, by sending
a message to control AT debbugs.gnu.org, with unarchive 14718 in the body.
You can then email your comments to 14718 AT debbugs.gnu.org in the normal way.
Toggle the display of automated, internal messages from the tracker.
Report forwarded
to
bug-gnu-emacs <at> gnu.org
:
bug#14718
; Package
emacs
.
(Tue, 25 Jun 2013 20:20:06 GMT)
Full text and
rfc822 format available.
Acknowledgement sent
to
Sebastian Wiesner <lunaryorn <at> gmail.com>
:
New bug report received and forwarded. Copy sent to
bug-gnu-emacs <at> gnu.org
.
(Tue, 25 Jun 2013 20:20:06 GMT)
Full text and
rfc822 format available.
Message #5 received at submit <at> debbugs.gnu.org (full text, mbox):
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.
Information forwarded
to
bug-gnu-emacs <at> gnu.org
:
bug#14718
; Package
emacs
.
(Wed, 26 Jun 2013 00:46:01 GMT)
Full text and
rfc822 format available.
Message #8 received at 14718 <at> debbugs.gnu.org (full text, mbox):
> 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":
Duh! Not sure how the nil got lost when I copied the loop from
package-process-define-package.
I installed the patch below which should fix it,
Stefan
=== modified file 'lisp/ChangeLog'
--- lisp/ChangeLog 2013-06-25 16:13:49 +0000
+++ lisp/ChangeLog 2013-06-26 00:43:32 +0000
@@ -1,3 +1,8 @@
+2013-06-26 Stefan Monnier <monnier <at> iro.umontreal.ca>
+
+ * emacs-lisp/package.el (package--add-to-archive-contents): Add missing
+ nil terminate the loop (bug#14718).
+
2013-06-25 Stefan Monnier <monnier <at> iro.umontreal.ca>
* emacs-lisp/package.el: Use lexical-binding. Include obsolete
=== modified file 'lisp/emacs-lisp/package.el'
--- lisp/emacs-lisp/package.el 2013-06-25 16:13:49 +0000
+++ lisp/emacs-lisp/package.el 2013-06-26 00:42:56 +0000
@@ -3,6 +3,7 @@
;; Copyright (C) 2007-2013 Free Software Foundation, Inc.
;; Author: Tom Tromey <tromey <at> redhat.com>
+;; Daniel Hackney <dan <at> haxney.org>
;; Created: 10 Mar 2007
;; Version: 1.0.1
;; Keywords: tools
@@ -924,7 +925,8 @@
(version-list-<
version (package-desc-version (cadr existing-packages))))
(setq existing-packages (cdr existing-packages))
- (push pkg-desc (cdr existing-packages))))))))
+ (push pkg-desc (cdr existing-packages))
+ nil))))))
(defun package-download-transaction (packages)
"Download and install all the packages in PACKAGES.
bug closed, send any further explanations to
14718 <at> debbugs.gnu.org and Sebastian Wiesner <lunaryorn <at> gmail.com>
Request was from
Glenn Morris <rgm <at> gnu.org>
to
control <at> debbugs.gnu.org
.
(Mon, 01 Jul 2013 18:21:02 GMT)
Full text and
rfc822 format available.
bug archived.
Request was from
Debbugs Internal Request <help-debbugs <at> gnu.org>
to
internal_control <at> debbugs.gnu.org
.
(Tue, 30 Jul 2013 11:24:03 GMT)
Full text and
rfc822 format available.
This bug report was last modified 11 years and 323 days ago.
Previous Next
GNU bug tracking system
Copyright (C) 1999 Darren O. Benham,
1997,2003 nCipher Corporation Ltd,
1994-97 Ian Jackson.