Does anybody here use cljs.spec.test.alpha/instrument
? I just ran into an error, where a var only became instrumented, after deleting .cpcache
. Just a restart and regular clean didn't help ...
adding the ns calling instrument
to :cache-blockers
should fix it though, right?
instrument
is a rather difficult beast since it is a macro
it isn't so much about the ns calling instrument, it is more about ensuring that that ns is compiled after all the namespaces you want to be instrumented
so the ns calling it should directly require all the namespaces
so I doubt that .cpcache
or any cache really had anything to do with it
rather you were maybe instrumenting a var that just happened to still be compiling when instrument
was already running due to parallel compile
you mean "directly" as in "transitively"? because that's what we already did.
I'm using the no-argument version of instrument
, that would instrument all specced vars. After adding the transitively dependent namespace, that also calls instrument
, to :cache-blockers
, it seems fine ..
yes if you require transitively then the ns calling the instrument
might not recompile
if you require directly it will
oof
so blocking the cache or (ns ^:dev/always this.calls.instrument)
works too
since it is a macro is must be recompiled to reflect the changes done in other namespaces
ok, that's good. because fn-specs are already used pervasively throughout the project, and will be used even more in the future ..
thanks!
Hello! I wonder how do you debug (with stepping debuger) CLJS code when compiling with shadow? I use Cursive IDE so it would be also nice to find out how that works with debugging.
@stebokas it doesn't work. you can use the chrome built-in debugger a little bit but thats about it.