Fork me on GitHub
#calva
<
2022-04-17
>
rayat16:04:59

In Calva am I supposed to get diagnostics (ie squiggles and such, or Problems) for undeclared variables? I only ever see them when running the code in terminal/repl/evaluating, never as vscode Problems/diagnostics.

all-clear 1
bringe18:04:58

Yes, you should. I’m not sure what would cause them to not show up unless you’ve added some clj-kondo config to make that happen, or if clojure-lsp isn’t starting.

thanks3 1
rayat21:04:25

LSP has started, and am jacked in. What sort of kondo config would disable them? Any logs I should look at that would help me investigate or debug? There are no errors that I notice in notifs or Calva Says. Right now (somehow) other language features like Go To- and References are working, but this ostensibly isn't. Does it matter that it's a shadow cljs project at all?

ericdallo00:04:07

@U037TPXKBGS there was a clojure-lsp bug where if you have source-paths configured incorrectly, it would not even return clj-kondo diagnostics, I fixed some days ago, included in the tomorrow's release, but that means you probably have wrong source-paths yet, you probably should take a look https://clojure-lsp.io/settings/#source-paths-discovery

👀 1
ericdallo00:04:21

BTW, you don't need to jack in to get errors/warnings, all of that comes from clojure-lsp (clj-kondo used under the hood)

rayat01:04:38

Yeah, I figured I'd add as much detail. Thanks! Running npx shadow classpath indeed returns the expected paths. Searching thru c-lsp's vsc output for diagnostics": \[\w returns nothing, but there are 800 instances of "diagnostics": [] , when I know that shouldn't be true. What could be going wrong?

rayat01:04:43

And man, this whole time I just thought we didn't have this feature - I need more faith in y'alls hard work!

1
rayat03:04:58

After some combination of the above, it now works! Somehow...

Erkan18:04:34

Hello! Would it be possible to configure Calva somehow to run inline tests (just pure clojure test) for cljs files?

pez18:04:03

It needs to be solved in cider-nrepl. Check the issues on that repository and see if it is moving anywhere.

👍 1
1