This page is not created by, affiliated with, or supported by Slack Technologies, Inc.
2021-12-28
Channels
- # announcements (13)
- # babashka (7)
- # beginners (35)
- # calva (23)
- # chlorine-clover (6)
- # cider (12)
- # clj-kondo (6)
- # clojure (31)
- # clojure-dev (20)
- # clojure-europe (4)
- # clojure-norway (4)
- # clojure-uk (1)
- # clojurescript (62)
- # fulcro (6)
- # google-cloud (1)
- # lsp (2)
- # malli (13)
- # meander (6)
- # music (1)
- # off-topic (19)
- # practicalli (2)
- # re-frame (7)
- # reagent (25)
- # reitit (5)
- # releases (1)
- # reveal (3)
- # shadow-cljs (90)
- # tools-build (18)
- # tools-deps (1)
Hello, I don´t know what is happenig, but the tests is including some spaces to the result, like
; Evaluating file: adapters_test.clj
#'unit.microservice-boilerplate.adapters-test/->wallet-history-test
; Running tests for unit.microservice-boilerplate.adapters-test...
; 5 tests finished, all passing 👍, ns: 1, vars: 5
Can you log a bug on GitHub and tag me in it please?
I think I know what's up here.
How can I install an unoptimized build calva? I can periodically reproduce the following bug https://github.com/BetterThanTomorrow/calva/issues/1189 and I see fsPath error in debug window but the symbols have been “optimized” so its hard to determine the callstack. I tried to follow https://github.com/BetterThanTomorrow/calva/wiki/How-to-Hack-on-Calva but and I can open and build the project but its not clear to me if VSCode is actually using the local clone of the extension in this or other vscode instances… I’m guessing not as simply opening and building the project did not seem to give me more info. I then tried to follow instructions to create a visx package and tweaked replaced shadow-cljs release with compile in the release-cljs script hoping the resulting package would be unoptimized but instead I just get “mainThreadExtensionService.ts:95 Activating extension ‘betterthantomorrow.calva’ failed: ENOENT: no such file or directory, open ‘/Users/kurt.harriger/.vscode/extensions/.shadow-cljs/builds/calva-lib/dev/out/cljs-runtime/goog.debug.error.js’.” trying to use the invoke commands after installing this custom package
so I recompiled the visx with --debug added to release-cljs step instead of changing compile to release… I now see an extension.js.map file in the out/extensions folder (if it wasn’t there before I’m not certain) so maybe next time I get the issue I’ll have a file and line number 🤞
Running a Calva development build will run a dev compiled calva-lib. No optimizations/minifications.
ah I see if I run the calva build it opens a new instance of visual studio…. Unfortunately the new instance does not immediately encounter the problem
hmm I also wonder if advanced optimizations might even be the reason this occurs… perhaps fsPath is getting renamed as part of optimizations
although I don’t see fsPaht in the cljs-lib.. I assumed the optimized names were from clojure compile but maybe its a wepback optimization as well
anyway I’ll try to do development in the new vs instance to see if I hit the error again at some point while running the dev build
Hmm I’m I still see mangled names… I disable the calva extension in vscode then launched and ran calva project to open a new vscode with calva active. I then tried to start a repl with in the cavla project of the new instance and I see an error in getTokenCursor displayed (Ive seen this error before but it is unrelated to the fsPath error doesn’t seem to cause any issues) and the stack trace seems to have optimized names…
although now that I think about I may need to do a clean rebuild from vscode before running as I last build a visx module from commandline it might be picking up those artifacts
oh that was it… progress now seeing proper stack trace… here is the stack trace for the getTokenCursor error
Interesting I found that if I cleaned my project folder such that it deleted calva and .lsp folders I was able to sorta reproduce the symptoms of the issue… the “Happy coding” message but no prompt…
I think this is because Clojure LSP is still initializing and as shown by the spinner next to my name in status bar
I also got an error replace on undefined which I’ve also seen occasionally
I’m curious if I’ll eventually get a repl prompt when LSP is ready but it seems to take awhile
hmm maybe not closing and reopening the project the initializing Clojure language features is spinning but I’m able to start a repl without issue
I reloaded the window as I started seeing some parse namespace errors in console issues that I realized were same cause as the getTokenCursor on undefined and then noticed the fsPath error, in this case I had not yet attempted to connect the repl
okay it seems I cannot start a repl not entirely sure exactly how to reproduce but here is screenshot with repl listening no repl prompt and error in console
updated the issue with some screenshots from above
Thanks for updating the issue. Just FYI, clojure-lsp does not do anything related to the REPL connection, so I don’t think it would cause this issue. I suppose there could possibly be some chance that an error thrown that’s related to clojure-lsp could effect the jack-in / connect process, but I doubt it.