calva

pez 2025-03-20T19:59:20.538619Z

Dear Calva friends: https://github.com/BetterThanTomorrow/calva/releases/tag/v2.0.493https://github.com/BetterThanTomorrow/calva/issues/2757 Latest clojure-lsp adds semantic tokens for ignored (`#_`) forms. This disables the syntax highlighting of these forms. This release of Calva filters the comment tokens away, restoring Calva’s highlighting of ignored forms. It also seems to avoid the bug in VS Code insiders which messes up rendering of files with ignored forms something awful. Good in case that bugs slips out to the stable VS Code builds.

Thierry 2025-03-24T07:44:20.393839Z

I still have the dissapearing text issue with this version 😞

Thierry 2025-03-24T07:55:48.014309Z

With latest insiders build and latest Calva

Thierry 2025-03-24T07:55:54.784309Z

Going to roll back again

pez 2025-03-24T07:56:26.335739Z

Are you sure you’re actually have latest Calva active?

Thierry 2025-03-24T07:57:15.283899Z

Calva is utilizing cider-nrepl and clojure-lsp to create this VS Code experience.
  nREPL dependencies configured:
    nrepl: 1.3.1
    cider-nrepl: 0.52.1
    cider/piggieback: 0.6.0
  clojure-lsp version configured: latest

If you are new to Calva, please see: 
  And please consider the command: **Calva: Create a Getting Started REPL project**

Calva version used: v2.0.494
vscode:
Version: 1.99.0-insider
Commit: 299b150bd5c0227099c9b03dc56c5073ec0ff5e2
Date: 2025-03-24T05:03:53.092Z
Electron: 34.3.2
ElectronBuildId: 11161073
Chromium: 132.0.6834.210
Node.js: 20.18.3
V8: 13.2.152.41-electron.0
OS: Linux x64 6.11.0-19-generic

pez 2025-03-24T07:58:42.912089Z

Thanks. Can you repro it with this simple text?

#_[
]

Thierry 2025-03-24T07:59:05.326049Z

will need to jack-in again, this happens directlly after jack-in, hold on 🙂

pez 2025-03-24T07:59:28.015489Z

Jack-in just shouldn’t matter…

Thierry 2025-03-24T07:59:50.192049Z

It's probably because of the app that starts logging into the repl window

pez 2025-03-24T08:00:24.008879Z

Ah, so then I am super curious about what could be in there.

pez 2025-03-24T08:00:43.807309Z

And you can maybe avoid the issue by using the terminal as output.

Thierry 2025-03-24T08:00:46.298969Z

just text about starting modules

Thierry 2025-03-24T08:01:21.433969Z

I will try that, was super happy I could use the repl window again as I cant get used to repl output not showing eval directly at my cursor

pez 2025-03-24T08:02:12.099459Z

You can keep evals there.

pez 2025-03-24T08:02:51.310779Z

My cursor is just never there. Lol.

Thierry 2025-03-24T08:03:21.788309Z

my cursor is in other files too, lol. I read the output from the repl window

Thierry 2025-03-24T08:04:18.041179Z

moved everything back into the terminal window for now

Thierry 2025-03-24T08:04:23.949269Z

will see if i can repro

Thierry 2025-03-24T08:05:06.836149Z

the logging of the app startup ends with a sequence filled with namespaces like so:

#'aorta.module.zorgdomein.endpoints/service
 #'aorta.service.import/service
 #'aorta.service.import-xml/service)

Thierry 2025-03-24T08:06:01.735419Z

other then those lines there are no hash characters in the logging lines

pez 2025-03-24T08:06:22.846519Z

A reason we don’t recommend using the REPL window for stdout and stderr is that it often contains unstructured text that can throw things out of whack, since it is a Clojure file. But for evaluation results it should be fine. (Minus VS Code Insiders shenanigans). That output has an unbalanced paren, for instance.

Thierry 2025-03-24T08:06:55.628309Z

after moving everything into terminal it seems okay

Thierry 2025-03-24T08:07:19.756279Z

I had it like so:

"evalResults": "repl-window",
    "evalOutput": "repl-window",
    "otherOutput": "terminal"
and now have it like so:
"evalResults": "terminal",
    "evalOutput": "terminal",
    "otherOutput": "terminal"

pez 2025-03-24T08:08:08.978479Z

It may not be about the hash characters at all. So far it has all been about some clojure-lsp provided semantic token spanning more than one line. But this could be a different beast, because I don’t think clojure-lsp is even active in the REPL window… I could remember that incorrectly.

pez 2025-03-24T08:08:55.410479Z

So evalOutput is typically stdout. FYI. evalResults is structured output since it is Clojure data.

