Fork me on GitHub
#lsp
<
2021-04-15
>
Karol Wójcik09:04:59

Does anybody experience the same wrong warning from clj-kondo?

(defn ^:export init! <-- unused init! public fn
  []
  (mount!))

borkdude09:04:26

this is not a warning from clj-kondo, but from an additional linter in clojure-lsp

Karol Wójcik09:04:04

Ahh. Sorry @U04V15CAJ. You're right. I thought that clojure-lsp relies on clj-kondo entirely when it comes to code checking! Thanks!

ericdallo12:04:42

Yes, check clojure-lsp docs about how to disable public linters

zane20:04:31

Is this the right default behavior? It seems common for (non-private) functions to be unused within a namespace.

ericdallo20:04:36

yes, it's the default behaviour, there are corner cases like API public functions and datomic functions I think but user can disable for some namespaces like in the docs

Karol Wójcik09:04:32

Found another bug in clojure-lsp. When moving the cursor to (:require) line, the namespace line vanishes.

ericdallo12:04:37

This is not a clojure-lsp bug, probably some issue with lsp-ui from emacs

👍 1
ericdallo12:04:38

You can ask for help on Emacs-lsp discord channel

anonimitoraf14:04:02

I'm on this commit:

commit 8a294181096a151cd4ee845a127b6e7306805800 (HEAD -> master, upstream/master)
Author: Eric Dallo <[email protected]>
Date:   Tue Apr 13 22:02:27 2021 -0300

    Improve resolve-macro-as command to check and log if couldn't resolve the macro.