Open boymaas opened 8 years ago
Can you confirm whether this happens with the bare ClojureScript compiler, i.e. is cljsbuild at fault here?
When I compile using the cljs.build.api it uses the correct clojurescript version. If that is what you mean? I've experimented with aot, without aot, the exclusions etc. The "AOT" case is the one that triggers the version drop only when going through cljsbuild. Hope that this helps, for now I am building without the aot classifier, and printing the clojurescipt version explicitly in case another drop should occur.
-Boy
I was able to reproduce this problem. It seems that we are passing the correct dependencies to leiningen when calling eval-in-project
, but when having a look at the classpath later on, two ClojureScript versions are present: 0.0-3211
and 1.7.170-aot
. When using 1.7.170
without aot, only 1.7.170
is included and 0.0-3211
is not in the classpath.
I probably need to have a look at the leiningen source code or talk to someone from the leiningen team to figure out, why the behaviour is different for aot.
@mneise I've done a bit of spelunking in Leiningen dealing with transitive dependencies recently, happy to help out.
@danielcompton Sure, that would be great! We need to figure out where and how the classpath is created. Had a quick look at this file so far: https://github.com/technomancy/leiningen/blob/master/leiningen-core/src/leiningen/core/classpath.clj.
Repo to reproduce this problem: https://github.com/mneise/cljsbuild-431.
Hi all,
:dependencies [[org.clojure/clojure "1.7.0"] [org.clojure/clojurescript "1.7.170" ;; :classifier "aot" :exclusion [org.clojure/data.json] ] [org.clojure/data.json "0.2.6" :classifier "aot"]
When enabling the :classifier "aot" the clojurescript version of 1.7.170 gets ignored and cljs project compiles with 0.0-3211.
I stumbled upon this by accident when using the (random-uuid) function which is not present in 0.0-3211.
-Boy