GNU bug report logs - #59088
29.0.50; void-function package-vc-update when first run package-update-all.

Previous Next

Package: emacs;

Reported by: Feng Shu <tumashu <at> 163.com>

Date: Mon, 7 Nov 2022 02:36:02 UTC

Severity: normal

Found in version 29.0.50

Done: Philip Kaludercic <philipk <at> posteo.net>

Bug is archived. No further changes may be made.

Full log


Message #16 received at 59088-done <at> debbugs.gnu.org (full text, mbox):

From: Philip Kaludercic <philipk <at> posteo.net>
To: Feng Shu <tumashu <at> 163.com>
Cc: 59088-done <at> debbugs.gnu.org
Subject: Re: bug#59088: 29.0.50; void-function package-vc-update when first
 run package-update-all.
Date: Thu, 15 Dec 2022 12:59:12 +0000
Feng Shu <tumashu <at> 163.com> writes:

> Philip Kaludercic <philipk <at> posteo.net> writes:
>
>> Feng Shu <tumashu <at> 163.com> writes:
>>
>>> Debugger entered--Lisp error: (void-function package-vc-update)
>>>   package-vc-update(#s(package-desc :name pyim :version (5 2 8)
>>> :summary "A Chinese input method support quanpin, shuangpin,..."
>>> :reqs ((emacs (25 1)) (async (1 6)) (xr (1 13))) :kind vc :archive
>>> nil :dir "/home/feng/.emacs.d/elpa-29/pyim" :extras ((:url
>>> . "https://github.com/tumashu/pyim") (:keywords "convenience"
>>> "chinese" "pinyin" "input-method") (:maintainer "Feng Shu"
>>> . "tumashu <at> 163.com") (:authors ("Ye Wenbin" . "wenbinye <at> 163.com")
>>> ("Feng Shu" . "tumashu <at> 163.com")) (:commit
>>> . "8c4f7d40c05dc06b3c96c2955e5d72ec268f2b61")) :signed nil))
>>>   package-update(pyim)
>>>   mapc(package-update (pyim))
>>>   package-update-all(t)
>>>   funcall-interactively(package-update-all t)
>>>   call-interactively(package-update-all record nil)
>>>   command-execute(package-update-all record)
>>>   execute-extended-command(nil "package-update-all" nil)
>>>   funcall-interactively(execute-extended-command nil "package-update-all" nil)
>>>   call-interactively(execute-extended-command nil nil)
>>>   command-execute(execute-extended-command)
>>
>> The function has been autoloaded, so this shouldn't occur any more:
>>
>>   commit 17889dd828dabc8d4a015c3df889799818178afb
>>   Author: Philip Kaludercic <philipk <at> posteo.net>
>>   Date:   Thu Nov 17 17:39:46 2022 +0100
>>
>>       * lisp/emacs-lisp/package-vc.el: Autoload package-vc-update{,-all}
>>
>>   diff --git a/lisp/emacs-lisp/package-vc.el b/lisp/emacs-lisp/package-vc.el
>>   --- a/lisp/emacs-lisp/package-vc.el
>>   +++ b/lisp/emacs-lisp/package-vc.el
>>   @@ -573,35 +574,36 @@
>>
>>   +;;;###autoload
>>    (defun package-vc-update (pkg-desc)
>>      "Attempt to update the package PKG-DESC."
>>      (interactive (list (package-vc--read-package-desc "Update source package: " t)))
>>      ;; HACK: To run `package-vc--unpack-1' after checking out the new
>>      ;; revision, we insert a hook into `vc-post-command-functions', and
>>      ;; remove it right after it ran.  To avoid running the hook multiple
>>      ;; times or even for the wrong repository (as `vc-pull' is often
>>      ;; asynchronous), we extract the relevant arguments using a pseudo
>>      ;; filter for `vc-filter-command-function', executed only for the
>>      ;; side effect, and store them in the lexical scope.  When the hook
>>      ;; is run, we check if the arguments are the same (`eq') as the ones
>>      ;; previously extracted, and only in that case will be call
>>      ;; `package-vc--unpack-1'.  Ugh...
>>      ;;
>>      ;; If there is a better way to do this, it should be done.
>>      (cl-assert (package-vc-p pkg-desc))
>>      (letrec ((pkg-dir (package-desc-dir pkg-desc))
>>               (vc-flags)
>>               (vc-filter-command-function
>>                (lambda (command file-or-list flags)
>>                  (setq vc-flags flags)
>>                  (list command file-or-list flags)))
>>               (post-upgrade
>>                (lambda (_command _file-or-list flags)
>>                  (when (and (file-equal-p pkg-dir default-directory)
>>                             (eq flags vc-flags))
>>                    (unwind-protect
>>                        (with-demoted-errors "Failed to activate: %S"
>>                          (package-vc--unpack-1 pkg-desc pkg-dir))
>>                      (remove-hook 'vc-post-command-functions post-upgrade))))))
>>        (add-hook 'vc-post-command-functions post-upgrade)
>>        (with-demoted-errors "Failed to fetch: %S"
>>          (let ((default-directory pkg-dir))
>>            (vc-pull)))))
>
> works!

Marked as closed.




This bug report was last modified 2 years and 237 days ago.

Previous Next


GNU bug tracking system
Copyright (C) 1999 Darren O. Benham, 1997,2003 nCipher Corporation Ltd, 1994-97 Ian Jackson.