calva

Wednesdays you might find @U0ETXRFEW in the Gather Calva space. Invite is https://gather.town/invite?token=GZqrm7CR and the password is `Be kind`.
bringe 2020-09-24T00:02:30.028700Z

@borkdude ctrl+c kills the terminal (and therefore the repl running in it) for me. As @chuck.cassel mentioned, it looks like for you vs code (maybe some extension?) is waiting on you to complete some chord. Maybe try disabling all extensions and then seeing if ctrl+c kills the repl/terminal. Though if some extension were binding those keys to something (some chord), it should show in your keyboard shortcuts.

pez 2020-09-24T11:59:38.001800Z

On the topic of using this channel for vscode general help. I totally love it. I’m still thrilled that I can read red on black in the vs code terminal now. Since I asked here and @sogaiu didn’t have the same mental blockers as I had so he could help me look for the settings in the right place.

2020-09-24T12:04:24.002400Z

lol, we can use each other as work-arounds for our mental blockers...i love it 🙂

borkdude 2020-09-24T12:47:59.002600Z

yes, this channel rocks

borkdude 2020-09-24T12:48:42.003100Z

does anyone use the Sync Settings extension? I tried it but I can't find where it actually stores the gist

il-tmfv 2020-09-24T16:08:22.003200Z

Having the same issue 😕 @stefan.toubia were you able to fix it?

borkdude 2020-09-24T16:10:59.003400Z

the code for the plugin is here: https://github.com/borkdude/clj-kondo.lsp maybe you can run using a local version with some debug statements in it. Without any repro I can't help

il-tmfv 2020-09-24T16:14:59.003800Z

I wish I knew what causes it 🙂 It works fine for hours but then suddenly some java process starts eating all CPU. And it stays even after I quit VSCode. After restart everything is fine. I’m trying to edit the same files, but it works ok.

borkdude 2020-09-24T16:15:54.004Z

using jps you can view which pid is related to clj-kondo

borkdude 2020-09-24T16:16:05.004200Z

17481 clj-kondo.lsp-standalone.jar

borkdude 2020-09-24T16:16:29.004400Z

and you can kill it of course, but other than that, I don't know. VSCode should be killing the server itself

borkdude 2020-09-24T16:16:36.004600Z

so it might as well be a bug in VSCode

borkdude 2020-09-24T16:17:18.004800Z

the source code of the language server itself hasn't been changed in over 4 months

borkdude 2020-09-24T16:18:44.005Z

Here's a similar bug: https://github.com/forcedotcom/salesforcedx-vscode/issues/968

il-tmfv 2020-09-24T16:20:32.005500Z

I’ve tried to quit vscode now and kondo process was killed as well You know, maybe it is killed every time, but when it is in “100% CPU” mode it takes more time, will wait next time :thumbsup:

pez 2020-09-24T16:21:33.006900Z

I use it. Afk atm so can't really check, but I'll get back to you if you don't figure it out before.

il-tmfv 2020-09-24T16:27:57.007Z

hmmm, I’ve just realized that I ran test via lein doo not sure how they work, I didn’t do their setup, but I see that it copies a lot of files to target/cljsbuild/public/... folder during start phase. Could it be the reason?

il-tmfv 2020-09-24T16:29:02.007200Z

And their content, well, is a copy. Can it confuse kondo? “Oh there are more than 1 definition”, somthing like that

borkdude 2020-09-24T16:31:12.007500Z

clj-kondo only lints files you are editing

il-tmfv 2020-09-24T16:35:57.007700Z

ok, will keep an eye on it thanks:+1:

borkdude 2020-09-24T16:36:33.007900Z

which OS are you on?

borkdude 2020-09-24T16:36:47.008100Z

could it be some virus scanner thing maybe

il-tmfv 2020-09-24T16:40:39.008300Z

macOS 10.14.6 no AV software installed It happens in the evening. Maybe OS schedules something like indexing (not sure why it affects kondo/java though), maybe something happens just b/c it works for a day and smth like memory leakage is happening

borkdude 2020-09-24T16:42:01.008600Z

What we can do is put a bunch of debug statements in the plugin, make a vsix package and you watch the clj-kondo output panel

borkdude 2020-09-24T16:42:54.008800Z

it should already output that it starts (and stops, but it's likely you won't see that since it only happens on workspace change )

borkdude 2020-09-24T16:43:59.009Z

il-tmfv 2020-09-24T16:46:27.009400Z

Let’s wait, I will avoid running tests on my machine. For some reason I have a feeling that it is somehow connected. Unfortunately I don’t remember the exact day when I ran them for the first time and when the issue started to appear.

Stefan T 2020-09-24T16:47:21.009700Z

I have to leave right now but I have not found anything useful yet

Stefan T 2020-09-24T16:47:46.009900Z

clearing the config didn’t help, eventually it just gets back to a bad state and I have to kill the process

Stefan T 2020-09-24T16:49:57.010100Z

I’m also running tests fairly often in editor, I wonder if there’s any relation

Stefan T 2020-09-24T16:50:08.010300Z

I haven’t seen anything helpful in the output yet

Stefan T 2020-09-24T16:50:41.010500Z

thanks for the link @borkdude that’s a good lead, I’ll read through and see if it helps

il-tmfv 2020-09-24T16:51:14.010700Z

Mine is in the gist called cloudSettings

il-tmfv 2020-09-24T16:52:26.010900Z

You should be able to find its id under sync.gist key in the preferences file

il-tmfv 2020-09-24T16:54:17.011200Z

so it is like this: https://gist.github.com/username/id

Stefan T 2020-09-24T16:55:23.011400Z

actually something else I noticed is the CPU for the clj-kondo extension is shooting through the roof as I type as well. That first spike was just typing a bunch of ((((((())))))), That last block I just wrote a tiny function and the CPU stayed high for 30s after I stopped

Stefan T 2020-09-24T16:56:00.011800Z

would definitely be helpful to get more verbose output on the language server, will check back in if I find out more

Stefan T 2020-09-24T16:57:14.012Z

also, jps shows two clj-kondo processes. Only one of them is misbehaving

borkdude 2020-09-24T17:44:51.012300Z

I do see CPU activity as I type, which is expected, but nothing abnormal. do you use one or multiple workspaces at the same time?

borkdude 2020-09-24T17:52:28.012500Z

Can you also try disabling Calva and see if you can trigger the same problem?

borkdude 2020-09-24T18:10:13.012700Z

@stefan.toubia @il.tmfv Added a bunch of debug statements which are visible in the clj-kondo output pane

borkdude 2020-09-24T18:10:26.012900Z

borkdude 2020-09-24T18:10:57.013300Z

Please install this VSIX

borkdude 2020-09-24T18:11:08.013700Z

and keep me posted

1👍
borkdude 2020-09-24T18:12:22.014Z

I made the VSIX from this branch, fyi https://github.com/borkdude/clj-kondo.lsp/tree/debug

borkdude 2020-09-24T18:13:24.014200Z

to build yourself:

script/build-server
cd vscode-extension && vsce package

Stefan T 2020-09-24T22:45:56.014700Z

oh very good point I forgot I had two workspaces open

Stefan T 2020-09-24T22:46:30.014900Z

thanks for the updates extension, I’ll test and see if I get any useful log info