This page is not created by, affiliated with, or supported by Slack Technologies, Inc.
2023-05-17
Channels
- # ai (1)
- # announcements (1)
- # aws (38)
- # babashka (25)
- # beginners (84)
- # biff (11)
- # calva (58)
- # clerk (14)
- # clj-kondo (14)
- # cljdoc (9)
- # cljs-dev (2)
- # clojars (2)
- # clojure (93)
- # clojure-czech (2)
- # clojure-dev (13)
- # clojure-europe (19)
- # clojure-nl (1)
- # clojure-spec (13)
- # clojure-uk (2)
- # clojurescript (6)
- # conjure (1)
- # core-async (9)
- # cursive (12)
- # data-science (7)
- # datahike (47)
- # datalevin (10)
- # datalog (3)
- # datomic (35)
- # emacs (3)
- # events (4)
- # fulcro (49)
- # gratitude (7)
- # humbleui (1)
- # hyperfiddle (42)
- # jobs-discuss (19)
- # kaocha (5)
- # lsp (20)
- # malli (3)
- # meander (2)
- # membrane (2)
- # off-topic (22)
- # pathom (2)
- # polylith (14)
- # practicalli (1)
- # rdf (3)
- # reitit (2)
- # shadow-cljs (11)
- # squint (3)
- # tools-deps (32)
- # vim (9)
- # xtdb (16)
Since today I can no longer Jack-In. I’ve just created a clean project (based on org.corfield.new/scratch
) with no dependencies at all. Jack-in fails with the following stacktrace (see thread). I have no clue why this issue manifested today all of a sudden. Anyone any idea?
Stacktrace:
This is a pseudo terminal, only used for hosting the Jack-in REPL process. It takes no input.
Pressing ctrl+c with this terminal focused, killing this terminal, or closing/reloading the VS Code window will all stop/kill the Jack-in REPL process.
⚡️ Starting the REPL ⚡️ using the below command line:
pushd /Users/jlmr/Code/test-calva ; clojure -Sdeps '{:deps {nrepl/nrepl {:mvn/version,"1.0.0"},cider/cider-nrepl {:mvn/version,"0.28.5"}}}' -M -m nrepl.cmdline --middleware "[cider.nrepl/cider-middleware]" ; popd
nREPL server started on port 56756 on host localhost -
ERROR: Unhandled REPL handler exception processing message {:op eval, :code *ns*, :id 1}
Syntax error macroexpanding at (cider/nrepl/inlined_deps/orchard/v0v9v2/orchard/java/parser.clj:1:1).
at clojure.lang.Compiler.load(Compiler.java:7665)
<elided>
at $eval4249$loading__6789__auto____4250.invoke(info.clj:1)
at $eval4249.invokeStatic(info.clj:1)
at $eval4249.invoke(info.clj:1)
<elided>
at clojure.lang.RestFn.invoke(RestFn.java:930)
at cider.nrepl.middleware.stacktrace$eval4241$loading__6789__auto____4242.invoke(stacktrace.clj:1)
at cider.nrepl.middleware.stacktrace$eval4241.invokeStatic(stacktrace.clj:1)
at cider.nrepl.middleware.stacktrace$eval4241.invoke(stacktrace.clj:1)
<elided>
at cider.nrepl.middleware.debug$eval4233$loading__6789__auto____4234.invoke(debug.clj:1)
at cider.nrepl.middleware.debug$eval4233.invokeStatic(debug.clj:1)
at cider.nrepl.middleware.debug$eval4233.invoke(debug.clj:1)
<elided>
at cider.nrepl$wrap_debug$fn__2388.invoke(nrepl.clj:163)
at nrepl.middleware$wrap_conj_descriptor$fn__962.invoke(middleware.clj:16)
at cider.nrepl.middleware.inspect$eval_reply.invokeStatic(inspect.clj:71)
at cider.nrepl.middleware.inspect$eval_reply.invoke(inspect.clj:69)
at cider.nrepl.middleware.inspect$handle_inspect.invokeStatic(inspect.clj:110)
at cider.nrepl.middleware.inspect$handle_inspect.invoke(inspect.clj:108)
at clojure.lang.Var.invoke(Var.java:388)
at cider.nrepl$wrap_inspect$fn__2422.invoke(nrepl.clj:227)
at nrepl.middleware$wrap_conj_descriptor$fn__962.invoke(middleware.clj:16)
at nrepl.middleware.load_file$wrap_load_file$fn__1840.invoke(load_file.clj:81)
at nrepl.middleware$wrap_conj_descriptor$fn__962.invoke(middleware.clj:16)
at cider.nrepl.middleware.track_state$handle_tracker.invokeStatic(track_state.clj:244)
at cider.nrepl.middleware.track_state$handle_tracker.invoke(track_state.clj:242)
at clojure.lang.Var.invoke(Var.java:388)
at cider.nrepl$wrap_tracker$fn__2510.invoke(nrepl.clj:482)
at nrepl.middleware$wrap_conj_descriptor$fn__962.invoke(middleware.clj:16)
at nrepl.middleware.caught$wrap_caught$fn__1231.invoke(caught.clj:97)
at nrepl.middleware$wrap_conj_descriptor$fn__962.invoke(middleware.clj:16)
at cider.nrepl$wrap_out$fn__2446.invoke(nrepl.clj:334)
at nrepl.middleware$wrap_conj_descriptor$fn__962.invoke(middleware.clj:16)
at cider.nrepl.middleware.content_type$handle_content_type.invokeStatic(content_type.clj:144)
at cider.nrepl.middleware.content_type$handle_content_type.invoke(content_type.clj:131)
at clojure.lang.Var.invoke(Var.java:388)
at cider.nrepl$wrap_content_type$fn__2346.invoke(nrepl.clj:107)
at nrepl.middleware$wrap_conj_descriptor$fn__962.invoke(middleware.clj:16)
at nrepl.middleware.print$wrap_print$fn__1198.invoke(print.clj:234)
at nrepl.middleware$wrap_conj_descriptor$fn__962.invoke(middleware.clj:16)
at nrepl.middleware.sideloader$wrap_sideloader$fn__1921.invoke(sideloader.clj:108)
at nrepl.middleware$wrap_conj_descriptor$fn__962.invoke(middleware.clj:16)
at cider.nrepl$wrap_enlighten$fn__2396.invoke(nrepl.clj:190)
at nrepl.middleware$wrap_conj_descriptor$fn__962.invoke(middleware.clj:16)
at nrepl.middleware.session$session$fn__1401.invoke(session.clj:325)
at nrepl.middleware$wrap_conj_descriptor$fn__962.invoke(middleware.clj:16)
at nrepl.server$default_handler$fn__1969.invoke(server.clj:141)
at nrepl.server$handle_STAR_.invokeStatic(server.clj:24)
at nrepl.server$handle_STAR_.invoke(server.clj:21)
at nrepl.server$handle$fn__1937.invoke(server.clj:41)
at clojure.core$binding_conveyor_fn$fn__5823.invoke(core.clj:2047)
at clojure.lang.AFn.call(AFn.java:18)
at java.base/java.util.concurrent.FutureTask.run(Unknown Source)
at java.base/java.util.concurrent.ThreadPoolExecutor.runWorker(Unknown Source)
at java.base/java.util.concurrent.ThreadPoolExecutor$Worker.run(Unknown Source)
at java.base/java.lang.Thread.run(Unknown Source)
Caused by: java.lang.ClassNotFoundException: jdk.javadoc.doclet.Doclet
at java.base/java.net.URLClassLoader.findClass(Unknown Source)
at clojure.lang.DynamicClassLoader.findClass(DynamicClassLoader.java:69)
at java.base/java.lang.ClassLoader.loadClass(Unknown Source)
at clojure.lang.DynamicClassLoader.loadClass(DynamicClassLoader.java:77)
at java.base/java.lang.ClassLoader.loadClass(Unknown Source)
at java.base/java.lang.Class.forName0(Native Method)
at java.base/java.lang.Class.forName(Unknown Source)
at clojure.lang.RT.classForName(RT.java:2209)
at clojure.lang.RT.classForNameNonLoading(RT.java:2222)
at cider.nrepl.inlined_deps.orchard.v0v9v2.orchard.java.parser$eval4444$loading__6789__auto____4445.invoke(parser.clj:1)
at cider.nrepl.inlined_deps.orchard.v0v9v2.orchard.java.parser$eval4444.invokeStatic(parser.clj:1)
at cider.nrepl.inlined_deps.orchard.v0v9v2.orchard.java.parser$eval4444.invoke(parser.clj:1)
at clojure.lang.Compiler.eval(Compiler.java:7194)
at clojure.lang.Compiler.eval(Compiler.java:7183)
at clojure.lang.Compiler.load(Compiler.java:7653)
... 188 more
I’ve elided parts of the stacktrace because Slack was complaining about the number of characters
Strange. Can you try with v2.0.358 and see if that makes a difference? We have made some changes to jack-in the last few days, and had some problems with regressions. This doesn’t look like any of that, but if it works with 358 and not in latest Calva, then it is any of that.
No, I don’t think a Calva change causes this. You haven’t changed anything with Java version?
Great, I guess from your emoji. 😃 What I do to control which environment VS Code runs with is that I start it with the code
command line, from a terminal that has the environment I need.
yes I also always start using code
I guess some recent changes in my shell config triggered this issue
Which Java version caused the problem? If we have that in this thread, people might find it in searches.
You’re welcome, @U56R03VNW!
Further investigation might be still be a good idea for you. Why is an upgrade from JRE 11 to 17 causing breakage?
Hi, folks. Thanks for this thread as it and other resources helped me resolve this issue: install a JDK (instead of a JRE) via https://asdf-vm.com/ 🙂
I started using this connect sequences by repl started in standalone terminal. To build ui we are using Figwheel, so the connect sequence has "cljsType": "Figwheel Main". When I try to reconnect to the repl, it says that "A build with id "dev" is already running". What a best approach to reconnect to figwheel?
Does it work to jack-in? Not suggesting that you do that, it’s just a test. If you test it, then only select the aliases test
, back-test
, and portal
.
connect sequence:
{
"calva.replConnectSequences": [
{
"name": "front+back",
"projectType": "deps.edn",
"projectRootPath": [
".",
"ui"
],
"cljsType": "Figwheel Main"
}
]
}
If you copy the jack-in command when using only the aliases I suggest. And run that command for starting the repl. Can you reconnect then? I somehow doubt it, but wanna check.
Without calva alias Figwheel won't start due to calva.user.clj requires figwheel.main.api
Error is: Could not locate figwheel/main/api__init.class, figwheel/main/api.clj or figwheel/main/api.cljc on classpath.
Oh, I see. If that’s the only thing happening, by all means include it. (And consider naming it fig
or somegthing 😃 )
nrepl alias:
:nrepl
{:extra-deps {cider/cider-nrepl {:mvn/version "LATEST"}
refactor-nrepl/refactor-nrepl {:mvn/version "2.5.0"}
cider/piggieback {:mvn/version "0.4.2"}}
:main-opts ["-m" "nrepl.cmdline"
"--middleware" "[cider.nrepl/cider-middleware]"
"--port" "55555"]
:jvm-opts ["-Xmx512M" "-XX:-OmitStackTraceInFastThrow"]}
Do any of the other aliases have main-opts? I think you could run in to problems with that old piggieback. But I don’t think any of this is the problem with reconnect. Just trying to exclude things here.
Do we need main-opts for developing purposes? Since Jack-In without nrepl alias works just fine.
No, you don’t need that. I was just confused why the clojure prompt appeared if you were using the command line you get from Copy Jack-in Command Line. Because that command line should not need the nrepl alias.
Well, I copied exact Jack-In command, added some envs, then my backed started.
Next I connected with Figwheel cljs type, reloaded vscode, reconnected. Reconnection happened. Still got this "A build with id "dev" is already running."
Also after reload in the repl there were Exceptions
ERROR: Unhandled REPL handler exception processing message {:op close, :session 83b85b52-2bec-49d3-814c-792a12323ec4}
java.net.SocketException: Socket closed
Ah, that was what my first question in this thread was about. 😃 If the connection happens, it doesn’t matter.
No, it is Figwheel Main. And now I recall I have asked for a better API for this, four years ago 😃 https://github.com/bhauman/figwheel-main/issues/166
Got it! Thank you! And, yeah, sometimes repl stucks in user.clj after reconnecting, like that said in the comment. So I guess we should put up with it.
Depends on if you want the panel with terminals and such on the bottom, then no. I tend to drag terminals I am interested in into the editor area and hide the panel.
To me this is a major pain. I came from using cursive and having a small repl window at the bottom means you can see the whole of the text file.
Editor panes can be tiled among themselves. And the REPL window is an editor. So you if you only have editors you can have a small repl window at the bottom. And, terminals can be tiled with editor panes. It is for some reason super restricted where you can place things in VS Code. I once asked for a change to this, but it was deemed out of scope: https://github.com/microsoft/vscode/issues/68831
It could be, but there are trade-offs that has made us choose to use a regular file for it. We have used terminals and we have used a webview. We are now considering making a write only output, but we don’t have any concrete plans for it.
I don’t know what the term is. Maybe write-only is confusing. Read-only makes sense now. 😃
I don't understand why the Panel is the way it is. Frustrating in multiple ways. I think all the things that go in the panel should be free like editors. But I wasn't consulted 😉. Anyway. You can at least move the Panel to one side to gain more vertical real estate. (Making up the name "Panel-Tabs" for the top bar of the Panel, with "tabs" of Problems, Output, Terminal, etc.)
right-click Panel-Tabs
-> click Panel Position
-> click Left <or> click Right