Thierry 2025-03-24T08:08:57.860109Z

I have these in my lsp config.edn

:source-paths-ignore-regex
 ["aorta-develop\/dev.*"
  "aorta-develop\/resources.*"
  "aorta-develop\/test.*"
  "\/home\/thierry\/\.m2\/repository.*"
  "\/home\/loud\/\.m2\/repository.*"]
 :paths-ignore-regex
 ["^\.calva.*"
  "^\.clj-kondo.*"
  "\.joyride.*"
  "^build.*"
  "^\.lsp.*"
  "^\.portal.*"
  "^target.*"
  "^dev.*"
  "^resources.*"
  "^test.*"
  "\/home\/thierry\/Documents\/\.docs-code.*"
  "\/home\/loud\/Development\/\.docs-code.*"]

pez 2025-03-24T08:09:55.267729Z

Yeah, so even if the repl window should be handled by clojure-lsp you seem to exclude it there.

Thierry 2025-03-24T08:10:05.889129Z

yes

Thierry 2025-03-24T08:10:18.053039Z

I can copy the logging output to the repl and see what happesn, hold on

pez 2025-03-24T08:10:52.458539Z

If you can share output with me in DM, I can try isolate.

Thierry 2025-03-24T08:11:02.641389Z

nothing happens, no dissapearing stuff

Thierry 2025-03-24T08:11:04.068749Z

sure

pez 2025-03-24T08:11:26.011389Z

It needs to be when there is dissapearing stuff for you. 😃

pez 2025-03-24T08:12:36.376619Z

Could of course be tricky to copy invisible text, but it could work with select-all, then copy.

Thierry 2025-03-24T08:14:07.426779Z

lol, now its not dissappearing. need to restart vscode

pez 2025-03-24T08:15:02.385809Z

Worst kind of bug!

Thierry 2025-03-24T08:16:13.608719Z

Set my replwindow settings back to repl output but no dissapearing stuff

Thierry 2025-03-24T08:16:14.359969Z

argh

Thierry 2025-03-24T08:19:52.843549Z

okay, what I will do is copy my repl window output when the text dissappears and send it to you in a dm

Thierry 2025-03-24T08:25:18.849579Z

right

Thierry 2025-03-24T08:25:21.388149Z

it broke lol

Thierry 2025-03-24T08:25:27.441319Z

going to save the file

pez 2025-03-24T08:25:28.400659Z

Awesome. 😃

Thierry 2025-03-24T08:25:31.472759Z

and copy the contents

Thierry 2025-03-24T08:39:04.926659Z

Is there a command to specifically send something to the repl window when every output is set to terminal?

pez 2025-03-24T08:39:06.490889Z

I can repro with that text. Haven’t isolated yet, but these obervations: • It doesn’t happen if I open the file while it is outside the project. • It happens immediately if I paste it in the Calva REPL Window • It happens only with clojure-lsp active. (If I stop clojure-lsp the file immediately renders again).

Thierry 2025-03-24T08:39:35.254439Z

good to hear you can repro it atleastr

pez 2025-03-24T08:43:53.413179Z

I can’t reliably repro, though. So it will take a little while to minimize. 😃

Thierry 2025-03-24T08:47:48.736959Z

Right, now it also happened with everything set to terminal and aftger I pasted a copied inspector item to the repl window

Thierry 2025-03-24T08:47:53.318049Z

i will send it to you in DM

🙏 1
pez 2025-03-20T22:09:29.456799Z

Dear Calva friends: https://github.com/BetterThanTomorrow/calva/releases/tag/v2.0.494 • Fix: https://github.com/BetterThanTomorrow/calva/issues/2759 I hope this should restore the way auto-connect sequences without projectRootPath worked before. @seancorfield Can you confirm that your sequences as they were before you added projectRootPath to them work as before?

seancorfield 2025-03-20T22:30:10.004199Z

Yup, I removed the projectRootPath setting, confirmed it was broken in my current Calva, updated Calva and reloaded the window and it auto-connected without error. Tried several other scenarios with the new Calva version and they all seemed to work.

seancorfield 2025-03-20T22:30:24.787219Z

So is ["."] the default now for projectRootPath?

pez 2025-03-21T07:09:39.526269Z

Thanks! 🙏 I also tried combos I could think of, but it is an explosion.

pez 2025-03-21T07:12:18.536409Z

At first I thought I should fix it with a default. Then I realized we actually need to restore the old behavior, which is to prompt for the project root when it is not specified, and there is more than one candidate.

👍🏻 1
seancorfield 2025-03-21T16:42:06.496249Z

Ah, that makes sense. It's why I have it in the auto-jack-in config (but not in the auto-connect config) as I recall!