magomimmo / modern-cljs

A series of tutorials on ClojureScript
2.92k stars 289 forks source link

boolean double defined and ns doesn't conform to spec errors when trying tutorial 1 example #452

Open vigilancetech-com opened 6 years ago

vigilancetech-com commented 6 years ago

~/tmp/modern-cljs $ boot cljs Writing main.cljs.edn... Compiling ClojureScript... • main.js WARNING: boolean? already refers to: #'clojure.core/boolean? in namespace: cljs.util, being replaced by: #'cljs.util/boolean? java.lang.Thread.run Thread.java: 748 java.util.concurrent.ThreadPoolExecutor$Worker.run ThreadPoolExecutor.java: 624 java.util.concurrent.ThreadPoolExecutor.runWorker ThreadPoolExecutor.java: 1149 java.util.concurrent.FutureTask.run FutureTask.java: 266 ...
clojure.core/binding-conveyor-fn/fn core.clj: 2022 adzerk.boot-cljs/compile-1/fn boot_cljs.clj: 126 adzerk.boot-cljs/compile boot_cljs.clj: 66 boot.pod/call-in pod.clj: 413 ...
org.projectodd.shimdandy.impl.ClojureRuntimeShimImpl.invoke ClojureRuntimeShimImpl.java: 102 org.projectodd.shimdandy.impl.ClojureRuntimeShimImpl.invoke ClojureRuntimeShimImpl.java: 109 ...
boot.pod/call-in
pod.clj: 410 boot.pod/eval-fn-call pod.clj: 357 ...
clojure.core/require core.clj: 5947 (repeats 2 times) clojure.core/apply core.clj: 659 ...
clojure.core/load-libs core.clj: 5909 clojure.core/load-libs core.clj: 5925 clojure.core/apply core.clj: 659 ...
clojure.core/load-lib core.clj: 5868 clojure.core/load-lib core.clj: 5887 clojure.core/load-lib/fn core.clj: 5888 clojure.core/load-one core.clj: 5848 ...
clojure.core/load core.clj: 6029 clojure.core/load core.clj: 6045 clojure.core/load/fn core.clj: 6046 ...
adzerk.boot-cljs.impl/eval169 impl.clj: 1 adzerk.boot-cljs.impl/eval169/loading--auto-- impl.clj: 1 ...
clojure.core/require core.clj: 5947 (repeats 2 times) clojure.core/apply core.clj: 659 ...
clojure.core/load-libs core.clj: 5909 clojure.core/load-libs core.clj: 5925 clojure.core/apply core.clj: 659 ...
clojure.core/load-lib core.clj: 5868 clojure.core/load-lib core.clj: 5887 clojure.core/load-lib/fn core.clj: 5888 clojure.core/load-one core.clj: 5848 ...
clojure.core/load core.clj: 6029 clojure.core/load core.clj: 6045 clojure.core/load/fn core.clj: 6046 ...
cljs.build.api/eval2477 api.clj: 8 cljs.build.api/eval2477/loading--auto-- api.clj: 8 ...
clojure.core/require core.clj: 5947 (repeats 2 times) clojure.core/apply core.clj: 659 ...
clojure.core/load-libs core.clj: 5909 clojure.core/load-libs core.clj: 5925 clojure.core/apply core.clj: 659 ...
clojure.core/load-lib core.clj: 5868 clojure.core/load-lib core.clj: 5887 clojure.core/load-lib/fn core.clj: 5888 clojure.core/load-one core.clj: 5848 ...
clojure.core/load core.clj: 6029 clojure.core/load core.clj: 6045 clojure.core/load/fn core.clj: 6046 ...
cljs.compiler/eval2483 compiler.cljc: 9 cljs.compiler/eval2483/loading--auto-- compiler.cljc: 9 ...
clojure.core/require core.clj: 5947 (repeats 2 times) clojure.core/apply core.clj: 659 ...
clojure.core/load-libs core.clj: 5909 clojure.core/load-libs core.clj: 5925 clojure.core/apply core.clj: 659 ...
clojure.core/load-lib core.clj: 5868 clojure.core/load-lib core.clj: 5887 clojure.core/load-lib/fn core.clj: 5888 clojure.core/load-one core.clj: 5848 ...
clojure.core/load core.clj: 6029 clojure.core/load core.clj: 6045 clojure.core/load/fn core.clj: 6046 ...
cljs.source-map/eval2489 source_map.clj: 1 cljs.source-map/eval2489/loading--auto-- source_map.clj: 1 ...
clojure.core/require core.clj: 5947 (repeats 2 times) clojure.core/apply core.clj: 659 ...
clojure.core/load-libs core.clj: 5909 clojure.core/load-libs core.clj: 5925 clojure.core/apply core.clj: 659 ...
clojure.core/load-lib core.clj: 5868 clojure.core/load-lib core.clj: 5887 clojure.core/load-lib/fn core.clj: 5888 clojure.core/load-one core.clj: 5848 ...
clojure.core/load core.clj: 6029 clojure.core/load core.clj: 6045 clojure.core/load/fn core.clj: 6046 ...
clojure.spec.alpha/macroexpand-check alpha.clj: 689 clojure.core/ex-info core.clj: 4739 clojure.lang.ExceptionInfo: Call to clojure.core/ns did not conform to spec: In: [1] val: ((require [clojure.string :as string] [cljs.source-map.base64 :as base64])) fails spec: :clojure.core.specs.alpha/ns-form at: [:args] predicate: (cat :docstring (? string?) :attr-map (? map?) :clauses :clojure.core.specs.alpha/ns-clauses), Extra input

