leiningen: missing super-pom

后端 未结 6 2298
盖世英雄少女心
盖世英雄少女心 2021-02-13 17:17

if I enable eith the clojure-couchdb or swank-clojure then lein deps fails because org.apache.maven:super-pom:jar:2.0 is missing

:dependencies [[org         


        
相关标签:
6条回答
  • 2021-02-13 17:39

    I think it's still common that projects have broken dependencies. It's unfortunate, because it really mars the experience.

    My solution is to go onto http://clojars.org and search for the library I need. Usually there are a few versions. I do a little research on http://github.com to see which one is most up to date. Then I try that one as a dependency. If it works, great! Otherwise, I try another one.

    It's a long process, but I think it is getting better. You should have seen the process before!

    0 讨论(0)
  • 2021-02-13 17:48

    I'm getting the same error on the maven super-pom dependency, and when I do

    $ sudo lein deps
    

    It runs without error. Not an ideal solution, but it works for me.

    0 讨论(0)
  • 2021-02-13 17:52

    I had a similar issue with lein-ring causing a dependency failure with regard to org.apache.maven:super-pom. Turns out the issue was that M2_HOME was set to a version of Maven I use for work. Unsetting M2_HOME fixed the issue. It appears that leiningen doesn't play nice with strange Maven implementations.

    0 讨论(0)
  • 2021-02-13 17:52

    With Ubuntu 10.10 x86_64, with lein deps, I get annoying ... 5 required artifacts are missing.

    for artifact:

    org.apache.maven:super-pom:jar:2.0
    

    ... but the commands

    sudo LEIN_ROOT=1 ~/bin/lein deps;
    sudo chown -R $USER:$USER lib 
    

    do the job.

    0 讨论(0)
  • 2021-02-13 17:53

    I accidentally uploaded swank-clojure to the org.clojure group about a year ago. I deleted it soon after since I'm not associated with that group, so that's why it can't be found. Can I ask where you found the instructions with the erroneous version so it can be corrected?

    0 讨论(0)
  • 2021-02-13 18:03

    I think this just means that Maven wasn't able to satisfy the dependencies you specified. I've checked there's no org.clojure/swank-clojure artifact in any of the three repositories your message mentions. For clojure-couchdb, the version you're using -- as far as I can tell from looking at its project.clj file on GitHub -- depends on org.clojure/clojure-http-client "1.0.0-SNAPSHOT", which doesn't exist in the repos either.

    One way around this problem is to install the jars you want into your local repo. (I can't seem to remember the exact command... will look it up in a minute. See e.g. this page for instructions.) Then Maven will just pick them up from there.

    (BTW, if you want to use Clojure + contrib 1.1.0, you can just use "1.1.0" as the version strings now. That's for both org.clojure/clojure and org.clojure/clojure-contrib.)

    Oh, and about the super POM -- from this page in Maven's docs:

    The Super POM is Maven's default POM. All POMs extend the Super POM unless explicitly set, meaning the configuration specified in the Super POM is inherited by the POMs you created for your projects.

    As for how it got into your error message, I've honestly no idea. You could add the "maven" tag to this question or just ask a separate question with that tag to get some Maven gurus onto it.

    0 讨论(0)
提交回复
热议问题