lsp

dominicm 2025-08-22T10:10:15.321029Z

During startup does clojure-lsp send $/progress messages? I'm failing to display them in my client. Seemed to hang where the ----- is, then I got a lot of progress messages at once:

2025-08-22T10:08:45.700Z  INFO [clojure-lsp.startup:314] - [startup] Analyzing source paths for project root /Users/dominicmonroe/src/github.com/...
---------[did nothing here]---------------
2025-08-22T10:08:45.702Z  INFO [clojure-lsp.startup:77] - :internal/project-paths-analyzed-by-clj-depend 1ms
2025-08-22T10:12:54.880Z  INFO [clojure-lsp.kondo:174] - :internal/kondo-findings->analysis 0ms
2025-08-22T10:12:54.882Z  INFO [clojure-lsp.startup:73] - :internal/project-paths-analyzed-by-clj-kondo 249181ms
2025-08-22T10:12:56.076Z  INFO [clojure-lsp.dep-graph:280] - :internal/maintain-dep-graph 1192ms
`

dominicm 2025-08-22T10:16:24.134119Z

oh, maybe the clojure-lsp.startup happened. You can see the 4 minute gap yourself. There seemed to be no progress messages there, but they'd be very useful!

ericdallo 2025-08-22T10:55:23.006559Z

Yes. It sends in real time, but maybe your client is only presenting after initialize finished

dominicm 2025-08-22T10:55:47.888159Z

Hmm, odd. Probably getting into a bug way more specific than I can easily search for in neovim

dominicm 2025-08-22T10:55:50.592969Z

That's a shame.

dominicm 2025-08-22T10:56:07.129749Z

The 4 minute wait is painful while I wait for setup.

ericdallo 2025-08-22T10:57:19.441669Z

Agree, the good news is it should be faster on next startups as it caches

dominicm 2025-08-22T10:57:28.760499Z

This is the next startup 🙂

dominicm 2025-08-22T10:57:33.284669Z

It always takes that long

dominicm 2025-08-22T11:19:16.048589Z

I assume the cache isn't broken... but it could be! the files aren't changing at all between invocations

ericdallo 2025-08-22T11:19:52.425979Z

you can check server logs too see if there is anything wrong

ericdallo 2025-08-22T11:19:59.420689Z

https://clojure-lsp.io/troubleshooting/#server-log

dominicm 2025-08-22T11:20:13.481649Z

I don't see anything obviously wrong in the log

dominicm 2025-08-22T11:23:42.786519Z

DEBUG [clojure-lsp.startup:273] - [startup] Using cached classpath this works, for example

dominicm 2025-08-22T11:24:32.556859Z

I guess it's the clj-kondo analysis which isn't caching? is that stored in .lsp or .clj-kondo? because my .clj-kondo seems to be fast.

ericdallo 2025-08-22T11:28:30.579419Z

if the project source is huge, that's it

ericdallo 2025-08-22T11:28:51.689689Z

clj-kondo is fast when analyzing few files, the whole codebase with analysis it's another history :)

dominicm 2025-08-22T11:29:21.305589Z

ah. and it can't be cached?

ericdallo 2025-08-22T11:33:50.811109Z

not really

dominicm 2025-08-22T11:34:09.587179Z

ah, then I guess I'm stuck with the 4m startup time 🙂

ericdallo 2025-08-22T11:36:10.893379Z

yeah, it's rare to have a so long startup IMO

ericdallo 2025-08-22T11:36:26.716789Z

maybe try clojure-lsp diagnostics in your terminal and check if it takes the same

dominicm 2025-08-22T11:36:28.558309Z

yeah, a 400kloc project is unusual

ericdallo 2025-08-22T11:36:44.278209Z

also make sure you are using a native binary, not sure how you installed

dominicm 2025-08-22T11:36:50.805559Z

yep, using native binary

ericdallo 2025-08-26T12:12:04.870409Z

yeah, sounds related, vscode had a similar bug in the past

dominicm 2025-08-26T05:57:26.959649Z

https://github.com/j-hui/fidget.nvim/issues/139 I bet neovim's built-in $/progress handler has the same flaw which was fixed a couple years ago here.