This page is not created by, affiliated with, or supported by Slack Technologies, Inc.
2019-09-27
Channels
- # beginners (86)
- # calva (1)
- # cider (21)
- # clj-kondo (2)
- # clojure (31)
- # clojure-europe (3)
- # clojure-italy (7)
- # clojure-nl (7)
- # clojure-spec (15)
- # clojure-uk (70)
- # clojurescript (4)
- # clojutre (31)
- # code-reviews (6)
- # cursive (10)
- # datomic (8)
- # duct (3)
- # emacs (2)
- # fulcro (34)
- # funcool (3)
- # jackdaw (2)
- # jobs (10)
- # jvm (2)
- # kaocha (1)
- # off-topic (21)
- # pathom (11)
- # re-frame (10)
- # reagent (4)
- # schema (1)
- # shadow-cljs (72)
- # sql (1)
- # tools-deps (3)
- # vim (9)
- # xtdb (4)
What would CIDER do? (A question I often ask, when hacking on Calva). Right now I don't have Emacs handy, though, so here goes. What does CIDER do when you evaluate to comment and an error is thrown?
;; =>
is what I get 😐
When running M-x cider-pprint-eval-last-sexp-to-comment
on (throw (ex-info "foo" {}))
Yes it is… I also get the *cider-error*
buffer pop up — not sure if configuring it differently would change the behaviour though
I'm looking at how to support the Design Journal that @jr0cket mentioned in the ClojureScript podcast better. Then it makes sense to include some of the error message in the comment, me thinks.
@rickmoynihan That’s definitely a bug. 🙂 It’d be nice if you reported it. I think nothing should be printed in the comment at all in such cases and users should just get the error buffer.
> I think nothing should be printed in the comment at all in such cases and users should just get the error buffer. That's what Calva does today. 😀 But it makes a boring design journal.
I’ve got no issues with boring. Printing the condensed error message is always an option, but it seems pointless to me if you get a stacktrace buffer alongside anyways.
It is in the design journal context that I think it is not pointless: https://github.com/jr0cket/tictactoe-reagent/blob/master/src/tictactoe_reagent/core.cljs
I will sometimes copy the most interesting part of an error message to a comment under the expressions
Especially of it's a useful learning experience or a common error the team experiences
somewhat related, but I'd actually like it if there was an option to display error messages in the result overlay without popping up an error buffer
90% of the time it's a simple typo and I don't need to see the entire stacktrace and spend half a second dismissing the popup window
@qythium what you ask for is what I use clj-kondo for, it picks up typos and many other errors and warnings. It works as a backend to flycheck
Yeah, I use flycheck-clj-kondo also, but it doesn't pick up on everything (eg. "typos" where I pass arguments in the wrong order)