This page is not created by, affiliated with, or supported by Slack Technologies, Inc.
2021-03-19
Channels
- # announcements (52)
- # asami (83)
- # atom-editor (1)
- # babashka (143)
- # beginners (123)
- # calva (18)
- # chlorine-clover (21)
- # cider (7)
- # clj-kondo (57)
- # cljs-dev (4)
- # clojure (209)
- # clojure-boston (1)
- # clojure-europe (27)
- # clojure-germany (12)
- # clojure-italy (17)
- # clojure-nl (3)
- # clojure-serbia (6)
- # clojure-spec (1)
- # clojure-uk (59)
- # clojurescript (82)
- # conjure (9)
- # core-async (6)
- # cursive (20)
- # data-science (1)
- # datahike (1)
- # datascript (1)
- # datomic (86)
- # duct (5)
- # emacs (6)
- # events (6)
- # figwheel-main (4)
- # fulcro (27)
- # graalvm (19)
- # leiningen (14)
- # lsp (30)
- # malli (48)
- # meander (3)
- # off-topic (6)
- # pedestal (2)
- # practicalli (1)
- # rewrite-clj (21)
- # shadow-cljs (18)
- # sql (15)
- # tools-deps (9)
- # vim (3)
- # wasm (3)
- # xtdb (18)
Dear friends of Calva. Please consider subscribing to the CalvaTV channel on YouTube, and also like and comment a bit on the material. Hopefully that can make it a bit more visible there. https://www.youtube.com/calvatv (Of course, please tweet and such about the material as well. 😍 )
I need help. I’ve been using Calva for a while, and I’m wondering if something is out of date or some dependency mismatch. Whenever I open or create a new project, I try to Jack-in and get this error:
clojure -Sdeps '{:deps {nrepl/nrepl {:mvn/version,"0.8.3"},cider/cider-nrepl {:mvn/version,"0.25.8"}}}' -A:test
/bin/sh: clojure: command not found
Jack-in process exited. Status: 127
I’m on mac, Big Sur, both Calva and VS Code are up to date (I’m pretty sure). What am I doing wrong? To fix this I have to quit VS Code and re-open my project, and that usually works, but sometimes not, and I can’t seem to have two projects going at the same time.
I am still learning the Slack editor and how to hit return to add lines instead of submit the message. I think I got it.
I think you are running into the common problem that VS Code is not started with an environment that has the Clojure stuff available. Try starting VS Code from a terminal where you know you have clojure
on the path.
okay, that definitely worked. I had made myself an automator script so that I could right-click on a folder and open it in VS Code, and then sort of forgot that I had created that helper tool. I bet there is something with that tool that is not picking up the path/environment correctly. I’ll go investigate. Thanks for the help.
Question: When I’m in a “problem” project, and jack-in is saying it can’t find clojure
command, I can still open a terminal (in the project), start nrepl (using the same options that jack-in would use, copied directly from the error message above, for example) and then use Calva’s ‘connect to running REPL server in the project’ and that works okay. I don’t understand enough to know why of these two terminals within the VS Code project, one of them can’t find the clojure
command and let me jack in, but the other will let me manually start repl. Do you know what is going on? It’s probably a VS Code thing more than a Calva thing?
Not sure actually. At first I thought it was the same problem I have, that VS Code, when started from the MacOS Finder does not get the right environment. But now you tell me that from a terminal in the project the command works. Is that from a terminal, in the project, in VS Code? Or is it from a terminal outside VS Code?
On my last comment, I was talking about terminals within the project itself. VS Code built-in terminals.
The Terminal opened inside VS Code is going to start up using your regular .profile
and other dot-files, so the path will be correct, and clojure
will be accessible.
macOS has always been a bit of a pain in regards to processes started from the Finder.
I always start VS Code from the Terminal via the code
command to avoid any of that…
Sean, I attended the Provo meetup a few months ago and remember your terminal use was a bit out of control. Don’t know how you keep track of it all…
I also always start VS Code from the terminal. I think it is super strange that you can use the jack-in command from a VS Code terminal but that jack-in fails with that message. I have never seen that before. Jack-in shares the environment with VS Code, as I was sure the VS Code terminals also did.