lsp

mpenet 2026-03-02T09:30:20.469939Z

I have an odd issue from time to time after buffer reformat: Error running timer: (wrong-type-argument json-value-p "(ns ....

mpenet 2026-03-02T09:30:33.273829Z

that seems to happen on buffers with emojis & co

mpenet 2026-03-02T09:31:05.779619Z

✉️ becomes -> ��� and save is prevented

mpenet 2026-03-02T09:31:09.986019Z

for instance

mpenet 2026-03-02T09:45:16.825299Z

(I am using eglot)

mpenet 2026-03-02T09:51:20.199499Z

ah! I think it's eglot-booster

mpenet 2026-03-02T09:52:04.226459Z

related: https://github.com/blahgeek/emacs-lsp-booster/issues/43

👍 1
cjohansen 2026-03-02T09:34:26.646999Z

We've had some issues where different people on the team experience different clj-kondo linting rules for our dependencies. We don't check in kondo-configs, and we suspect the inconsistencies stems from how lsp runs "import configs". Would it be possible to make lsp run import configs in such a way that the configs are always in sync with library versions in deps.edn?

ericdallo 2026-03-02T11:59:01.756409Z

Actually this sync should always happen otherwise it's a bug. What may happen is someone is having issues with lsp classpath scan during startup and ignoring, starting clojure-lsp in a basic mode

ericdallo 2026-03-02T11:59:25.257429Z

maybe try to rm .lsp/.cache and restart lsp

cjohansen 2026-03-02T12:08:21.644139Z

When should this sync happen?

cjohansen 2026-03-02T12:08:39.344679Z

My expectation was that it would happen when deps.edn changes.

ericdallo 2026-03-02T12:09:24.471579Z

it should happen when clojure-lsp is starting

ericdallo 2026-03-02T12:09:51.890639Z

no, clojure-lsp doesn't auto re-lint classpath when deps.edn yet, only if you restarted it

ericdallo 2026-03-02T12:10:31.828689Z

then it will check that deps.edn changed and change its cached classpath

cjohansen 2026-03-02T12:34:39.383799Z

I see. I very rarely restart Emacs (or lsp, for that matter), so that's probably the source of the problem

ericdallo 2026-03-02T12:37:55.158919Z

lsp-workspace-restart should retrigger the restart

cjohansen 2026-03-02T12:40:55.520569Z

Yeah, but it's a little heavy-handed, and it would be good if it happened automatically when needed.

ericdallo 2026-03-02T12:42:14.678249Z

yes there is a idea to re-lint classpath when that happens, it just that considering the effort it's just easier to restart manually

cjohansen 2026-03-02T12:54:40.929819Z

Restarting lsp by hand isn't really top of mind (and probably shouldn't be!) so this has caused us some grief with inconsistent linting. We're looking into using a git hook to refresh the kondo configs on changes to deps.edn now. Still not ideal, as the hooks must be manually enabled on everyone's machine.

ericdallo 2026-03-02T12:56:14.347819Z

agree, this is something clojure-lsp should take care, feel free to create a issue about it so I can prioritize Even so, a git hook looks too much to me to be honest, how much you change deps.edn daily? never saw Nubank with thousands of projects and people requiring this at that point

cjohansen 2026-03-02T12:59:51.297139Z

It doesn't change often, but people generally never quit/restart Emacs 😅

ericdallo 2026-03-02T13:00:31.710489Z

fair enough

ericdallo 2026-03-02T13:01:43.006499Z

It's been a while since I thought about a dynamic classpath scan, I think it's time to support that

cjohansen 2026-03-02T13:02:11.759059Z

Would be useful 👍

borkdude 2026-03-02T12:34:45.231079Z

@ericdallo https://karanbansal.in/blog/claude-code-lsp/

👍 1
1