Saturday, 31 August 2013

java.lang.IllegalArgumentException when trying to run a clojure web application

java.lang.IllegalArgumentException when trying to run a clojure web
application

I'm trying to run a clojure web app I wrote using ring, compojure, hiccup,
and lein-ring, and when I run lein ring server, I get an exception.
java.lang.IllegalArgumentException: No implementation of method: :as-file
of protocol: #'clojure.java.io/Coercions found for class: clojure.l
ang.PersistentVector
at clojure.core$_cache_protocol_fn.invoke(core_deftype.clj:541)
at clojure.java.io$fn__8496$G__8491__8501.invoke(io.clj:35)
at clojure.java.io$file.invoke(io.clj:413)
at leiningen.core.project$absolutize.invoke(project.clj:308)
at clojure.lang.AFn.applyToHelper(AFn.java:163)
at clojure.lang.AFn.applyTo(AFn.java:151)
at clojure.core$apply.invoke(core.clj:619)
at clojure.core$partial$fn__4190.doInvoke(core.clj:2396)
at clojure.lang.RestFn.applyTo(RestFn.java:137)
at clojure.core$apply.invoke(core.clj:619)
at clojure.core$update_in.doInvoke(core.clj:5587)
at clojure.lang.RestFn.invoke(RestFn.java:445)
at leiningen.core.project$absolutize_path.invoke(project.clj:314)
at clojure.core.protocols$fn__6034.invoke(protocols.clj:143)
at
clojure.core.protocols$fn__6005$G__6000__6014.invoke(protocols.clj:19)
at clojure.core.protocols$seq_reduce.invoke(protocols.clj:31)
at clojure.core.protocols$fn__6028.invoke(protocols.clj:48)
at
clojure.core.protocols$fn__5979$G__5974__5992.invoke(protocols.clj:13)
at clojure.core$reduce.invoke(core.clj:6177)
at leiningen.core.project$absolutize_paths.invoke(project.clj:322)
at leiningen.core.project$init_profiles.doInvoke(project.clj:603)
at clojure.lang.RestFn.invoke(RestFn.java:425)
at leiningen.core.project$read.invoke(project.clj:684)
at leiningen.core.project$read.invoke(project.clj:685)
at leiningen.core.project$read.invoke(project.clj:686)
at leiningen.core.main$_main$fn__1332.invoke(main.clj:256)
at leiningen.core.main$_main.doInvoke(main.clj:252)
at clojure.lang.RestFn.invoke(RestFn.java:408)
at clojure.lang.Var.invoke(Var.java:415)
at clojure.lang.AFn.applyToHelper(AFn.java:161)
at clojure.lang.Var.applyTo(Var.java:532)
at clojure.core$apply.invoke(core.clj:617)
at clojure.main$main_opt.invoke(main.clj:335)
at clojure.main$main.doInvoke(main.clj:440)
at clojure.lang.RestFn.invoke(RestFn.java:436)
at clojure.lang.Var.invoke(Var.java:423)
at clojure.lang.AFn.applyToHelper(AFn.java:167)
at clojure.lang.Var.applyTo(Var.java:532)
at clojure.main.main(main.java:37)
The googling I've done shows two options, test suits not named properly,
or having multiple java source paths in my project.clj, both of which I've
checked, so I'm stumped.
Can someone please sift through the stack trace and point me in the right
direction? Thank you.

No comments:

Post a Comment