You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Sometimes unbalanced parens cause the "lein-cljsbuild auto" process to crash with an NPE, and I have to restart the process.
(on $body :click:#anil
(fn [e]
(log"test";;)
)
)
yields
wei:papyrus wei$ lein cljsbuild auto main-prod template-prod
Compiling ClojureScript.
Compiling "../app/assets/javascripts/bin/template.js" from ["src/cljs-template"]...
* Notification delivered.
Compiling "../app/assets/javascripts/bin/template.js" failed.
Exception in thread "main" java.lang.NullPointerException
at java.util.regex.Matcher.getTextLength(Matcher.java:1140)
at java.util.regex.Matcher.reset(Matcher.java:291)
at java.util.regex.Matcher.<init>(Matcher.java:211)
at java.util.regex.Pattern.matcher(Pattern.java:888)
at clj_stacktrace.utils$re_gsub.invoke(utils.clj:6)
at clj_stacktrace.core$clojure_ns.invoke(core.clj:14)
at clj_stacktrace.core$parse_trace_elem.invoke(core.clj:68)
at clojure.core$map$fn__4087.invoke(core.clj:2434)
at clojure.lang.LazySeq.sval(LazySeq.java:42)
at clojure.lang.LazySeq.seq(LazySeq.java:60)
at clojure.lang.Cons.next(Cons.java:39)
at clojure.lang.RT.next(RT.java:587)
at clojure.core$next.invoke(core.clj:64)
at clojure.core$reduce1.invoke(core.clj:880)
at clojure.core$reverse.invoke(core.clj:888)
The text was updated successfully, but these errors were encountered:
Hmm, lein-cljsbuild definitely catches all compiler errors, so those shouldn't cause the auto process to stop. I guess what's happening here (from the stack trace) is that clj-stacktrace (which lein-cljsbuild uses to pretty-print stack traces, with color, etc) is crashing when lein-cljsbuild tries to print the unmatched-parens exception. Bleh!
I checked to see if clj-stacktrace has a newer version out, but the latest that I see is 0.2.5, which is what lein-cljsbuild depends on right now.
I don't see any open bug reports for clj-stacktrace that seem related to this problem. Maybe you could open one?
If I have some time later this week, I can get the exact contents of the exception that clj-stacktrace is crashing while trying to print, which might be helpful to debug clj-stacktrace.
Sometimes unbalanced parens cause the "lein-cljsbuild auto" process to crash with an NPE, and I have to restart the process.
yields
The text was updated successfully, but these errors were encountered: