莱宁根找不到当地的依赖

时间:2015-02-13 09:54:19

标签: clojure leiningen

我在使用本地版本的库时遇到问题,我不想将其推向Clojars进行测试并发现它已损坏。我很欣赏这是许多新的Clojure和Leiningen开发人员的常见问题。我已按照其他人提供的步骤操作,但仍然无效。

总结
我已尝试lein pom/jar/install,以及checkout功能(您将其他项目符号链接)。我认为我可以尝试source-paths选项,但我不确定它是如何工作的。我还想过尝试修改lein classpath,但我不确定这是否可行?


对于那些喜欢更多细节的人......

我有两个Leiningen项目:

  1. https://github.com/Integralist/spurious-clojure-aws-sdk-helper
  2. https://github.com/Integralist/spurious-clojure-example
  3. 这个想法是第二个项目“spurious-clojure-example”应该使用第一个“spurious-clojure-aws-sdk-helper”作为开发依赖项(因为它是一个你使用的库,而本地devuing反对伪造AWS资源;因此无需在生产环境中使用它。)

    “spurious-clojure-example”project.clj文件看起来像......

    (defproject spurious-clojure-example "0.1.0"
      :description "This is an example application that utilises the Spurious Clojure AWS SDK Helper"
      :url "https://github.com/integralist/spurious-clojure-example"
      :dependencies [[org.clojure/clojure "1.6.0"]
                     [compojure "1.1.6"]
                     [hiccup "1.0.5"]
                     [ring-server "0.3.1"]
                     [amazonica "0.3.13"]
                     [environ "1.0.0"]]
      :plugins [[lein-ring "0.8.12"]
                [lein-environ "1.0.0"]]
      :ring {:handler spurious-clojure-example.handler/app
             :init spurious-clojure-example.handler/init
             :destroy spurious-clojure-example.handler/destroy}
      :profiles
      {:uberjar {:aot :all}
       :production
       {:ring
        {:open-browser? false, :stacktraces? false, :auto-reload? false}}
       :dev
       {:dependencies [[ring-mock "0.1.5"]
                       [ring/ring-devel "1.3.1"]
                       [spurious-aws-sdk-helper "0.1.0"]]}})
    

    注意我已将[spurious-aws-sdk-helper "0.1.0"]加入:dev {:dependencies}

    加载“spurious-clojure-aws-sdk-helper”代码的方式是这样的:

    (if (env :debug) ; defined in profiles.clj
      (do
        (require '[spurious-aws-sdk-helper.core :as core])
        (...other stuff...)))
    

    我在“spurious-aws-sdk-helper”项目中尝试的第一件事就是......

    lein pom
    lein jar
    lein install
    

    ...正如我被告知这会将“spurious-aws-sdk-helper”安装到本地目录~/.m2中,Leiningen将首先将其视为远程依赖项的本地缓存。

    tree ~/.m2 | grep spurious
    ├── spurious-aws-sdk-helper
    │   └── spurious-aws-sdk-helper
    │       │   ├── spurious-aws-sdk-helper-0.1.0.jar
    │       │   └── spurious-aws-sdk-helper-0.1.0.pom
    │       │   ├── spurious-aws-sdk-helper-0.1.0-SNAPSHOT.jar
    │       │   └── spurious-aws-sdk-helper-0.1.0-SNAPSHOT.pom
    ├── spurious-clojure-example
    │   └── spurious-clojure-example
    │       │   ├── spurious-clojure-example-0.1.0-SNAPSHOT.jar
    │       │   └── spurious-clojure-example-0.1.0-SNAPSHOT.pom
    

    这不起作用。当我将我的Vim编辑器连接到nREPL并尝试评估对库的require调用时,它会说它无法找到命名空间。

    然后我尝试为我的“spurious-clojure-example”项目执行相同的lein pom/jar/install过程(以防万一有两个项目需要本地安装的奇怪原因)。同样,也没有区别,但我没想到这会做任何事情。

    然后我尝试重命名我的项目以从版本号中删除-SNAPSHOT(如果让Leiningen认为依赖项无法使用 - 我知道废话,但我抓着稻草)。

    我开始尝试checkout功能(https://github.com/technomancy/leiningen/blob/stable/doc/TUTORIAL.md#checkout-dependencies),当我评估require调用时,会通过(例如没有错误),但随后使用其中一个依赖项“spurious-aws-sdk-helper”无法加载(即org.clojure/data.json)。

    作为临时措施,我决定将org.clojure/data.json添加到我的“spurious-clojure-example”依赖项中。因此,当在REPL中再次评估代码时,它这次超过了前两个命名空间错误,但由于无法找到spurious-aws-sdk-helper.s3命名空间而再次出错: - /

    此时我意识到我必须遗漏一些非常明显的东西,因为在你的计算机上本地测试一个库并不困难。

    有人可以帮我解决这个问题。

    非常感谢!

    更新:这是lein classpath对于“spurious-clojure-example”的结果......

    /Users/markmcdonnell/Code/spurious-clojure-example/test
    /Users/markmcdonnell/Code/spurious-clojure-example/src
    /Users/markmcdonnell/Code/spurious-clojure-example/dev-resources
    /Users/markmcdonnell/Code/spurious-clojure-example/resources
    /Users/markmcdonnell/Code/spurious-clojure-example/target/classes
    /Users/markmcdonnell/.m2/repository/ns-tracker/ns-tracker/0.2.1/ns-tracker-0.2.1.jar
    /Users/markmcdonnell/.m2/repository/org/clojure/tools.macro/0.1.0/tools.macro-0.1.0.jar
    /Users/markmcdonnell/.m2/repository/com/amazonaws/aws-java-sdk-sqs/1.9.13/aws-java-sdk-sqs-1.9.13.jar
    /Users/markmcdonnell/.m2/repository/com/amazonaws/aws-java-sdk-s3/1.9.13/aws-java-sdk-s3-1.9.13.jar
    /Users/markmcdonnell/.m2/repository/com/amazonaws/aws-java-sdk-dynamodb/1.9.13/aws-java-sdk-dynamodb-1.9.13.jar
    /Users/markmcdonnell/.m2/repository/com/amazonaws/aws-java-sdk-swf-libraries/1.9.13/aws-java-sdk-swf-libraries-1.9.13.jar
    /Users/markmcdonnell/.m2/repository/org/clojure/algo.generic/0.1.2/algo.generic-0.1.2.jar
    /Users/markmcdonnell/.m2/repository/org/clojure/java.classpath/0.2.0/java.classpath-0.2.0.jar
    /Users/markmcdonnell/.m2/repository/watchtower/watchtower/0.1.1/watchtower-0.1.1.jar
    /Users/markmcdonnell/.m2/repository/com/amazonaws/aws-java-sdk-config/1.9.13/aws-java-sdk-config-1.9.13.jar
    /Users/markmcdonnell/.m2/repository/com/amazonaws/aws-java-sdk-redshift/1.9.13/aws-java-sdk-redshift-1.9.13.jar
    /Users/markmcdonnell/.m2/repository/org/apache/httpcomponents/httpcore/4.3.2/httpcore-4.3.2.jar
    /Users/markmcdonnell/.m2/repository/clojure-complete/clojure-complete/0.2.3/clojure-complete-0.2.3.jar
    /Users/markmcdonnell/.m2/repository/com/amazonaws/aws-java-sdk-glacier/1.9.13/aws-java-sdk-glacier-1.9.13.jar
    /Users/markmcdonnell/.m2/repository/com/amazonaws/aws-java-sdk/1.9.13/aws-java-sdk-1.9.13.jar
    /Users/markmcdonnell/.m2/repository/com/amazonaws/aws-java-sdk-directconnect/1.9.13/aws-java-sdk-directconnect-1.9.13.jar
    /Users/markmcdonnell/.m2/repository/ring/ring-codec/1.0.0/ring-codec-1.0.0.jar
    /Users/markmcdonnell/.m2/repository/org/eclipse/jetty/jetty-server/7.6.8.v20121106/jetty-server-7.6.8.v20121106.jar
    /Users/markmcdonnell/.m2/repository/joda-time/joda-time/2.2/joda-time-2.2.jar
    /Users/markmcdonnell/.m2/repository/com/amazonaws/aws-java-sdk-ec2/1.9.13/aws-java-sdk-ec2-1.9.13.jar
    /Users/markmcdonnell/.m2/repository/org/eclipse/jetty/jetty-continuation/7.6.8.v20121106/jetty-continuation-7.6.8.v20121106.jar
    /Users/markmcdonnell/.m2/repository/com/amazonaws/aws-java-sdk-lambda/1.9.13/aws-java-sdk-lambda-1.9.13.jar
    /Users/markmcdonnell/.m2/repository/com/amazonaws/aws-java-sdk-storagegateway/1.9.13/aws-java-sdk-storagegateway-1.9.13.jar
    /Users/markmcdonnell/.m2/repository/com/amazonaws/aws-java-sdk-ses/1.9.13/aws-java-sdk-ses-1.9.13.jar
    /Users/markmcdonnell/.m2/repository/clj-stacktrace/clj-stacktrace/0.2.5/clj-stacktrace-0.2.5.jar
    /Users/markmcdonnell/.m2/repository/com/amazonaws/aws-java-sdk-opsworks/1.9.13/aws-java-sdk-opsworks-1.9.13.jar
    /Users/markmcdonnell/.m2/repository/com/amazonaws/aws-java-sdk-core/1.9.13/aws-java-sdk-core-1.9.13.jar
    /Users/markmcdonnell/.m2/repository/org/eclipse/jetty/jetty-util/7.6.8.v20121106/jetty-util-7.6.8.v20121106.jar
    /Users/markmcdonnell/.m2/repository/ring/ring-servlet/1.2.1/ring-servlet-1.2.1.jar
    /Users/markmcdonnell/.m2/repository/com/amazonaws/aws-java-sdk-simpleworkflow/1.9.13/aws-java-sdk-simpleworkflow-1.9.13.jar
    /Users/markmcdonnell/.m2/repository/clj-time/clj-time/0.4.4/clj-time-0.4.4.jar
    /Users/markmcdonnell/.m2/repository/com/amazonaws/aws-java-sdk-logs/1.9.13/aws-java-sdk-logs-1.9.13.jar
    /Users/markmcdonnell/.m2/repository/robert/hooke/1.3.0/hooke-1.3.0.jar
    /Users/markmcdonnell/.m2/repository/com/amazonaws/aws-java-sdk-cloudsearch/1.9.13/aws-java-sdk-cloudsearch-1.9.13.jar
    /Users/markmcdonnell/.m2/repository/com/amazonaws/aws-java-sdk-simpledb/1.9.13/aws-java-sdk-simpledb-1.9.13.jar
    /Users/markmcdonnell/.m2/repository/com/amazonaws/aws-java-sdk-cloudfront/1.9.13/aws-java-sdk-cloudfront-1.9.13.jar
    /Users/markmcdonnell/.m2/repository/com/amazonaws/aws-java-sdk-sts/1.9.13/aws-java-sdk-sts-1.9.13.jar
    /Users/markmcdonnell/.m2/repository/com/amazonaws/aws-java-sdk-codedeploy/1.9.13/aws-java-sdk-codedeploy-1.9.13.jar
    /Users/markmcdonnell/.m2/repository/commons-io/commons-io/2.4/commons-io-2.4.jar
    /Users/markmcdonnell/.m2/repository/com/amazonaws/aws-java-sdk-kinesis/1.9.13/aws-java-sdk-kinesis-1.9.13.jar
    /Users/markmcdonnell/.m2/repository/com/amazonaws/aws-java-sdk-autoscaling/1.9.13/aws-java-sdk-autoscaling-1.9.13.jar
    /Users/markmcdonnell/.m2/repository/com/amazonaws/amazon-kinesis-client/1.1.0/amazon-kinesis-client-1.1.0.jar
    /Users/markmcdonnell/.m2/repository/commons-logging/commons-logging/1.1.3/commons-logging-1.1.3.jar
    /Users/markmcdonnell/.m2/repository/ring/ring-jetty-adapter/1.2.1/ring-jetty-adapter-1.2.1.jar
    /Users/markmcdonnell/.m2/repository/com/amazonaws/aws-java-sdk-support/1.9.13/aws-java-sdk-support-1.9.13.jar
    /Users/markmcdonnell/.m2/repository/commons-fileupload/commons-fileupload/1.3/commons-fileupload-1.3.jar
    /Users/markmcdonnell/.m2/repository/hiccup/hiccup/1.0.5/hiccup-1.0.5.jar
    /Users/markmcdonnell/.m2/repository/com/amazonaws/aws-java-sdk-elasticbeanstalk/1.9.13/aws-java-sdk-elasticbeanstalk-1.9.13.jar
    /Users/markmcdonnell/.m2/repository/org/clojure/tools.reader/0.7.3/tools.reader-0.7.3.jar
    /Users/markmcdonnell/.m2/repository/com/amazonaws/aws-java-sdk-cognitoidentity/1.9.13/aws-java-sdk-cognitoidentity-1.9.13.jar
    /Users/markmcdonnell/.m2/repository/ring-refresh/ring-refresh/0.1.2/ring-refresh-0.1.2.jar
    /Users/markmcdonnell/.m2/repository/org/tukaani/xz/1.5/xz-1.5.jar
    /Users/markmcdonnell/.m2/repository/com/amazonaws/aws-java-sdk-cloudwatch/1.9.13/aws-java-sdk-cloudwatch-1.9.13.jar
    /Users/markmcdonnell/.m2/repository/com/amazonaws/aws-java-sdk-rds/1.9.13/aws-java-sdk-rds-1.9.13.jar
    /Users/markmcdonnell/.m2/repository/com/amazonaws/aws-java-sdk-importexport/1.9.13/aws-java-sdk-importexport-1.9.13.jar
    /Users/markmcdonnell/.m2/repository/com/amazonaws/aws-java-sdk-cloudformation/1.9.13/aws-java-sdk-cloudformation-1.9.13.jar
    /Users/markmcdonnell/.m2/repository/commons-codec/commons-codec/1.6/commons-codec-1.6.jar
    /Users/markmcdonnell/.m2/repository/com/amazonaws/aws-java-sdk-route53/1.9.13/aws-java-sdk-route53-1.9.13.jar
    /Users/markmcdonnell/.m2/repository/ring/ring/1.2.1/ring-1.2.1.jar
    /Users/markmcdonnell/.m2/repository/org/clojure/tools.namespace/0.1.3/tools.namespace-0.1.3.jar
    /Users/markmcdonnell/.m2/repository/com/fasterxml/jackson/core/jackson-databind/2.3.2/jackson-databind-2.3.2.jar
    /Users/markmcdonnell/.m2/repository/com/amazonaws/aws-java-sdk-elastictranscoder/1.9.13/aws-java-sdk-elastictranscoder-1.9.13.jar
    /Users/markmcdonnell/.m2/repository/com/amazonaws/aws-java-sdk-elasticache/1.9.13/aws-java-sdk-elasticache-1.9.13.jar
    /Users/markmcdonnell/.m2/repository/org/iq80/snappy/snappy/0.3/snappy-0.3.jar
    /Users/markmcdonnell/.m2/repository/ring/ring-devel/1.2.1/ring-devel-1.2.1.jar
    /Users/markmcdonnell/.m2/repository/com/amazonaws/aws-java-sdk-kms/1.9.13/aws-java-sdk-kms-1.9.13.jar
    /Users/markmcdonnell/.m2/repository/com/amazonaws/aws-java-sdk-emr/1.9.13/aws-java-sdk-emr-1.9.13.jar
    /Users/markmcdonnell/.m2/repository/clout/clout/1.1.0/clout-1.1.0.jar
    /Users/markmcdonnell/.m2/repository/com/amazonaws/aws-java-sdk-cloudwatchmetrics/1.9.13/aws-java-sdk-cloudwatchmetrics-1.9.13.jar
    /Users/markmcdonnell/.m2/repository/org/clojure/tools.nrepl/0.2.6/tools.nrepl-0.2.6.jar
    /Users/markmcdonnell/.m2/repository/com/amazonaws/aws-java-sdk-elasticloadbalancing/1.9.13/aws-java-sdk-elasticloadbalancing-1.9.13.jar
    /Users/markmcdonnell/.m2/repository/com/amazonaws/aws-java-sdk-iam/1.9.13/aws-java-sdk-iam-1.9.13.jar
    /Users/markmcdonnell/.m2/repository/com/amazonaws/aws-java-sdk-datapipeline/1.9.13/aws-java-sdk-datapipeline-1.9.13.jar
    /Users/markmcdonnell/.m2/repository/org/apache/httpcomponents/httpclient/4.3.3/httpclient-4.3.3.jar
    /Users/markmcdonnell/.m2/repository/org/eclipse/jetty/orbit/javax.servlet/2.5.0.v201103041518/javax.servlet-2.5.0.v201103041518.jar
    /Users/markmcdonnell/.m2/repository/org/clojure/clojure/1.6.0/clojure-1.6.0.jar
    /Users/markmcdonnell/.m2/repository/com/amazonaws/aws-java-sdk-sns/1.9.13/aws-java-sdk-sns-1.9.13.jar
    /Users/markmcdonnell/.m2/repository/com/amazonaws/aws-java-sdk-cloudtrail/1.9.13/aws-java-sdk-cloudtrail-1.9.13.jar
    /Users/markmcdonnell/.m2/repository/environ/environ/1.0.0/environ-1.0.0.jar
    /Users/markmcdonnell/.m2/repository/net/jpountz/lz4/lz4/1.2.0/lz4-1.2.0.jar
    /Users/markmcdonnell/.m2/repository/com/fasterxml/jackson/core/jackson-core/2.3.2/jackson-core-2.3.2.jar
    /Users/markmcdonnell/.m2/repository/compojure/compojure/1.1.6/compojure-1.1.6.jar
    /Users/markmcdonnell/.m2/repository/ring-server/ring-server/0.3.1/ring-server-0.3.1.jar
    /Users/markmcdonnell/.m2/repository/com/taoensso/nippy/2.7.0/nippy-2.7.0.jar
    /Users/markmcdonnell/.m2/repository/amazonica/amazonica/0.3.13/amazonica-0.3.13.jar
    /Users/markmcdonnell/.m2/repository/ring/ring-core/1.2.1/ring-core-1.2.1.jar
    /Users/markmcdonnell/.m2/repository/org/eclipse/jetty/jetty-io/7.6.8.v20121106/jetty-io-7.6.8.v20121106.jar
    /Users/markmcdonnell/.m2/repository/org/eclipse/jetty/jetty-http/7.6.8.v20121106/jetty-http-7.6.8.v20121106.jar
    /Users/markmcdonnell/.m2/repository/org/clojure/core.incubator/0.1.0/core.incubator-0.1.0.jar
    /Users/markmcdonnell/.m2/repository/com/taoensso/encore/1.11.2/encore-1.11.2.jar
    /Users/markmcdonnell/.m2/repository/com/amazonaws/aws-java-sdk-cognitosync/1.9.13/aws-java-sdk-cognitosync-1.9.13.jar
    /Users/markmcdonnell/.m2/repository/com/fasterxml/jackson/core/jackson-annotations/2.3.0/jackson-annotations-2.3.0.jar
    

    更新2

    /Users/markmcdonnell/.m2
    └── repository
        ├── amazonica
        ├── ant
        ├── antlr
        ├── aopalliance
        ├── args4j
        ├── asm
        ├── bbc
        ├── bidi
        ├── bouncycastle
        ├── ch
        ├── cheshire
        ├── circleci
        ├── classworlds
        ├── clj-stacktrace
        ├── clj-time
        ├── clojure-complete
        ├── clout
        ├── co
        ├── com
        ├── commons-beanutils
        ├── commons-cli
        ├── commons-codec
        ├── commons-collections
        ├── commons-digester
        ├── commons-discovery
        ├── commons-el
        ├── commons-fileupload
        ├── commons-httpclient
        ├── commons-io
        ├── commons-jelly
        ├── commons-jexl
        ├── commons-lang
        ├── commons-logging
        ├── commons-net
        ├── commons-validator
        ├── compojure
        ├── compojure-app
        ├── crypto-equality
        ├── crypto-random
        ├── de
        ├── dom4j
        ├── dotenv
        ├── doxia
        ├── environ
        ├── findbugs
        ├── geronimo-spec
        ├── hiccup
        ├── http-kit
        ├── instaparse
        ├── jackmorrill
        ├── javax
        ├── jaxen
        ├── jdom
        ├── jfree
        ├── jline
        ├── joda-time
        ├── junit
        ├── juxt
        ├── lein-dotenv
        ├── lein-environ
        ├── lein-ring
        ├── leinjacker
        ├── local
        ├── log4j
        ├── medley
        ├── modular
        ├── mx4j
        ├── nekohtml
        ├── net
        ├── ns-tracker
        ├── org
        ├── oro
        ├── pathetic
        ├── plexus
        ├── potemkin
        ├── prismatic
        ├── qdox
        ├── ring
        ├── ring-mock
        ├── ring-refresh
        ├── ring-server
        ├── robert
        ├── spurious-aws-sdk-helper
        ├── stax
        ├── thneed
        ├── tigris
        ├── trammel
        ├── velocity
        ├── watchtower
        ├── xalan
        ├── xerces
        ├── xml-apis
        ├── xom
        └── xpp3
    
    95 directories, 0 files
    

    更新3 lein with-profile +dev classpath

    /Users/markmcdonnell/Code/spurious-clojure-example/test
    /Users/markmcdonnell/Code/spurious-clojure-example/src
    /Users/markmcdonnell/Code/spurious-clojure-example/dev-resources
    /Users/markmcdonnell/Code/spurious-clojure-example/resources
    /Users/markmcdonnell/Code/spurious-clojure-example/target/classes
    /Users/markmcdonnell/.m2/repository/ns-tracker/ns-tracker/0.2.1/ns-tracker-0.2.1.jar
    /Users/markmcdonnell/.m2/repository/org/clojure/tools.macro/0.1.0/tools.macro-0.1.0.jar
    /Users/markmcdonnell/.m2/repository/com/amazonaws/aws-java-sdk-sqs/1.9.13/aws-java-sdk-sqs-1.9.13.jar
    /Users/markmcdonnell/.m2/repository/com/amazonaws/aws-java-sdk-s3/1.9.13/aws-java-sdk-s3-1.9.13.jar
    /Users/markmcdonnell/.m2/repository/com/amazonaws/aws-java-sdk-dynamodb/1.9.13/aws-java-sdk-dynamodb-1.9.13.jar
    /Users/markmcdonnell/.m2/repository/com/amazonaws/aws-java-sdk-swf-libraries/1.9.13/aws-java-sdk-swf-libraries-1.9.13.jar
    /Users/markmcdonnell/.m2/repository/org/clojure/algo.generic/0.1.2/algo.generic-0.1.2.jar
    /Users/markmcdonnell/.m2/repository/org/clojure/java.classpath/0.2.0/java.classpath-0.2.0.jar
    /Users/markmcdonnell/.m2/repository/watchtower/watchtower/0.1.1/watchtower-0.1.1.jar
    /Users/markmcdonnell/.m2/repository/com/amazonaws/aws-java-sdk-config/1.9.13/aws-java-sdk-config-1.9.13.jar
    /Users/markmcdonnell/.m2/repository/com/amazonaws/aws-java-sdk-redshift/1.9.13/aws-java-sdk-redshift-1.9.13.jar
    /Users/markmcdonnell/.m2/repository/org/apache/httpcomponents/httpcore/4.3.2/httpcore-4.3.2.jar
    /Users/markmcdonnell/.m2/repository/clojure-complete/clojure-complete/0.2.3/clojure-complete-0.2.3.jar
    /Users/markmcdonnell/.m2/repository/com/amazonaws/aws-java-sdk-glacier/1.9.13/aws-java-sdk-glacier-1.9.13.jar
    /Users/markmcdonnell/.m2/repository/com/amazonaws/aws-java-sdk/1.9.13/aws-java-sdk-1.9.13.jar
    /Users/markmcdonnell/.m2/repository/com/amazonaws/aws-java-sdk-directconnect/1.9.13/aws-java-sdk-directconnect-1.9.13.jar
    /Users/markmcdonnell/.m2/repository/ring/ring-codec/1.0.0/ring-codec-1.0.0.jar
    /Users/markmcdonnell/.m2/repository/org/eclipse/jetty/jetty-server/7.6.8.v20121106/jetty-server-7.6.8.v20121106.jar
    /Users/markmcdonnell/.m2/repository/joda-time/joda-time/2.2/joda-time-2.2.jar
    /Users/markmcdonnell/.m2/repository/com/amazonaws/aws-java-sdk-ec2/1.9.13/aws-java-sdk-ec2-1.9.13.jar
    /Users/markmcdonnell/.m2/repository/org/eclipse/jetty/jetty-continuation/7.6.8.v20121106/jetty-continuation-7.6.8.v20121106.jar
    /Users/markmcdonnell/.m2/repository/com/amazonaws/aws-java-sdk-lambda/1.9.13/aws-java-sdk-lambda-1.9.13.jar
    /Users/markmcdonnell/.m2/repository/com/amazonaws/aws-java-sdk-storagegateway/1.9.13/aws-java-sdk-storagegateway-1.9.13.jar
    /Users/markmcdonnell/.m2/repository/com/amazonaws/aws-java-sdk-ses/1.9.13/aws-java-sdk-ses-1.9.13.jar
    /Users/markmcdonnell/.m2/repository/clj-stacktrace/clj-stacktrace/0.2.5/clj-stacktrace-0.2.5.jar
    /Users/markmcdonnell/.m2/repository/com/amazonaws/aws-java-sdk-opsworks/1.9.13/aws-java-sdk-opsworks-1.9.13.jar
    /Users/markmcdonnell/.m2/repository/com/amazonaws/aws-java-sdk-core/1.9.13/aws-java-sdk-core-1.9.13.jar
    /Users/markmcdonnell/.m2/repository/org/eclipse/jetty/jetty-util/7.6.8.v20121106/jetty-util-7.6.8.v20121106.jar
    /Users/markmcdonnell/.m2/repository/ring/ring-servlet/1.2.1/ring-servlet-1.2.1.jar
    /Users/markmcdonnell/.m2/repository/com/amazonaws/aws-java-sdk-simpleworkflow/1.9.13/aws-java-sdk-simpleworkflow-1.9.13.jar
    /Users/markmcdonnell/.m2/repository/clj-time/clj-time/0.4.4/clj-time-0.4.4.jar
    /Users/markmcdonnell/.m2/repository/com/amazonaws/aws-java-sdk-logs/1.9.13/aws-java-sdk-logs-1.9.13.jar
    /Users/markmcdonnell/.m2/repository/robert/hooke/1.3.0/hooke-1.3.0.jar
    /Users/markmcdonnell/.m2/repository/com/amazonaws/aws-java-sdk-cloudsearch/1.9.13/aws-java-sdk-cloudsearch-1.9.13.jar
    /Users/markmcdonnell/.m2/repository/com/amazonaws/aws-java-sdk-simpledb/1.9.13/aws-java-sdk-simpledb-1.9.13.jar
    /Users/markmcdonnell/.m2/repository/com/amazonaws/aws-java-sdk-cloudfront/1.9.13/aws-java-sdk-cloudfront-1.9.13.jar
    /Users/markmcdonnell/.m2/repository/com/amazonaws/aws-java-sdk-sts/1.9.13/aws-java-sdk-sts-1.9.13.jar
    /Users/markmcdonnell/.m2/repository/com/amazonaws/aws-java-sdk-codedeploy/1.9.13/aws-java-sdk-codedeploy-1.9.13.jar
    /Users/markmcdonnell/.m2/repository/commons-io/commons-io/2.4/commons-io-2.4.jar
    /Users/markmcdonnell/.m2/repository/com/amazonaws/aws-java-sdk-kinesis/1.9.13/aws-java-sdk-kinesis-1.9.13.jar
    /Users/markmcdonnell/.m2/repository/com/amazonaws/aws-java-sdk-autoscaling/1.9.13/aws-java-sdk-autoscaling-1.9.13.jar
    /Users/markmcdonnell/.m2/repository/com/amazonaws/amazon-kinesis-client/1.1.0/amazon-kinesis-client-1.1.0.jar
    /Users/markmcdonnell/.m2/repository/commons-logging/commons-logging/1.1.3/commons-logging-1.1.3.jar
    /Users/markmcdonnell/.m2/repository/ring/ring-jetty-adapter/1.2.1/ring-jetty-adapter-1.2.1.jar
    /Users/markmcdonnell/.m2/repository/com/amazonaws/aws-java-sdk-support/1.9.13/aws-java-sdk-support-1.9.13.jar
    /Users/markmcdonnell/.m2/repository/commons-fileupload/commons-fileupload/1.3/commons-fileupload-1.3.jar
    /Users/markmcdonnell/.m2/repository/hiccup/hiccup/1.0.5/hiccup-1.0.5.jar
    /Users/markmcdonnell/.m2/repository/com/amazonaws/aws-java-sdk-elasticbeanstalk/1.9.13/aws-java-sdk-elasticbeanstalk-1.9.13.jar
    /Users/markmcdonnell/.m2/repository/org/clojure/tools.reader/0.7.3/tools.reader-0.7.3.jar
    /Users/markmcdonnell/.m2/repository/com/amazonaws/aws-java-sdk-cognitoidentity/1.9.13/aws-java-sdk-cognitoidentity-1.9.13.jar
    /Users/markmcdonnell/.m2/repository/ring-refresh/ring-refresh/0.1.2/ring-refresh-0.1.2.jar
    /Users/markmcdonnell/.m2/repository/org/tukaani/xz/1.5/xz-1.5.jar
    /Users/markmcdonnell/.m2/repository/com/amazonaws/aws-java-sdk-cloudwatch/1.9.13/aws-java-sdk-cloudwatch-1.9.13.jar
    /Users/markmcdonnell/.m2/repository/com/amazonaws/aws-java-sdk-rds/1.9.13/aws-java-sdk-rds-1.9.13.jar
    /Users/markmcdonnell/.m2/repository/com/amazonaws/aws-java-sdk-importexport/1.9.13/aws-java-sdk-importexport-1.9.13.jar
    /Users/markmcdonnell/.m2/repository/com/amazonaws/aws-java-sdk-cloudformation/1.9.13/aws-java-sdk-cloudformation-1.9.13.jar
    /Users/markmcdonnell/.m2/repository/commons-codec/commons-codec/1.6/commons-codec-1.6.jar
    /Users/markmcdonnell/.m2/repository/com/amazonaws/aws-java-sdk-route53/1.9.13/aws-java-sdk-route53-1.9.13.jar
    /Users/markmcdonnell/.m2/repository/ring/ring/1.2.1/ring-1.2.1.jar
    /Users/markmcdonnell/.m2/repository/org/clojure/tools.namespace/0.1.3/tools.namespace-0.1.3.jar
    /Users/markmcdonnell/.m2/repository/com/fasterxml/jackson/core/jackson-databind/2.3.2/jackson-databind-2.3.2.jar
    /Users/markmcdonnell/.m2/repository/com/amazonaws/aws-java-sdk-elastictranscoder/1.9.13/aws-java-sdk-elastictranscoder-1.9.13.jar
    /Users/markmcdonnell/.m2/repository/com/amazonaws/aws-java-sdk-elasticache/1.9.13/aws-java-sdk-elasticache-1.9.13.jar
    /Users/markmcdonnell/.m2/repository/org/iq80/snappy/snappy/0.3/snappy-0.3.jar
    /Users/markmcdonnell/.m2/repository/ring/ring-devel/1.2.1/ring-devel-1.2.1.jar
    /Users/markmcdonnell/.m2/repository/com/amazonaws/aws-java-sdk-kms/1.9.13/aws-java-sdk-kms-1.9.13.jar
    /Users/markmcdonnell/.m2/repository/com/amazonaws/aws-java-sdk-emr/1.9.13/aws-java-sdk-emr-1.9.13.jar
    /Users/markmcdonnell/.m2/repository/clout/clout/1.1.0/clout-1.1.0.jar
    /Users/markmcdonnell/.m2/repository/com/amazonaws/aws-java-sdk-cloudwatchmetrics/1.9.13/aws-java-sdk-cloudwatchmetrics-1.9.13.jar
    /Users/markmcdonnell/.m2/repository/org/clojure/tools.nrepl/0.2.6/tools.nrepl-0.2.6.jar
    /Users/markmcdonnell/.m2/repository/com/amazonaws/aws-java-sdk-elasticloadbalancing/1.9.13/aws-java-sdk-elasticloadbalancing-1.9.13.jar
    /Users/markmcdonnell/.m2/repository/com/amazonaws/aws-java-sdk-iam/1.9.13/aws-java-sdk-iam-1.9.13.jar
    /Users/markmcdonnell/.m2/repository/com/amazonaws/aws-java-sdk-datapipeline/1.9.13/aws-java-sdk-datapipeline-1.9.13.jar
    /Users/markmcdonnell/.m2/repository/org/apache/httpcomponents/httpclient/4.3.3/httpclient-4.3.3.jar
    /Users/markmcdonnell/.m2/repository/org/eclipse/jetty/orbit/javax.servlet/2.5.0.v201103041518/javax.servlet-2.5.0.v201103041518.jar
    /Users/markmcdonnell/.m2/repository/org/clojure/clojure/1.6.0/clojure-1.6.0.jar
    /Users/markmcdonnell/.m2/repository/com/amazonaws/aws-java-sdk-sns/1.9.13/aws-java-sdk-sns-1.9.13.jar
    /Users/markmcdonnell/.m2/repository/com/amazonaws/aws-java-sdk-cloudtrail/1.9.13/aws-java-sdk-cloudtrail-1.9.13.jar
    /Users/markmcdonnell/.m2/repository/environ/environ/1.0.0/environ-1.0.0.jar
    /Users/markmcdonnell/.m2/repository/net/jpountz/lz4/lz4/1.2.0/lz4-1.2.0.jar
    /Users/markmcdonnell/.m2/repository/com/fasterxml/jackson/core/jackson-core/2.3.2/jackson-core-2.3.2.jar
    /Users/markmcdonnell/.m2/repository/compojure/compojure/1.1.6/compojure-1.1.6.jar
    /Users/markmcdonnell/.m2/repository/ring-server/ring-server/0.3.1/ring-server-0.3.1.jar
    /Users/markmcdonnell/.m2/repository/com/taoensso/nippy/2.7.0/nippy-2.7.0.jar
    /Users/markmcdonnell/.m2/repository/amazonica/amazonica/0.3.13/amazonica-0.3.13.jar
    /Users/markmcdonnell/.m2/repository/ring/ring-core/1.2.1/ring-core-1.2.1.jar
    /Users/markmcdonnell/.m2/repository/org/eclipse/jetty/jetty-io/7.6.8.v20121106/jetty-io-7.6.8.v20121106.jar
    /Users/markmcdonnell/.m2/repository/org/eclipse/jetty/jetty-http/7.6.8.v20121106/jetty-http-7.6.8.v20121106.jar
    /Users/markmcdonnell/.m2/repository/org/clojure/core.incubator/0.1.0/core.incubator-0.1.0.jar
    /Users/markmcdonnell/.m2/repository/com/taoensso/encore/1.11.2/encore-1.11.2.jar
    /Users/markmcdonnell/.m2/repository/com/amazonaws/aws-java-sdk-cognitosync/1.9.13/aws-java-sdk-cognitosync-1.9.13.jar
    /Users/markmcdonnell/.m2/repository/com/fasterxml/jackson/core/jackson-annotations/2.3.0/jackson-annotations-2.3.0.jar
    

3 个答案:

答案 0 :(得分:1)

来自#clojure irc频道的Justin Smith帮我解决了这个问题。

似乎只运行lein install就足够了,但真正的问题是我看到的关于未找到命名空间的错误实际上是误导的,因为我的帮助库中的错误需要先修复之前我可以在我的示例应用程序中成功加载它。

建议是在REPL中彻底测试(例如,尝试在帮助程序自己的REPL中加载帮助程序命名空间,如果它不起作用,则运行linter以验证代码本身没有问题)。

答案 1 :(得分:0)

lein install是正确的方法,但您必须在命名或版本方面存在一些不一致。

显示leiningen实际使用的类路径会很有帮助:

lein classpath

或者使用个人资料(+ dev表示默认+开发):

lein with-profile +dev classpath

您应该在输出中列出的〜/ .m2下找到库。

lein deps :tree类似,您可能会发现通过它更容易找到不一致。

答案 2 :(得分:0)

我基本上有同样的问题,无法处理1.5天...... 解决方案包括:

  1. 在所有project.clj个文件和命名空间声明中正确获取groupid / artifactid依赖项。
  2. 库项目中有一个未使用的测试文件,该文件引用了另一个未在project.clj文件中声明的图表库。该项目编译和安装没有此图表lib声明。但是,在我删除此测试文件(或在其project.clj中包含所需的图表lib依赖项)之前,使用本地存储库引用此lib无效。
  3. 我必须从project.clj文件中删除这两个手动本地存储库声明: :local-repo "file:/home/atmamta/.m2/repository/" :repositories [["local" "file:/home/atmamta/.m2/repository/"]]
  4. 卸载了苹果快照版本及其相关的emacs库,使用最新的稳定版本重新安装它们,并修改了我的~/.lein/profiles.clj以反映这些更改。 即我将文件[cider/cider-nrepl "SNAPSHOT-x.y.z"][cider/cider-nrepl "0.8.2"]的{​​{1}}行改为{:user {:plugins ...}} 重要提示:苹果酒版必须与cider-nrepl版本相同。