This page is not created by, affiliated with, or supported by Slack Technologies, Inc.
2022-01-12
Channels
- # announcements (2)
- # babashka (26)
- # beginners (48)
- # calva (32)
- # cider (23)
- # clj-kondo (61)
- # cljfx (3)
- # clojure (93)
- # clojure-australia (2)
- # clojure-europe (23)
- # clojure-losangeles (1)
- # clojure-nl (5)
- # clojure-uk (4)
- # clojurescript (46)
- # cloverage (9)
- # code-reviews (1)
- # copenhagen-clojurians (1)
- # cursive (39)
- # data-science (6)
- # datahike (8)
- # deps-new (8)
- # depstar (2)
- # etaoin (1)
- # fulcro (2)
- # funcool (2)
- # graalvm (5)
- # jackdaw (3)
- # java (17)
- # jobs-discuss (43)
- # kaocha (2)
- # leiningen (25)
- # malli (8)
- # minecraft (1)
- # missionary (8)
- # observability (6)
- # off-topic (37)
- # other-languages (12)
- # practicalli (1)
- # reagent (4)
- # releases (78)
- # remote-jobs (1)
- # sci (9)
- # shadow-cljs (13)
- # spacemacs (6)
- # sql (1)
- # tools-deps (30)
- # xtdb (3)
clojure-extras v0.4.0 is out! IntelliJ plugin which builds on Cursive with clj-kondo, inline eval, and more.
How do you actually use it to get clj-kondo linting? That page doesn't mention anything
I installed it and was able to keymap the inline eval
and they show up in problems I guess?
but it may take a while before your project is fully set up in intellij due to indexing etc. it's only after cursive is fully started that the plugin will load, I think
@UQTHDKJ8J may be able to tell your more, he wrote the integration.
ah, maybe it hadn't indexed yet when I tried it
note that this indexing has nothing to do with clj-kondo, but it just takes a while before everything launches I think
I just did, not seeing any kondo stuff
I see same under the tools panel, and get no warnings on code like that
what version of intellij? I'm using IntelliJ IDEA 2021.3.1 (Ultimate Edition)
over here
2021.2.3 and yes, latest Cursive
Cursive 1.12.2-eap1-2021.2
inline eval stuff works
My IntelliJ knowledge ends here, maybe upgrading helps, else I hope @UQTHDKJ8J will help :)
this is the latest cursive (EAP stream), re https://github.com/cursive-ide/cursive/blob/master/CHANGELOG.md from Dec 23
doesn't seem likely that matters here but dunno
perhaps we can try to open the same project, if you're working on something open source
I mean, I have a half dozen projects open, it doesn't work anywhere
@UQTHDKJ8J It seems that adding some logging (or whatever is appropriate for a plugin) could be helpful
it's possible I have turned off whatever feature suggests things generally (I'm not entirely sure what that is called)
I don't see any clj-kondo problems
no errors in the intellij log
I tried restarting intellij again too
IntelliJ IDEA 2021.3.1 (Community Edition) Build #IC-213.6461.79, built on December 28, 2021 com.cursiveclojure.cursive (1.12.2-eap1-2021.3) com.github.brcosta.cljstuffplugin (0.4.0) works for me fine
btw, it's possible to separately disable cursive's suggestions from clj-kondo's according to @UQTHDKJ8J
I do get other problems
Unused global declaration etc
in general, that stuff works, I just don't see any of the clj-kondo suggestions from clojure extras
I didn't think I needed to have anything set up ?
I did not have anything already installed or set up (as it said it was built-in)
I have clj-kondo working from cmdline, and up to now I’ve had it working with the file-watchers plugin too. I’ve switched that off, and now I expected -extras to kick in, which is has not.
something like clj -Sdeps '{:deps {clj-kondo/clj-kondo {:mvn/version "2021.12.19"}}}' -m clj-kondo.main --lint src
?
clj -Sdeps '{:deps {clj-kondo/clj-kondo {:mvn/version "2021.12.19"}}}' -M -m clj-kondo.main --lint src
it appears if I rename the .clj-kondo folder in my project root I don't get kondo suggestions anymore
that works from terminal (trying in tools.deps.alpha)
so, @U064X3EF3 can you try to make a .clj-kondo
directory in your project?
Hi guys, trying to follow the thread, @U08BJGV6E this is definitely a problem, I think this is hardcoded in the plugin code, I need to fix it :)
even weirder, if I rename config.edn inside, that isn't a problem and suggestions still work
if I make a .clj-kondo directory, it starts working
Also, I’m not forwarding clj-kondo errors to intellij, so the user can’t tell this is the error
@UQTHDKJ8J Just curious, why is the plugin reading the .clj-kondo
directory?
@U064X3EF3 Feel free to ping me via DM or #clj-kondo if you want help setting up clj-kondo on repos like tools.deps.alpha etc to get correct linting with respect to macros, etc.
:config-dir is hardcoded to ProjectBashPath/.clj-kondo, my bad, I think this one got there when I was trying to fix that dependencies problem with cursive way back
@UQTHDKJ8J you don't need to set the config dir manually, clj-kondo figures that out automatically, assuming that it is started in the right working directory
@UQTHDKJ8J if you send along the complete filename (absolute file path) then clj-kondo walks up the filename until it finds a .clj-kondo
directory, that should be a robust solution if you're linting one file at a time.
https://github.com/clj-kondo/clj-kondo/blob/67e992aa6c92e6675997e5558729d6efd2db51c6/src/clj_kondo/core.clj#L107
Release 1.0.0-alpha6 of Fulcrologic’s statecharts library. https://github.com/fulcrologic/statecharts
This version contains a few bug fixes, and refines the external event queue to include an extra parameter. This is a minor breaking change (you can jsut add an _
arg to your handlers and otherwise ignore it).
The default data model in the simple provider also changed to flat, because the scoped data model leads to subtle bugs in statecharts that are hard to reason about. This is also a potential breaking change if you were relying on scoping in the internal data model. You can easily specify the scoped model as an argument so it is a trivial fix.