When I install lsp-mode from Melpa, I get version 20221003.1714.

When I install dap-mode from Melpa, I get version 20220921.941, which requires lsp-mode-6.0.

As a result, (require 'dap-mode) fails:

Unable to activate package ‘dap-mode’.
Required package ‘lsp-mode-6.0’ is unavailable

When I look inside lsp-mode.el, I see

;; Version: 8.0.1

Looking at this, it appears that I am getting a snapshot version of lsp-mode which is based on a higher version than dap-mode requires. But something in the package framework is not figuring out the versions.

The only solution that I am seeing is to clone the lsp-mode repo, checkout a release tag and manually add it to my class-path. I'm guessing that would work, but it would make getting updates much harder.

Is there a resolution to this? When I do package-list-packages, I don't see a version of lsp-mode with a fixed version number to install.


package-archives is a variable defined in ‘package.el’. Its value is (("gnu" . "https://elpa.gnu.org/packages/") ("melpa" . "https://melpa.org/packages/")) Original value was (("gnu" . "https://elpa.gnu.org/packages/"))

Emacs version:

GNU Emacs 27.2 (build 1, x86_64-apple-darwin20.6.0, NS appkit-2022.60 Version 11.6.4 (Build 20G417)) of 2022-03-02

  • What's the question?
    – Drew
    Commented Oct 4, 2022 at 17:09

1 Answer 1


Try uninstalling both lsp-mode and dap-mode. Then install dap-mode allowing the package system to pull in the lsp-mode dependency automatically. When I did that I got:

dap-mode   20220921.941   installed    Debug Adapter Protocol mode
lsp-mode   20220815.958   installed    LSP mode

At that point (require 'dap-mode) worksforme.

  • 1
    I was using cask and pallet for package management, and for some reason, my Cask file was explicitly requiring lip-mode 6.0. When I uninstalled enough stuff and deleted the version locks, it worked for me too. Commented Oct 4, 2022 at 18:55

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.