This page is not created by, affiliated with, or supported by Slack Technologies, Inc.
2022-01-03
Channels
- # aleph (2)
- # announcements (13)
- # babashka (7)
- # beginners (36)
- # calva (26)
- # cider (11)
- # circleci (13)
- # clj-kondo (15)
- # clojure (105)
- # clojure-europe (79)
- # clojure-nl (3)
- # clojure-uk (6)
- # clojurescript (17)
- # conjure (4)
- # core-logic (2)
- # cursive (10)
- # data-science (5)
- # datalevin (11)
- # datalog (14)
- # eastwood (6)
- # emacs (2)
- # figwheel-main (1)
- # fulcro (34)
- # google-cloud (1)
- # graphql (3)
- # introduce-yourself (7)
- # jobs (1)
- # leiningen (17)
- # lsp (46)
- # malli (2)
- # minecraft (3)
- # missionary (19)
- # off-topic (31)
- # other-languages (49)
- # polylith (2)
- # portal (5)
- # practicalli (1)
- # quil (77)
- # releases (1)
- # remote-jobs (1)
Hello, friends! I’m cross-posting https://clojurians.slack.com/archives/C0FM7N1SM/p1641201738016900, in hopes that someone here might now whether it’s possible to set up a smoother dynamic workflow for Quil via VS Code and Calva. It would be super awesome if it’s possible to render the output in a new tab within VS Code as well, but I’m not sure whether it’s possible to “embed” OpenGL in VS Code like that.
Hello all. Just wanted to notify that calva.jackInEnv
setting is not working in the latest version 2.0.232
. I just tested it by upgrading the extension. Had to downgrade to version 2.0.231
to get it to work. I don't know if it's just on my system though.
Thanks for the heads-up! Can you file an issue about it? Preferrably from VS Code’s Help-menu, so that we get some system info from your machine with it.
@U0ETXRFEW I did some investigation and it turns out I was mistaken, the env vars do work. But the problem is with deps.edn
projects. I have a main (mono) repo where all the deps and their versions are defined (in a particular profile called deps
). I also add that profile as an alias in the calva.myCljAliases
setting. Then I refer them in my sub-projects using :mvn/version "_"
. But when I start my REPL by jacking in
, that _
is not overridden to the version defined in the alias
in the deps.edn
file of the project path specified by the CLJ_CONFIG
env var.
Now I don't know where the problem is; in the alias setting or with calva+deps.edn project.
Could you help me a little investigating this further?
Profile is an alias
and the "_"
for versions are resolved based on deps defined in the alias
. More info here https://clojure.org/reference/deps_and_cli#_deps_edn_sources
Sorry, _
is just like a placeholder, which will be overridden with version defined inside the deps.edn
(which will be contained in the project path specified by CLJ_CONFIG
env var), in it's alias
(which we are using to start the repl, while jacking in). So you could have anything in there as it'll be overridden.
@U5BRU7X8Q FYI: You probably want to avoid an alias called :deps
since that's a standard alias defined in the root deps.edn
file (to bring in tools.deps.alpha
).
Are you use :override-deps
here? When we used to do that, we typically had {}
for the coordinate -- we didn't even specify :mvn/version
at all (since the overriding deps could be local or git deps). We gave up on that approach tho' and we stopped using CLJ_CONFIG
too (because it prevents developers having their own additional dev-only aliases).
I don't know if you've seen my series of blog posts about our monorepo at World Singles Networks but I talk a lot in the early posts in that series about the various setups we tried and abandoned (and why).
@U04V70XH6 Thanks a lot for the pointers! I'll read your blogs :thumbsup:
@U0ETXRFEW Same issue with v2.0.233
as well.
@U5BRU7X8Q can you make a small repro project exposing this?
@U0ETXRFEW Sure I can, please see the attached zip file. It contains a deps.edn
file in the root-project
folder, where all my deps are defined under the alias deps-override
. Inside the folder there is a small project under sub-projects/hello-world
which has it's own deps.edn
file but I am using an underscore (`_`) as a placeholder to be replaced by the one defined in the root project folder.
Now if you try to spin up a REPL using jack-in and select the deps-override
profile (as it's defined in root-project/.vscode/settings.json
), you'll be able to start it if you are on the version 2.0.231
of calva
.
But if you try to start it with 2.0.232
or 2.0.233
, you'll see the error:
clojure -Sdeps '{:deps {nrepl/nrepl {:mvn/version,"0.9.0"},cider/cider-nrepl {:mvn/version,"0.27.4"}}}' -M:deps-override -m nrepl.cmdline --middleware "[cider.nrepl/cider-middleware]"
Error building classpath. Could not find artifact org.clojure:clojure:jar:_ in central ( )
Jack-in process exited. Status: 1
NOTE: I have added .vscode/settings.json
file in multiple places (one in root and another in one of the sub projects) for your convenience. But please make sure you change the path value for CLJ_CONFIG
env var in those files according to you. It should be equal to where you extract the project folder, like, <extracted-path>/root-project
.I’ll don’t have time to test this until tonight. But looking at the changelog for 232, I am suspecting this change: https://github.com/BetterThanTomorrow/calva/pull/1417
So if you use the Copy Jack-in command line (or something, I don’t recall the exact command name) to copy the command line and change -M to -A, does the command then work? (If so you can then use the Connect command to connect the REPL, until we have figured out what the fix for the issue is.)
@U0ETXRFEW Yes, you are right. If I change the command from -M
to -A
, it works.
If -A
works and -M
does not, I think you are running an old Clojure CLI and need to upgrade @U5BRU7X8Q -- run clojure -version
and check that against https://clojure.org/releases/tools (if clojure -version
doesn't work you have a very old version)
@U0ETXRFEW @U04V70XH6 clojure -version
didn't work as I had 1.10.1
version. I upgraded it and now my deps.edn project works with the latest calva.
Thanks for all the help guys! 🙏
I like to use brew
(even on Linux) to help keep my clojure/tools/clojure
CLI up-to-date. Something to consider.
Hi, does Calva support sideloading? https://nrepl.org/nrepl/0.9/design/middleware.html#sideloading