Fork me on GitHub
#leiningen
<
2019-03-26
>
beders19:03:12

sorry to just barge in and demand help: I just upgraded leiningen to 2.9.1 and if I just run lein in my project I'm getting this mysterious error message:

clojure.lang.Compiler$CompilerException: Syntax error macroexpanding clojure.core/ns at (clojure/tools/namespace.clj:15:1).
Any ideas how to fix that? Thank you!

beders19:03:36

as far as I know I'm using the latest [org.clojure/tools.trace "0.7.10"]

beders19:03:34

(which doesn't seem to trigger it) I'm at loss why an upgrade from 2.8.1 to 2.9.1 would cause that much trouble

danielcompton21:03:18

Can you show the full stack trace, and the command you ran?

beders21:03:26

and thank you for looking at this!

Alex Miller (Clojure team)21:03:33

I think this is due to using an old version of tools.namespace, which had an ns problem that failed the specs added in clojure 1.9

Alex Miller (Clojure team)21:03:42

most likely pulled in via a plugin

Alex Miller (Clojure team)21:03:16

I kind of suspect lein-autoreload here as thing pulling it in?

Alex Miller (Clojure team)21:03:55

maybe check ~/.lein/profiles.clj too

Alex Miller (Clojure team)21:03:13

lein-autoreload -> ns-tracker -> tools.namespace

Alex Miller (Clojure team)21:03:57

you might be able to set :jvm-opts ["-Dclojure.spec.skip-macros=true"] in your project.clj to get past the error enough to be able to use lein to figure out how to remove/fix that dep

Alex Miller (Clojure team)21:03:24

why lein upgrade triggered that, I can't explain unless it's a change to using clojure 1.9 for lein itself

beders23:03:52

thank you very much, Alex. Yes, lein-autoreload is pulled in

beders23:03:55

that solved the problem. Thank you!