clj-kondo

https://github.com/clj-kondo/clj-kondo
gmercer 2021-02-28T04:51:49.040600Z

Hi, I could not seem to find the exclude mechanism for ignoring java.lang.* e.g. (Integer/parseInt numstr) , any clues appreciated

borkdude 2021-02-28T07:53:19.041500Z

@gmercer please give a full standalone repro and then the expected outcome

gmercer 2021-02-28T08:00:25.042500Z

@borkdude I just cloned https://github.com/mogenslund/liquid and ran clj-kondo --lint src/liq/editor.cljc

gmercer 2021-02-28T08:03:14.043200Z

It is a cljc so this command removes the warning cat src/liq/editor.cljc | clj-kondo --lang clj --lint -

borkdude 2021-02-28T08:04:38.044100Z

If it’s cljc Java interop should not occur outside of branches

borkdude 2021-02-28T08:05:32.044900Z

Unless it targets a different runtime than JVM and JS

gmercer 2021-02-28T08:21:20.045300Z

ahh - I see

gmercer 2021-02-28T08:22:25.046100Z

sorry - for what looks like cross-posting - but they were slightly different problems (in my mind)

gmercer 2021-02-28T08:24:08.047600Z

PS really enjoying your latest videos .. I was wondering about a bb/graalvm version of liquid .. which requires some understanding of sci+graal, any chance of a video on that topic?

gmercer 2021-02-28T08:24:59.048300Z

e.g. a tiny project that you could show is not sci compatible, the slight changes to make it so and how that can be graal'd

borkdude 2021-02-28T08:26:07.048900Z

@gmercer You need sci if you need eval in your program. If you don't need this, you can possibly just compile it with GraalVM as is

borkdude 2021-02-28T08:27:06.049300Z

I'm not sure what it entails to compile liquid to graalvm. What does it use for UI?

borkdude 2021-02-28T08:28:33.049900Z

java.awt. That should maybe work on GraalVM 21 and only on linux: https://medium.com/graalvm/graalvm-21-0-introducing-a-new-way-to-run-java-df894256de28

borkdude 2021-02-28T08:29:13.050700Z

@gmercer The main incompatibility with sci and clojure is the absence of deftype and definterface and some edge cases around defprotocol and reify

gmercer 2021-02-28T08:34:13.052400Z

@borkdude liquid is a zero dependency text based vim/emacs mash - beware it may leave you terminal a bit wonky, definitely worth a try

lread 2021-02-28T17:44:02.053800Z

What do you think about a linter that warns if you are using a var/ns from a dep that is marked with :no-doc?

borkdude 2021-02-28T17:48:05.053900Z

borkdude 2021-02-28T17:48:47.054400Z

@lee That seems interesting, but clj-kondo doesn't know what is a dep and what is your own source

lread 2021-02-28T17:50:15.055500Z

yah, was describing in the abstract, you’d have to tell it to exclude your nses.

lread 2021-02-28T18:08:38.058Z

BTW, liking your vids @borkdude! If I hadn’t chosen to be a frugally retired hobbyist, I’d certainly be sponsoring you (and others). Hopefully my contributions in other areas in some small way make up for my lack of $ sponsorship!

❤️ 1
borkdude 2021-02-28T18:10:13.058200Z

It sure does, don't worry :)

lread 2021-02-28T18:11:53.058400Z

I’d love to see you be able to afford to do OSS as your main job!

borkdude 2021-02-28T18:12:03.058600Z

I've also mean meaning to do something like this for vars from .impl namespaces. Let's think more about it. But first: dinner.

lread 2021-02-28T18:12:34.058800Z

Bon appetit!

borkdude 2021-02-28T19:42:35.059400Z

@juhoteperi Thanks for sponsoring me on Github! Would you like access to the private sponsors channel?

juhoteperi 2021-03-01T09:31:17.059700Z

Thanks! Sure.