This page is not created by, affiliated with, or supported by Slack Technologies, Inc.
2022-06-16
Channels
- # announcements (33)
- # atom-editor (1)
- # aws (21)
- # babashka (174)
- # babashka-sci-dev (2)
- # beginners (59)
- # calva (4)
- # chlorine-clover (9)
- # clj-kondo (51)
- # clojars (7)
- # clojure (86)
- # clojure-czech (4)
- # clojure-europe (21)
- # clojure-france (6)
- # clojure-nl (1)
- # clojure-uk (2)
- # conjure (7)
- # core-async (3)
- # core-logic (3)
- # cursive (10)
- # data-science (8)
- # datalevin (14)
- # datomic (12)
- # events (1)
- # fulcro (5)
- # graalvm (10)
- # gratitude (3)
- # honeysql (3)
- # hyperfiddle (3)
- # introduce-yourself (4)
- # joyride (3)
- # leiningen (3)
- # malli (13)
- # minecraft (15)
- # music (1)
- # off-topic (40)
- # pathom (16)
- # polylith (28)
- # portal (25)
- # rdf (15)
- # remote-jobs (3)
- # shadow-cljs (23)
- # specter (1)
- # sql (5)
- # tools-deps (25)
- # xtdb (31)
I saw some weird error today: Can't parse blablabla.clj, No implementation of method: :tag of protocol: #'clj-kondo.impl.rewrite-clj.node.protocols/Node found for class: nil - clj-kondo
please try with the most recent version of clj-kondo on the command line, to avoid any downstream involvement
this is not the real namespace I have, but I think the ns name is irrelevant in that case
is it possible to make a minimal repro though and do it with clj-kondo on the command line and send that repro here?
❯ clj-kondo --lint . ./some-random-file.clj:0:0: error: Can't parse ../some-random-file.clj, No implementation of method: :tag of protocol: #'clj-kondo.impl.rewrite-clj.node.protocols/Node found for class: nil
protocols & implems of these etc etc, but the problem lies here. If I remove half of the code the issue goes away, I ll try to bisect the thing until I find the culprit
yes, when something unexpected happens, then clj-kondo doesn't know where to put the issue and it just puts it at 0:0
Is it possible to discourage usage of whole namespace? I know there is https://github.com/clj-kondo/clj-kondo/blob/master/doc/linters.md#discouraged-var but would be great to place the warning directly on ns declaration because requiring namespace is a mutation and might cause some problems even if vars are not used
will do
I think there were also some requests recently to lint access from namespace X to namespace Y etc
you can deprecate in the namespace metadata
https://github.com/clojure/clojure/blob/master/src/clj/clojure/parallel.clj#L9 for example
I guess that's not actually metadata, but it could be
that's proposed in https://clojure.atlassian.net/browse/CLJ-706 (not sure if that will ever get looked at, Rich was noncommittal the last time he did)
@U064X3EF3 those namespaces out of my control. They are coming from a library and to alter metadata I have to load it first which is exactly what I'm trying to avoid.
FWI - https://github.com/clj-kondo/clj-kondo/pull/1724 @U04V15CAJ adding new linter was surprisingly easy, kudos for the architecture of kondo
Nice. Maybe we should add some example of using an ns group + the in option? Maybe :from
is a better name than :in
?
In my head in
emerged from the sentence: "In namespaces #{X Y Z} discourage usage of namespace A"
can't make such sentence with from
but probably it is a problem of my english 🙂
We already use the word :from
in the analysis here:
https://github.com/clj-kondo/clj-kondo/blob/master/analysis/README.md
so imo that would be more consistent
sounds right to me, I'll change it
@U04V4KLKC I invited you to #clj-kondo-dev for some PR feedback
Thanks!