This page is not created by, affiliated with, or supported by Slack Technologies, Inc.
2021-09-29
Channels
- # aws (8)
- # babashka (45)
- # beginners (83)
- # cider (23)
- # clj-on-windows (4)
- # cljdoc (23)
- # clojars (6)
- # clojure (68)
- # clojure-dev (33)
- # clojure-europe (75)
- # clojure-nl (1)
- # clojure-uk (4)
- # clojurescript (14)
- # conjure (6)
- # data-science (15)
- # datascript (7)
- # datomic (47)
- # docker (15)
- # events (1)
- # fulcro (4)
- # graphql (3)
- # jobs (4)
- # lsp (14)
- # nginx (2)
- # nrepl (2)
- # off-topic (41)
- # pathom (18)
- # pedestal (1)
- # polylith (72)
- # reitit (8)
- # reveal (1)
- # shadow-cljs (48)
- # tools-build (11)
- # tools-deps (24)
- # xtdb (8)
Does uber
prune deps that aren’t used? (Maybe the term is “tree shaking”?)
I am trying to set the uberjar main to a namespace in a :local/root
dep that is never called called and getting a Error: Failed to load class ...
When a require
the namespace in an arbitrary source file and rebuild the uberjar, the error is no longer raised.
no pruning, should use all deps
are you compiling? if so, you might need to specify that it should be compiled if it's not in your src dir
by default compile-clj will compile all the namespaces in your project srcs
but it doesn't know about the local dep ones
So maybe the way to go in this case is to inspect the basis to get the path to the dep(s) and call compile-clj on each? Does that sound sane?
compile-clj can be given a set of namespaces to compile
I think maybe I would call it twice - once the way you are
and again just to specify any additional specific namespaces to compile