Deraen / less4clj

Less compiler for Clj, Lein and Boot, using Less4j

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

lein less4j fails with clojure alpha 14

calvis opened this issue · comments

Exception in thread "main" java.lang.IllegalArgumentException: Call to clojure.core/fn did not conform to spec:
In: [0] val: leiningen.less4j/compile-less fails spec: :clojure.core.specs/arg-list at: [:args :bs :arity-1 :args] predicate: vector?
In: [0] val: leiningen.less4j/compile-less fails spec: :clojure.core.specs/args+body at: [:args :bs :arity-n] predicate: (cat :args :clojure.core.specs/arg-list :prepost (? map?) :body (* any?))
:clojure.spec/args  (leiningen.less4j/compile-less [& _] (clojure.core/doseq [[path__5687__auto__ relative-path__5688__auto__] [["resources/public/css/app.main.less" "app.main.less"] ["resources/public/css/vendor.main.less" "vendor.main.less"]]] (clojure.core/println (clojure.core/format "Compiling {less}... %s" relative-path__5688__auto__)) (clojure.core/let [result__5689__auto__ (try (less4clj.core/less-compile-to-file path__5687__auto__ "resources/public/css" relative-path__5688__auto__ {}) (catch java.lang.Exception e__5690__auto__ (if false (clojure.core/println (.getMessage e__5690__auto__)) (throw e__5690__auto__))))] (clojure.core/doseq [warning__5691__auto__ (:warnings result__5689__auto__)] (clojure.core/println (clojure.core/format "WARN: %s %s\n" (:message warning__5691__auto__) (clojure.core/str (if (:uri (:source warning__5691__auto__)) (clojure.core/str "on file " (:uri (:source warning__5691__auto__)) (if (:line warning__5691__auto__) (clojure.core/str " at line " (:line warning__5691__auto__) " character " (:char warning__5691__auto__))))))))))))

I'm using [deraen/lein-less4j "0.6.1"]

I'm quite sure the problem is in Clojure, not here.

I am reasonably sure this macro falls under 2 here: https://groups.google.com/d/msg/clojure/_slHTn-Ej1Y/1dY0n_3uCQAJ

because replacing compile-less with ~'compile-less fixes the problem

Ah, right, now I understand even the spec error.

Yeah, the spec error is not the most helpful description, I don't see a check for a namespaced symbol. Had to go google searching.

Do you want to send a PR with the fix?