This page is not created by, affiliated with, or supported by Slack Technologies, Inc.
2018-09-20
Channels
- # 100-days-of-code (2)
- # aleph (53)
- # architecture (2)
- # aws (3)
- # beginners (230)
- # boot (15)
- # calva (3)
- # cider (19)
- # cljs-dev (1)
- # clojure (139)
- # clojure-conj (3)
- # clojure-italy (47)
- # clojure-nl (19)
- # clojure-spec (26)
- # clojure-uk (98)
- # clojurescript (152)
- # clojutre (4)
- # core-async (22)
- # cursive (5)
- # datomic (48)
- # emacs (11)
- # events (1)
- # figwheel-main (219)
- # fulcro (15)
- # instaparse (3)
- # jobs (4)
- # jobs-rus (1)
- # leiningen (30)
- # luminus (8)
- # off-topic (67)
- # onyx (5)
- # pedestal (16)
- # re-frame (1)
- # reagent (4)
- # reitit (31)
- # ring (8)
- # ring-swagger (3)
- # shadow-cljs (115)
- # specter (4)
- # videos (1)
- # vim (20)
- # yada (15)
I've found a lovely bug in cider-nrepl. The way that tools.nrepl compatibility interacts with lazily loaded middleware means that sometimes cider can use cider/nrepl for one namespace, and org.clojure/tools.nrepl for another.
@bozhidar A) why does the implementation look for tools.nrepl first? B) Why use find-ns
and not try-require
?
fwiw, this means that for me, cider-refresh is completely unusable unless I do a careful dance first to make sure cider loads carefully.
So the trick here is that under boot/lein, we're running inside an existing tools.nrepl, and we need to detect that. But inside clj
cider/nrepl is used via cider.main, meaning that tools.nrepl is not the context in which we're running. However, figwheel is trying to load tools.nrepl, and fails if it cannot.
Building figwheel sidecar from master works, so I guess figwheel sidecar isn't updated to support cider/nrepl. @bhauman any problem with a new snapshot from master?
There's perhaps a more underlying issue here, but excluding a tools.nrepl dependency from figwheel sidecar does the job for me. Edge is the delicate balance of Clojure anyway.
@bhauman it's on my todo list. We're reworking our build tool significantly, but we are also just kicking off a new client project.
I need to look at the API for figwheel main too. I might have some feedback from that really, so sooner is probably better with me doing that. But time is short.
@sb yes, I do this regularly. I start my app externally via lein repl, then connect to it twice. In one of the REPLs I start the ClojureScript REPL. It takes some effort, but works, and is a big improvement on many years of ClojureScript REPLs which I was never able to get to work 🙂
Thanks! I got a great tip from ‘roosta, cider-jack-in clj&cljs (in the emacs) and that is working now fine.
I wonder — am I the only one using aggressive-indent
? It causes unbearable slowdowns and sometimes weird behavior (such as emacs waiting for me to press a key until proceeding). I managed to profile one possible cause, reported and I think fixed in clojure-mode, but I'm still seeing this. Perhaps because there was no recent release of clojure-mode?