Fork me on GitHub

is there a way to stop the clojure-lsp std-err buffer from being created? i tab into it by accident and then my emacs needs to be force quit :face_palm:


No, this is created automatically by lsp-mode for each server you start. Even so never saw this buffer cause any issues, I change to this buffer everytime I want to debug a error or something


i think it's because i've got a font with ligature support enabled


thanks for answering!

ūüĎć 1

clojure-lsp¬† Released¬†clojure-lsp¬†¬†with more improvements and some new¬†LSP¬†features! ‚ÄĘ General ‚ó¶ Bump Graalvm from 21.2.0 to 21.3.0 improving binary performance/size ‚ó¶ Fix wrong parse of code when code contains namespaced maps like¬†`#:foo{:bar 1}`. This issue was affecting a lot of features for example code actions. ‚ó¶ Bump datalevin from 0.5.26 to 0.5.27. ‚ó¶ Improve semantic tokens for dynamic vars, function definitions, namespaced and aliased keywords. ‚ó¶ Fix bug where¬†`:source-paths`¬†settings could be hot-reloaded with wrong-value. ‚ÄĘ Editor ‚ó¶ Deprecates setting¬†`:show-docs-arity-on-same-line?`¬†in favor of¬†`:hover`¬†`:arity-on-same-line?`. ‚ó¶ Add support to new¬†LSP¬†`LinkedEditingRange`¬†feature.¬† ‚ó¶ Improve suggested¬†`Add require ...`¬†code actions, this should make¬†clojure-lsp¬†smarter when user wants to add a missing require.¬† ‚ó¶ Change¬†`:notify-references-on-file-change`¬†default from¬†`false`¬†to¬†`true`, we had some performance improvements and I've been testing this for some time now and didn't see any new issues with that. This should improve a lot the UX when user change any code that is references on other files, updating the diagnostics for those files as well. ‚ó¶ Improve rename feature UX to output errors when it's not possible rename. ‚ó¶ Add support for¬†`window/showDocument`¬†LSP¬†method, used on¬†`create-test`¬†command/code action after creating the test to show the test file. ‚ó¶ Add new¬†`Unwind thread once`¬†and¬†`Unwind whole thread`¬†code actions to undo a thread call. ‚ó¶ Improve code actions performance requesting async all actions. ‚ó¶ Add new¬†LSP¬†custom method¬†`clojure/clojuredocs/raw`¬†which takes a symbol and a namespace (both strings) and returns any Clojuredocs entry found, otherwise¬†`null`. ‚ó¶ Fix missing keywords rename/references for destructured keywords. ‚ÄĘ CLI ‚ó¶ Show error/warning message when a classpath scan fail during analysis. Fixes¬† ‚ó¶ Add coloring to¬†`diagnostics`¬†output matching diagnostic severity. The highlights of this release are: ‚ÄĘ New code actions to¬†unwind¬†a thread call ‚ÄĘ Change¬†`:notify-references-on-file-change`¬†default value from false to true, which makes¬†clojure-lsp¬†notify other files when a change was made to a reference, Example: you change the function arity of the¬†`foo`¬†function from 1 to 2, then¬†clojure-lsp¬†will re-lint all usages/references of that function, making the diagnostics consistent with the whole project. ‚ÄĘ The huge improvement on the¬†`Add missing require`¬†code actions where¬†clojure-lsp¬†now try to infer some namespaces from alias like alias¬†``¬†for ns¬†``, please let me know if any corner case bugs on this one. ‚ÄĘ The new¬†`LinkedEditingRange`¬†feature which makes possible rename variables from the same buffer¬†live, check the gif This release was supported by¬†¬†clojurists-together¬†gratitude

catjam 4

notify-references-on-file-change change is a huge QOL bump, thank you


yeah, it's been some time I want to enable it by default, but the feature was with some performance issues, now I think it's good enough to be on by default :)


I'm seeing this exception in the LSP log (in Calva/VS Code) with that latest version:

Nov 02, 2021 2:22:50 PM org.eclipse.lsp4j.jsonrpc.json.StreamMessageProducer fireError
SEVERE: Unable to invoke no-args constructor for class org.eclipse.lsp4j.SetTraceParams. Registering an InstanceCreator with Gson for this type may fix this problem.
java.lang.RuntimeException: Unable to invoke no-args constructor for class org.eclipse.lsp4j.SetTraceParams. Registering an InstanceCreator with Gson for this type may fix this problem.
	at org.eclipse.lsp4j.jsonrpc.json.adapters.MessageTypeAdapter.fromJson(
	at org.eclipse.lsp4j.jsonrpc.json.adapters.MessageTypeAdapter.parseParams(
	at org.eclipse.lsp4j.jsonrpc.json.MessageJsonHandler.parseMessage(
	at org.eclipse.lsp4j.jsonrpc.json.MessageJsonHandler.parseMessage(
	at org.eclipse.lsp4j.jsonrpc.json.StreamMessageProducer.handleMessage(
	at org.eclipse.lsp4j.jsonrpc.json.StreamMessageProducer.listen(
	at java.util.concurrent.Executors$
	at java.util.concurrent.ThreadPoolExecutor.runWorker(
	at java.util.concurrent.ThreadPoolExecutor$
Caused by: java.lang.reflect.InvocationTargetException
	at java.lang.reflect.Method.invoke(
	... 19 more
Caused by: java.lang.IllegalArgumentException: Class org.eclipse.lsp4j.SetTraceParams is instantiated reflectively but was never registered. Register the class by using org.graalvm.nativeimage.hosted.RuntimeReflection
	at sun.misc.Unsafe.allocateInstance(
	... 22 more
and I'm not getting proper semantic token coloring.


This could be a reflection issue. @UKFSJSM38


Yes it is, I'll take a look


According to lsp4j, it is related with

A notification that should be used by the client to modify the trace setting of the server.
It doesn't seem to block any clojure-lsp feature and it's not a new bug it seems, I'll include the fix on the next release


thanks for the report @U04V70XH6


Hmm, I wound back to 2021.10.20-16.49.47 and restarted and I'm still not getting proper semantic token coloring (strings and comments are white in the Dark+ theme in VS Code where they used to be brown and green respectively, as I recall from last week).


OK, the trace exception above has nothing to do with the semantic token coloring. Seems to be an extension conflict in VS Code. Will debug and bring that up elsewhere...


Interesting. I don't get the trace exception unless I have Clover enabled. With Clover disabled, it all works -- including coloring.


that's odd, AFAICS this is a new LSP notification that happens when client change the trace settings:


and probably started happen with the semantic tokens calva update that bumped the vscode-language-client package which included this new trace feature


but my guess is that it has nothing related with clover


anyway, I fixed on master, it should not throw any exception on next release


Interesting. OK. But Clover does seem to interfere with coloring/token stuff somehow.


(it's related to the Clojure grammar file -- I have a workaround: everything's fine now ūüôā )

ūüĎć 1