This page is not created by, affiliated with, or supported by Slack Technologies, Inc.
2018-03-05
Channels
- # beginners (229)
- # cider (54)
- # cljs-dev (187)
- # cljsrn (1)
- # clojure (187)
- # clojure-dev (5)
- # clojure-italy (31)
- # clojure-losangeles (1)
- # clojure-russia (3)
- # clojure-spec (76)
- # clojure-uk (29)
- # clojurescript (94)
- # cursive (18)
- # datascript (8)
- # datomic (26)
- # docker (6)
- # emacs (19)
- # figwheel (6)
- # fulcro (41)
- # garden (1)
- # graphql (1)
- # hoplon (33)
- # jobs (1)
- # jobs-discuss (1)
- # lein-figwheel (14)
- # leiningen (7)
- # nrepl (10)
- # nyc (1)
- # off-topic (2)
- # onyx (2)
- # parinfer (25)
- # portkey (6)
- # powderkeg (1)
- # protorepl (1)
- # re-frame (14)
- # reagent (14)
- # shadow-cljs (31)
- # spacemacs (3)
- # test-check (33)
- # uncomplicate (1)
- # unrepl (40)
- # vim (5)
- # yada (16)
lein uberjar
hangs in my project and from google I see that this is due to a top level form that gets evaluated.
However, I can’t eyeball any such thing.
Any way to get an idea what is causing lein uberjar
to hang?
nakiya: you can use jstack or even Control-\ to show all the stack traces in the vm
one of those (likely the longest) will be the one that is stuck, and point to the top level side effect
nakiya: and pedantically, all top level forms are evaluated when you do AOT, if something shouldn't happen when AOT compiling you shouldn't do it at the top level (or you shouldn't AOT compile)
doing anything in top-level forms besides defining vars and functions seems... dirty.
@kenrestivo: it's trickier than that though, for example if you do something with a side effect inside the body of def - people don't intuitively expect that to run during AOT, but it will
ah, yes, i've been bitten by that before