I am hereby making April 17 Calva’s official birthday. 😃 https://www.linkedin.com/posts/cospaia_my-wife-asked-me-about-when-calva-celebrates-activity-7318543796214939648-4MuS 🎉
When i try to run tests in the repl, it does this
clj꞉dte.repl꞉>
; Running test: timesales-cache-insertion-test…
; Running test: timesales-cache-insertion-test…
; Running test: timesales-cache-insertion-test…
; Running test: timesales-cache-insertion-test…
; Running test: timesales-cache-insertion-test…
; Running test: timesales-cache-insertion-test…
; Running test: timesales-cache-insertion-test…
I was in a test and used the keybinding to run that test. In other words, I tried 7 times and it never actually runs the test.Have you loaded the namespace?
Also, long shot. Is the output maybe printed to some other destination? like the terminal output is what I generally recommend.
While asking Grok to explain MCP for me it told me there already is a Calva MCP server. Turns out that MCP.so has found indexed the repo. 😃 https://mcp.so/?q=calva
I loaded the namespace. And that doesn't seem to be it, and don't see any terminal output. Are the tests meant to run in the REPL or command line tests ?
Calva is supposed to run your tests and show you the results, and update problems list and such. What’s your output destinations setting?
the repl
"calva.outputDestinations": { "evalResults": "repl-window", "evalOutput": "repl-window", "otherOutput": "repl-window" }
OK. FYI (unrelated to the problem at hand) I recommend to use "terminal" as the output instead. The repl-window is a bit unstable.
cool thanks
I’m still figuring on why the tests are not run. (Or at least why we don’t see anything about it.) I do recognize the screenshot, but can’t recall what it was about right now.
terminal for all 3 outputs ?
when i try the terminal for all 3, i see
To reveal this terminal, use the command Calva: Show/Open the Calva Output Terminal .
See also the Calva Inspector:
Running test: calculate-ema-test…
TypeError: Cannot read properties of undefined (reading 'results') Yes, I use terminal for all three. Ah, so there’s something going wrong that we now get informed about at least. There’s a command for enabling nrepl message logging. Maybe we can see something there that gives us an idea.
1744910167382 ->| not sent! (not supported by the server)
{
op: 'test-var-query',
id: '16',
session: 'd3bc65d5-872d-42c3-80b0-3c9d363b8031',
'var-query': {
'ns-query': { exactly: [Array] },
search: 'calculate-ema-test',
'test?': true
}
}this is odd
1744910229325
looks like a datomic id and i am using datomicIt’s a timestamp, iirc
Maybe cider-nrepl middleware is lacking. Based on the message.
ooh thank you!!!
sweet... Thank you so much for your help!
Please file an issue about it. Calva should inform you about this instead of just silently lying about that it is running the tests.
will do. Wow this is so much better than emacs. I used to comment out all my tests in the test file and re-evaluate the file with a (run-tests) at the bottom to focus on just one test 🙂
Im sure it was possible with emacs to do test focus, just never had a UI to set the key bindings so easily.
It’s CIDER infrastructure we are using, so no doubt it’s there. But VS Code does have a sweet UI for keybindings. Levering the power of search, as a lot of other things in VS Code.
Also I wanted to say, I'm super pumped on using this https://github.com/PEZ/calva-mcp-server
My MCP server / Claude deleted my bash profile and my macbook's keychain file and i lost a day thinking i'd been hacked.
i literally think Calva + MCP will be like the singularity event in my coding lol
Haha, how did you find it?
I tried to vibe code it at first and now I have a bloody mess to clean up. But I am getting there, slowly.
I googled it, I'm your lone star
first result. Calva MCP server https://github.com/PEZ/calva-mcp-server
I refresh this every day like a kid waiting for christmas https://marketplace.visualstudio.com/items?itemName=betterthantomorrow.calva-mcp-server
Haha. Interesting that you were looking for it. So means I am not the only one who thinks it could be useful. PMF!
I think it could become the most powerful gen-ai tool and everyone will wish they knew clojure
We dream alike!
the feedback loop will be insane
I think so too. Looking forward to record some demos!
I really am addicted to my key bindings in emacs but I am weaning myself off bc the potential in VS code.
With some luck I am only a few days from being able to package a that can do something.
Er - what if it suggests (clojure.java.shell/sh "rm -rf") and tries it out to make sure of the syntax
Then you are toast!
YOLO and all that.
Actually, I don’t know what to do about that. This can happen without a REPL though, since the agents execute shell code.