data: {#object[clojure.lang.Keyword 0x2e9fda69 ":clojure.spec.alpha/problems"] [{#object[clojure.lang.Keyword 0x17cdf2d0 ":path"] [#object[clojure.lang.Keyword 0x7fd244dc ":args"]], #object[clojure.lang.Keyword 0x1755e85b ":reason"] "Extra input", #object[clojure.lang.Keyword 0x736d6a5c ":pred"] (#object[clojure.lang.Symbol 0x2371aaca "clojure.spec.alpha/cat"] #object[clojure.lang.Keyword 0x5b529706 ":docstring"] (#object[clojure.lang.Symbol 0x63fdab07 "clojure.spec.alpha/?"] #object[clojure.lang.Symbol 0x7b5a12ae "clojure.core/string?"]) #object[clojure.lang.Keyword 0x5553d0f5 ":attr-map"] (#object[clojure.lang.Symbol 0x1af687fe "clojure.spec.alpha/?"] #object[clojure.lang.Symbol 0x14dda234 "clojure.core/map?"]) #object[clojure.lang.Keyword 0x3f390d63 ":clauses"] #object[clojure.lang.Keyword 0x74a6a609 ":clojure.core.specs.alpha/ns-clauses"]), #object[clojure.lang.Keyword 0x75679ade ":val"] ((#object[clojure.lang.Symbol 0x5a411614 "require"] [#object[clojure.lang.Symbol 0x2374d36a "clojure.string"] #object[clojure.lang.Keyword 0x33f04b7a ":as"] #object[clojure.lang.Symbol 0x54d18072 "string"]] [#object[clojure.lang.Symbol 0x1506f20f "cljs.source-map.base64"] #object[clojure.lang.Keyword 0x33f04b7a ":as"] #object[clojure.lang.Symbol 0x47a5b70d "base64"]])), #object[clojure.lang.Keyword 0x424fd310 ":via"] [#object[clojure.lang.Keyword 0x1a45193b ":clojure.core.specs.alpha/ns-form"]], #object[clojure.lang.Keyword 0x38f116f6 ":in"] [1]}], #object[clojure.lang.Keyword 0x5286c33a ":clojure.spec.alpha/spec"] #object[clojure.spec.alpha$regex_spec_impl$reify__2436 0x406c12d0 "clojure.spec.alpha$regex_spec_impl$reify__2436@406c12d0"], #object[clojure.lang.Keyword 0x6e6d5d29 ":clojure.spec.alpha/value"] (#object[clojure.lang.Symbol 0x5c530d1e "cljs.source-map.base64-vlq"] (#object[clojure.lang.Symbol 0x5a411614 "require"] [#object[clojure.lang.Symbol 0x2374d36a "clojure.string"] #object[clojure.lang.Keyword 0x33f04b7a ":as"] #object[clojure.lang.Symbol 0x54d18072 "string"]] [#object[clojure.lang.Symbol 0x1506f20f "cljs.source-map.base64"] #object[clojure.lang.Keyword 0x33f04b7a ":as"] #object[clojure.lang.Symbol 0x47a5b70d "base64"]])), #object[clojure.lang.Keyword 0x6c25e6c4 ":clojure.spec.alpha/args"] (#object[clojure.lang.Symbol 0x5c530d1e "cljs.source-map.base64-vlq"] (#object[clojure.lang.Symbol 0x5a411614 "require"] [#object[clojure.lang.Symbol 0x2374d36a "clojure.string"] #object[clojure.lang.Keyword 0x33f04b7a ":as"] #object[clojure.lang.Symbol 0x54d18072 "string"]] [#object[clojure.lang.Symbol 0x1506f20f "cljs.source-map.base64"] #object[clojure.lang.Keyword 0x33f04b7a ":as"] #object[clojure.lang.Symbol 0x47a5b70d "base64"]]))}

clojure.lang.Compiler$CompilerException: clojure.lang.ExceptionInfo: Call to clojure.core/ns did not conform to spec: In: [1] val: ((require [clojure.string :as string] [cljs.source-map.base64 :as base64])) fails spec: :clojure.core.specs.alpha/ns-form at: [:args] predicate: (cat :docstring (? string?) :attr-map (? map?) :clauses :clojure.core.specs.alpha/ns-clauses), Extra input {:clojure.spec.alpha/problems [{:path [:args], :reason "Extra input", :pred (clojure.spec.alpha/cat :docstring (clojure.spec.alpha/? clojure.core/string?) :attr-map (clojure.spec.alpha/? clojure.core/map?) :clauses :clojure.core.specs.alpha/ns-clauses), :val ((require [clojure.string :as string] [cljs.source-map.base64 :as base64])), :via [:clojure.core.specs.alpha/ns-form], :in [1]}], :clojure.spec.alpha/spec #object[clojure.spec.alpha$regex_spec_impl$reify2436 0x406c12d0 "clojure.spec.alpha$regex_spec_impl$reify2436@406c12d0"], :clojure.spec.alpha/value (cljs.source-map.base64-vlq (require [clojure.string :as string] [cljs.source-map.base64 :as base64])), :clojure.spec.alpha/args (cljs.source-map.base64-vlq (require [clojure.string :as string] [cljs.source-map.base64 :as base64]))}, compiling:(cljs/source_map/base64_vlq.clj:1:1) clojure.lang.ExceptionInfo: clojure.lang.ExceptionInfo: Call to clojure.core/ns did not conform to spec: In: [1] val: ((require [clojure.string :as string] [cljs.source-map.base64 :as base64])) fails spec: :clojure.core.specs.alpha/ns-form at: [:args] predicate: (cat :docstring (? string?) :attr-map (? map?) :clauses :clojure.core.specs.alpha/ns-clauses), Extra input {:clojure.spec.alpha/problems [{:path [:args], :reason "Extra input", :pred (clojure.spec.alpha/cat :docstring (clojure.spec.alpha/? clojure.core/string?) :attr-map (clojure.spec.alpha/? clojure.core/map?) :clauses :clojure.core.specs.alpha/ns-clauses), :val ((require [clojure.string :as string] [cljs.source-map.base64 :as base64])), :via [:clojure.core.specs.alpha/ns-form], :in [1]}], :clojure.spec.alpha/spec #object[clojure.spec.alpha$regex_spec_impl$reify2436 0x406c12d0 "clojure.spec.alpha$regex_spec_impl$reify2436@406c12d0"], :clojure.spec.alpha/value (cljs.source-map.base64-vlq (require [clojure.string :as string] [cljs.source-map.base64 :as base64])), :clojure.spec.alpha/args (cljs.source-map.base64-vlq (require [clojure.string :as string] [cljs.source-map.base64 :as base64]))}, compiling:(cljs/source_map/base64_vlq.clj:1:1) line: 48 ~/tmp/modern-cljs $

defcool commented 5 years ago

(set-env! :source-paths #{"src/cljs/"} :resource-paths #{"html/"} :dependencies '[ [org.clojure/clojure "1.10.0"] [org.clojure/clojurescript "1.10.516"] [adzerk/boot-cljs "2.1.5"]] )

totemo commented 4 years ago

Just commenting for the benefit of others who (like me) fell at the first hurdle (Tutorial 1): the resolution is, as already commented, to add an explicit dependency on the ClojureScript version.

Duplicate or related issues are: #433 #444 and https://github.com/boot-clj/boot-cljs/issues/195.