On Fri, 22 Dec 2017, at 18:41, Stuart Sierra wrote:
> Also be aware that AOT-compilation[1] causes all sorts of havoc with
> namespace reloading, because AOT-compiled .class files get read by a
> different ClassLoader.>
Is there any place explaining how exactly Clojure compiles and loads the
co
If you do have namespace names that do not correspond with the file name
they are placed in, in a Clojure/Java files, Eastwood can find them for you
quickly. Eastwood doesn't analyze ClojureScript files, though.
Andy
https://github.com/jonase/eastwood
On Fri, Dec 22, 2017 at 9:41 AM, Stuart Si
>
> => CompilerException java.lang.Exception: namespace 'foo.bar' not found
> after loading '/foo/bar', compiling:(*cider-repl foo*:65:7)
>
An error like this usually means that the ns declaration does not match the
expected namespace name, based on the file path.
Also be aware that AOT-compil
Thanks Andy, that was helpful.
In my example foo.bar is in *loaded-libs*
I removed it by calling (clojure.tools.namespace.reload/remove-lib 'foo.bar)
Interestingly when I then did a require I get a different error, the file
is loaded, but the namespace not found.
(require '[foo.bar :as bar])
=>
I don't have the answer, but perhaps a clue that might lead you to one: the
function remove-lib inside of the tools.namespace library does this:
(defn remove-lib
"Remove lib's namespace and remove lib from the set of loaded libs."
[lib]
(remove-ns lib)
(dosync (alter @#'clojure.core/*loade
Hi,
Apologies in advance for the possibly stupid question!
I was having a problem with clojure.tools.namespace.repl/refresh where a
namespace that had been successfully loaded subsequently failed to be
reloaded when doing a repl/refresh.
Whilst investigating the problem, (this is probably tota