jwiegley / use-package

A use-package declaration for simplifying your .emacs
https://jwiegley.github.io/use-package
GNU General Public License v3.0
4.37k stars 260 forks source link

Unable to install package: installed package dir missing after install #1046

Open TLINDEN opened 1 year ago

TLINDEN commented 1 year ago

There are a couple of packages I am unable to install. It doesn't matter wether I use use-package or package-install directly. The error messages look always the same:

package-autoload-ensure-default-file: Opening output file: No such file or directory, /home/scip/.emacs-init.d/elpa-27.1/expand-region-20221030.957/expand-region-autoloads.el

Debug log:

Debugger entered--Lisp error: (file-missing "Opening output file" "No such file or directory" "/home/scip/.emacs-init.d/elpa-27.1/expand-region-2...")
  write-region(";;; expand-region-autoloads.el --- automatically e..." nil "/home/scip/.emacs-init.d/elpa-27.1/expand-region-2..." nil silent)
  package-autoload-ensure-default-file("/home/scip/.emacs-init.d/elpa-27.1/expand-region-2...")
  package-generate-autoloads(expand-region "/home/scip/.emacs-init.d/elpa-27.1/expand-region-2...")
  package--make-autoloads-and-stuff(#s(package-desc :name expand-region :version (20221030 957) :summary "Increase selected region by semantic units." :reqs nil :kind tar :archive "melpa" :dir nil :extras ((:commit . "b70feaa644310dc2d599dc277cd20a1f2b6446ac") (:authors ("Magnar Sveen" . "magnars@gmail.com")) (:maintainer "Magnar Sveen" . "magnars@gmail.com") (:keywords "marking" "region")) :signed nil) "/home/scip/.emacs-init.d/elpa-27.1/expand-region-2...")
  package-unpack(#s(package-desc :name expand-region :version (20221030 957) :summary "Increase selected region by semantic units." :reqs nil :kind tar :archive "melpa" :dir nil :extras ((:commit . "b70feaa644310dc2d599dc277cd20a1f2b6446ac") (:authors ("Magnar Sveen" . "magnars@gmail.com")) (:maintainer "Magnar Sveen" . "magnars@gmail.com") (:keywords "marking" "region")) :signed nil))
  #f(compiled-function (&optional good-sigs) #<bytecode 0x158389bfec9d>)(nil)
  #f(compiled-function () #<bytecode 0x158389bfecfd>)()
  package--with-response-buffer-1("https://melpa.org/packages/" #f(compiled-function () #<bytecode 0x158389bfecd1>) :file "expand-region-20221030.957.tar.sig" :async nil :error-function #f(compiled-function () #<bytecode 0x158389bfecfd>) :noerror t)
  package--check-signature("https://melpa.org/packages/" "expand-region-20221030.957.tar" "expand-region-20221030.957/\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0..." nil #f(compiled-function (&optional good-sigs) #<bytecode 0x158389bfec9d>))
  #f(compiled-function () #<bytecode 0x15838989a121>)()
  package--with-response-buffer-1("https://melpa.org/packages/" #f(compiled-function () #<bytecode 0x15838989a121>) :file "expand-region-20221030.957.tar" :async nil :error-function #f(compiled-function () #<bytecode 0x158389309e7d>) :noerror nil)
  package-install-from-archive(#s(package-desc :name expand-region :version (20221030 957) :summary "Increase selected region by semantic units." :reqs nil :kind tar :archive "melpa" :dir nil :extras ((:commit . "b70feaa644310dc2d599dc277cd20a1f2b6446ac") (:authors ("Magnar Sveen" . "magnars@gmail.com")) (:maintainer "Magnar Sveen" . "magnars@gmail.com") (:keywords "marking" "region")) :signed nil))
  mapc(package-install-from-archive (#s(package-desc :name expand-region :version (20221030 957) :summary "Increase selected region by semantic units." :reqs nil :kind tar :archive "melpa" :dir nil :extras ((:commit . "b70feaa644310dc2d599dc277cd20a1f2b6446ac") (:authors ("Magnar Sveen" . "magnars@gmail.com")) (:maintainer "Magnar Sveen" . "magnars@gmail.com") (:keywords "marking" "region")) :signed nil)))
  package-download-transaction((#s(package-desc :name expand-region :version (20221030 957) :summary "Increase selected region by semantic units." :reqs nil :kind tar :archive "melpa" :dir nil :extras ((:commit . "b70feaa644310dc2d599dc277cd20a1f2b6446ac") (:authors ("Magnar Sveen" . "magnars@gmail.com")) (:maintainer "Magnar Sveen" . "magnars@gmail.com") (:keywords "marking" "region")) :signed nil)))
  package-install(expand-region)
  eval((package-install 'expand-region) t)
  eval-expression((package-install 'expand-region) nil nil 127)
  funcall-interactively(eval-expression (package-install 'expand-region) nil nil 127)
  call-interactively(eval-expression record nil)
  command-execute(eval-expression record)
  execute-extended-command(nil "eval-expression" "eval-ex")
  funcall-interactively(execute-extended-command nil "eval-expression" "eval-ex")
  call-interactively(execute-extended-command nil nil)
  command-execute(execute-extended-command)

Other affected packages: magit, compat, change-inner, etcpp.

It took me many hours to nail the problem down to this statement which causes this effect:

(use-package pod-mode
             :ensure nil
             :hook font-lock-mode)  ;; <==== here

(I install that mode using el-get).

If I remove the :hook then everything works fine, using use-package and package-install.

Everything also works fine when I replace the hook with:

  :config
             (add-hook 'pod-mode-hook 'font-lock-mode)
spearman commented 1 year ago

I have the same problem, how do you fix it?

I don't know what "use-package" is, I don't have any mention in my init.el. Is it something that is automatically used by package-install or you have to enable it manually?

Debugger entered--Lisp error: (file-missing "Opening output file" "No such file or directory" "/home/spearman/.emacs.d/elpa/auto-complete-1.5.1/a...")
  package-autoload-ensure-default-file("/home/spearman/.emacs.d/elpa/auto-complete-1.5.1/a...")
  package-generate-autoloads(auto-complete "/home/spearman/.emacs.d/elpa/auto-complete-1.5.1")
  package--make-autoloads-and-stuff(#s(package-desc :name auto-complete :version (1 5 1) :summary "Auto Completion for GNU Emacs" :reqs ((popup (0 5 0)) (cl-lib (0 5))) :kind tar :archive "melpa-stable" :dir nil :extras ((:commit . "0655b7f1e6c0f8475adc55f2b86404a877f26a77") (:authors ("Tomohiro Matsuyama" . "m2ym.pub@gmail.com")) (:maintainer "Tomohiro Matsuyama" . "m2ym.pub@gmail.com") (:keywords "completion" "convenience") (:url . "https://github.com/auto-complete/auto-complete")) :signed nil) "/home/spearman/.emacs.d/elpa/auto-complete-1.5.1")
  package-unpack(#s(package-desc :name auto-complete :version (1 5 1) :summary "Auto Completion for GNU Emacs" :reqs ((popup (0 5 0)) (cl-lib (0 5))) :kind tar :archive "melpa-stable" :dir nil :extras ((:commit . "0655b7f1e6c0f8475adc55f2b86404a877f26a77") (:authors ("Tomohiro Matsuyama" . "m2ym.pub@gmail.com")) (:maintainer "Tomohiro Matsuyama" . "m2ym.pub@gmail.com") (:keywords "completion" "convenience") (:url . "https://github.com/auto-complete/auto-complete")) :signed nil))
  #f(compiled-function (&optional good-sigs) #<bytecode 0x74ab2aa31acd69c>)(nil)
  #f(compiled-function () #<bytecode 0x176cd8d10ed61e5>)()
  package--with-response-buffer-1("https://stable.melpa.org/packages/" #f(compiled-function () #<bytecode 0x128e81501d2d4bf9>) :file "auto-complete-1.5.1.tar.sig" :async nil :error-function #f(compiled-function () #<bytecode 0x176cd8d10ed61e5>) :noerror t)
  package--check-signature("https://stable.melpa.org/packages/" "auto-complete-1.5.1.tar" "auto-complete-1.5.1/\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0..." nil #f(compiled-function (&optional good-sigs) #<bytecode 0x74ab2aa31acd69c>))
  #f(compiled-function () #<bytecode -0x67fb6b51a73e32c>)()
  package--with-response-buffer-1("https://stable.melpa.org/packages/" #f(compiled-function () #<bytecode -0x67fb6b51a73e32c>) :file "auto-complete-1.5.1.tar" :async nil :error-function #<subr F616e6f6e796d6f75732d6c616d626461_anonymous_lambda_75> :noerror nil)
  package-install-from-archive(#s(package-desc :name auto-complete :version (1 5 1) :summary "Auto Completion for GNU Emacs" :reqs ((popup (0 5 0)) (cl-lib (0 5))) :kind tar :archive "melpa-stable" :dir nil :extras ((:commit . "0655b7f1e6c0f8475adc55f2b86404a877f26a77") (:authors ("Tomohiro Matsuyama" . "m2ym.pub@gmail.com")) (:maintainer "Tomohiro Matsuyama" . "m2ym.pub@gmail.com") (:keywords "completion" "convenience") (:url . "https://github.com/auto-complete/auto-complete")) :signed nil))
  package-download-transaction((#s(package-desc :name auto-complete :version (1 5 1) :summary "Auto Completion for GNU Emacs" :reqs ((popup (0 5 0)) (cl-lib (0 5))) :kind tar :archive "melpa-stable" :dir nil :extras ((:commit . "0655b7f1e6c0f8475adc55f2b86404a877f26a77") (:authors ("Tomohiro Matsuyama" . "m2ym.pub@gmail.com")) (:maintainer "Tomohiro Matsuyama" . "m2ym.pub@gmail.com") (:keywords "completion" "convenience") (:url . "https://github.com/auto-complete/auto-complete")) :signed nil)))
  package-install(auto-complete)
  (if (package-installed-p package) nil (package-install package))
  (while --dolist-tail-- (setq package (car --dolist-tail--)) (if (package-installed-p package) nil (package-install package)) (setq --dolist-tail-- (cdr --dolist-tail--)))
  (let ((--dolist-tail-- package-list) package) (while --dolist-tail-- (setq package (car --dolist-tail--)) (if (package-installed-p package) nil (package-install package)) (setq --dolist-tail-- (cdr --dolist-tail--))))
  load-with-code-conversion("/home/spearman/.emacs.d/init.el" "/home/spearman/.emacs.d/init.el" t t)
  load("/home/spearman/.emacs.d/init" noerror nomessage)
  startup--load-user-init-file(#f(compiled-function () #<bytecode -0xb55e791f5d992c4>) #f(compiled-function () #<bytecode -0x1f3c686ddc0cdc35>) t)
  command-line()
  normal-top-level()