Note that -X:deps mvn-pom
is not affected by changes in the classpath used to run it (so using the :versions alias with it won't affect the pom that is generated). This differs from -Spom
which does work from the classpath you're choosing via clj. We are still debating the best way to supply a set of classpath-modifying options to mvn-pom (and other programs like tree).
I wasn't able to repro the error you show above with that or with variants. The code you point to should only be happening if a coord can't be resolved so that's too probably too late to be fixing this error, but I'd like to have a good repro first
also btw, mvn-pom does not take a :lib argument, I'm curious how you got the idea it did
@alexmiller Tried this again.
borkdude@MBP2019 /tmp $ clojure -A:versions -X:deps mvn-pom
Error generating pom manifest: Bad coordinate for library clj-kondo/clj-kondo, expected map: nil
borkdude@MBP2019 /tmp $ clojure -Sdescribe
{:version "1.10.1.727"
:config-files ["/usr/local/Cellar/clojure/1.10.1.727/deps.edn" "/Users/borkdude/.clojure/deps.edn" "deps.edn" ]
:config-user "/Users/borkdude/.clojure/deps.edn"
:config-project "deps.edn"
:install-dir "/usr/local/Cellar/clojure/1.10.1.727"
:config-dir "/Users/borkdude/.clojure"
:cache-dir ".cpcache"
:force false
:repro false
:main-aliases ""
:repl-aliases ""}
borkdude@MBP2019 /tmp $ cat deps.edn
{:aliases {:versions {:default-deps {clj-kondo/clj-kondo {:mvn/version "2020.10.10"}}}}
:deps {clj-kondo/clj-kondo nil}}
I don't know where the :lib argument came from. This was written by a colleague who went with vacation and this blocked our deploy.
fwiw @seancorfield also has said he has the exact same problem at his job
Same with -Srepro
:
$ clojure -Srepro -A:versions -X:deps mvn-pom
Error generating pom manifest: Bad coordinate for library clj-kondo/clj-kondo, expected map: nil
thx, that repros for me
so this is exactly what I said above - the :versions alias affects the classpath of the mvn-pom program, but is not used when computing the pom deps (only the project deps.edn is used for that), and yes that's the same issue Sean has. as he said, clj -Spom works differently and that's the recommended path right now.
alright, thanks