Skip to content

"ensure" fails if the package version has changed on the remote repository #772

Open
@rdiez

Description

@rdiez

I am not sure whether use-package is the right place for this bug report.

I wanted to install the "which-key" package, so I added this to my config:

(use-package which-key
:ensure t
:config
(which-key-mode))

I did not want to restart Emacs, so I ran the code above manually. I got the following error:

Error (use-package): Failed to install which-key: https://melpa.org/packages/which-key-20190315.1248.el: Not found
Error (use-package): Cannot load which-key

I did some digging, and it turns out that I had not updated the package list in a few weeks. Apparently, MELPA does not serve old package versions.

This is all rather unfortunate. Imagine you run "sudo apt install some-package" on Debian, and that fails if the package version on the remote repository has been updated in the mean time. You would then complain that "apt install" is not actually reliable. Installing a package should be reliable, even if a newer version is available. Whether it installs the older or the newer version is debatable.

Metadata

Metadata

Assignees

No one assigned

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions