This page is not created by, affiliated with, or supported by Slack Technologies, Inc.
2020-02-24
Channels
- # announcements (5)
- # aws (24)
- # babashka (41)
- # beginners (130)
- # bristol-clojurians (2)
- # calva (39)
- # chlorine-clover (64)
- # cider (30)
- # clojure (202)
- # clojure-belgium (1)
- # clojure-dev (99)
- # clojure-europe (5)
- # clojure-hungary (4)
- # clojure-italy (10)
- # clojure-losangeles (8)
- # clojure-nl (11)
- # clojure-norway (6)
- # clojure-spec (7)
- # clojure-uk (12)
- # clojurescript (52)
- # core-typed (26)
- # cursive (19)
- # data-science (19)
- # datomic (19)
- # duct (10)
- # emacs (17)
- # fulcro (22)
- # graalvm (11)
- # jobs (3)
- # kaocha (28)
- # leiningen (6)
- # lumo (2)
- # malli (10)
- # nrepl (2)
- # off-topic (23)
- # pathom (2)
- # pedestal (7)
- # re-frame (3)
- # reagent (30)
- # reitit (2)
- # remote-jobs (2)
- # shadow-cljs (77)
- # sql (10)
- # test-check (22)
- # tools-deps (37)
- # vscode (1)
- # yada (3)
is there a way to have cursive sort all the map keys in an edn file alphabetically?
It would be a neat feature because when editing large edn files it can be easier to find things if they are sorted alphabetically. I know it doesn’t impact the actual generated datastructure.
maps are unordered, so don't expect that doing so will have any impact on what happens when you read/compare.
if you throw it's contents into a treemap then this one is sorted
but it's a bad idea to build things based on sorted maps, i have only used it for comparison of deep json trees in tests
I have a suspicion that the reason in this case is code style/ease of reading/nicer diffs
Cursive seems to get confused by an exception I'm throwing
Error printing return value (ExceptionInfo) at compute.data-model.spec-helpers/add2 (spec_helpers.cljc:240).
asd
Expanding the stacktrace shows:
clojure.lang.ExceptionInfo: null #:clojure.error{:phase :print-eval-result}
at clojure.main$repl$read_eval_print__9086.invoke(main.clj:442)
clojure.lang.ExceptionInfo: compute.data-model.spec-helpers/add2 threw an exception. {:sym compute.data-model.spec-helpers/add2, :spec #object[clojure.spec.alpha$fspec_impl$reify__2524 0x73f4d05a "clojure.spec.alpha$fspec_impl$reify__2524@73f4d05a"]}
at compute.data_model.spec_helpers$cleanup_check_result.invokeStatic(spec_helpers.cljc:224)
clojure.lang.ExceptionInfo: asd {}
The problems I was having with slowness/unresponsiveness in recent versions of IntelliJ are a little better after increasing the heap size. I got a low memory warning. The slowness was discussed in an earlier thread here that's now gone. I do have a lot of workspaces open at a time, but it's also possible that recent versions are using more memory. FWIW you can increase heap size with the Heap->Change Memory Settings menu item.
When switching to a particular branch, the entire IntelliJ UI freezes. It appears to have something to do with reading projects.
Why does switching branches require Cursive to re-read all the projects? It seems like it should have cached that from the last time I switched to a branch.