leiningen

ericdallo 2022-04-19T14:23:03.420769Z

I have a clojure version issue with a lein plugin, there is this jar on clojars called clojure-lsp-standalone, it has a org.clojure/clojure dep with 1.11.1 version, and there is lein-clojure-lsp plugin which just uses that jar. When I use the plugin in a clojure project that have other multiple plugins (but the deps of the project is using clojure 1.11.1), it doesn't find parse-long which is from 1.11.0 and it's being used by clojure-lsp, What's the best way to fix that?

ericdallo 2022-04-19T14:23:27.118369Z

I saw eval-in-project could be used, but not sure it's the best way

ericdallo 2022-04-19T14:25:26.157919Z

what's the best way to a plugin declare a clojure dep, AFAIK it should not have a org.clojure/clojure declared on its project.clj right?

vemv 2022-04-19T15:37:21.391769Z

From what I see in https://clojars.org/com.github.clojure-lsp/clojure-lsp-standalone/versions/2022.04.18-00.59.32-hotfix2 you do declare a vanilla 1.11 dep, right? Which sounds correct

vemv 2022-04-19T15:39:06.087979Z

I've had mixed experiences with dep resolution in plugins, at least two scars come to mind I've been happy coding e.g. Eastwood with up to (down to?) 1.7 compatibility, verified in CI, in practice it's little pain and a whole lot of peace of mind

ericdallo 2022-04-19T17:35:02.011059Z

you mean, it would be better if clojure-lsp had clojure as a older version to better compatibility?

vemv 2022-04-19T19:47:18.301619Z

yes

ericdallo 2022-04-19T19:49:24.771069Z

I see, I thought plugins could override that, but makes sense