This page is not created by, affiliated with, or supported by Slack Technologies, Inc.
2020-05-15
Channels
- # announcements (2)
- # babashka (137)
- # beginners (96)
- # calva (3)
- # cider (11)
- # clj-kondo (8)
- # cljs-dev (161)
- # cljsrn (21)
- # clojure (78)
- # clojure-europe (47)
- # clojure-france (1)
- # clojure-losangeles (1)
- # clojure-nl (4)
- # clojure-spec (24)
- # clojure-uk (9)
- # clojuredesign-podcast (4)
- # clojurescript (39)
- # conjure (2)
- # core-async (27)
- # cursive (36)
- # datomic (54)
- # emacs (6)
- # figwheel (9)
- # figwheel-main (46)
- # fulcro (25)
- # graalvm (8)
- # helix (30)
- # hoplon (6)
- # hugsql (3)
- # jobs (5)
- # leiningen (7)
- # luminus (12)
- # nrepl (20)
- # off-topic (20)
- # pedestal (16)
- # re-frame (14)
- # reagent (3)
- # reitit (3)
- # remote-jobs (5)
- # rum (25)
- # shadow-cljs (60)
- # spacemacs (10)
- # vim (2)
- # xtdb (36)
I have a project where all the namespaces are loaded on REPL start and it’s getting quite long, to the point of REPL client in IntelliJ giving up saying it didn’t receive a nREPL ack. Is there a way to make that timer longer?
Yes, Preferences | Languages & Frameworks | Clojure | REPL options | REPL startup timeout
@cfleming Is Cursive able to warn on duplicate values in set literal?
Yes, it’s possible, at least for statically visible cases (i.e. not #{1 2 (+ 1 1) 3}
), the same for map keys.
The error when executing the code is pretty immediate and obvious so I’ve never got around to it, but it should be a warning, yes.
I'll create a feature request issue for that on GitHub
for example #{1 2 4 4}
The other one that would be nice, and in that same realm, is duplicate map keys.
{::a 1
::a 2}
These are caught almost instantly when you actually read load the file in the repl. Still nice to have that static feedback for the times when you don't have a repl open.@cfleming I updated to the latest Cursive release. I think there's a memory leak. IntelliJ will soar up to 8gb of memory after 30 mins or so.
I started the IDE, updated Cursive, wrote 1 line of code and have been reading since then. Went back to IntelliJ and the IDE shows a "Low Memory" message and is using 8.9gb of memory, as per system monitor. IntelliJ's memory bar shows less but guessing it's missing something.
I just updated too, right after I read your post, and I’m not seeing any unusually memory consumption. MacOS Mojave, IntelliJ IDEA 2020.1. FWIW.
It might =)… I have a few memory issues where the ram consumption grows slowly and Colin was interested in the dumps, so might be worth holding onto them until he says otherwise?
@U083D6HK9 Yes, please click that link and send the result to me - it’ll produce a text report.
Hi, I'm trying to do simple addition at the REPL using (+ 40 3) and I keep on getting a syntax error that's pointing me to a file called form-init18086366295139673654.clj in my Local/Temp directory. Kind of confused on what I should do here to fix this
I think you're seeing some stuff that wraps expressions before evaluating them
can't say I know how to fix it though
i can recreate that somewhat if i try to evaluate a form in a bad ns
Clojure 1.10.1
user=> (in-ns 'namespace)
#object[clojure.lang.Namespace 0x6aa3a905 "namespace"]
namespace=> (+ 1 1)
Syntax error compiling at (REPL:1:1).
Unable to resolve symbol: + in this context
namespace=>
i don't have cursive on this computer but that is one way to get syntax errors on otherwise correct forms
command shift-N sets the repl namespace and perhaps this was done before loading/requiring?
I was changing the namespace to where the addition was located for some reason. I have another question. When I have a namespace that contains my code, do I have to highlight it to send the code the the REPL or is there an easier way to run my code without having to do this everytime
no, there are key bindings to send the expression prior to the cursor or the top level expression you're in
Ok thank you that helps a lot more
"Send form before caret to REPL" or "Send top form to REPL"
Carrying on the "wouldn't it be nice" theme from earlier today: I'd like in-editor feedback when sending anything to the repl results in a compilation error. I often keep the repl output window hidden only opening it after send forms there as I test from comment blocks in the editor. My workflow is write code, then load files in REPL, then evaluate a comment block, then open REPL to review result. If the "load files in REPL" results in a compilation error AND the evaluate comment block is large enough to cause the compilation error to scroll off the top, I am left puzzling why my output doesn't change.
I used to do that, but have slowly switched to editing/running smaller forms with the namespace I’m working in being currently loaded in the repl =)… It’s really useful to take a form that’s in the editor, stick it in a comment block and tinker with it. I try not to have a form larger than a few lines at a time… I do agree that in editor feedback would be interesting though.
Yes, in recent versions (2019.3+) IntelliJ has much better functionality for in-editor results and feedback which I’m planning to integrate.
I thought it would be asking too much to have REPL evaluation results displayed inline in the editor 🙂
I'm un-reasonably excited about this feature 😄