This page is not created by, affiliated with, or supported by Slack Technologies, Inc.
2018-02-22
Channels
- # architecture (9)
- # beginners (90)
- # cider (98)
- # cljs-dev (23)
- # cljsrn (4)
- # clojure (101)
- # clojure-brasil (3)
- # clojure-dev (48)
- # clojure-italy (15)
- # clojure-losangeles (3)
- # clojure-russia (12)
- # clojure-uk (17)
- # clojured (1)
- # clojurescript (141)
- # community-development (15)
- # core-async (1)
- # datascript (12)
- # datomic (18)
- # docker (3)
- # emacs (1)
- # events (1)
- # figwheel (1)
- # fulcro (57)
- # graphql (4)
- # javascript (9)
- # jobs (1)
- # lein-figwheel (1)
- # leiningen (1)
- # lumo (1)
- # off-topic (68)
- # om (9)
- # om-next (3)
- # onyx (4)
- # parinfer (6)
- # pedestal (14)
- # portkey (2)
- # proton (1)
- # protorepl (19)
- # re-frame (57)
- # reagent (46)
- # ring-swagger (12)
- # shadow-cljs (167)
- # slack-help (5)
- # specter (18)
- # sql (1)
- # uncomplicate (3)
- # unrepl (1)
Yeah, we should probably find some time to fix the problem with excessive output being dumped in the REPL. A relatively simply solution would be to just count the size of the output and trim it client side, but a better solution might be to enhance the eval middleware to be smarter about this.
And the previous broad discussion of how Clojure programming is different from C++ programming reminded me of an old idea we had to add some indicator whether a ns is loaded/in sync with the source buffer and maybe leverage this in commands like find-var
.
I don’t know how many of you have noticed it, but once you evaluate an expression a small indicator appears next to it and and it disappears if you change the expression.
Is there some way to use *cider-scratch*
as it’s own namespace so I can import a bunch of packages into it? At the moment I’m doing something horrific like (def thing (require 'a.b.c.d.e.thing))
😕
the problem i’m trying to solve is referencing a lot of various namespaces by a short name (aka, what (ns ..)
does) in the scratch buffer
Cider debugger is awesome. thats all i got
is cider trace any different then what sayid does?
@iwannaseethelight can you not just (do (require 'ns1 :as alias1) ...)
??
yeah i guess that works, just sorta clunky
on an unrelated note, I think i’ve discovered a bug of sorts
if you have some namespace like (ns a.b.c.foobar (:require [a.b.c.user :as user])
and you switch to that namespace in the repl, and then type user/
you will not get autocompletions for that namespace - it seems to be related to the fact that cider
uses the user
namespace and treats it specially
super frustrating though, this big codebase I’m working on uses user
as a namespace alias in so many files 😕
Are you aware of any special handling for ns user
? That would surprise me.
maybe a conflicting namespace? Like is the project has :profiles {:dev {:source-paths ["dev"]}}
and a dev/user.clj
which would conflict with [a.b.c.user :as user]
?
oh, right. user
gets clojure.core
for doc
and so forth…
sorry, that’s not a reply to you, just me remembering.
(defn resolve-namespace
"Tries to resolve a namespace from the given symbol, either from a
fully qualified name or an alias in the given namespace."
[sym ns]
(or (find-ns sym) ((ns-aliases ns) sym)))
and this is actually a really bad thing. if an alias is the same as a single segment namespace you'll get backwards results
yeah i wondered if there was a ticket for this already 🙂
the gist is that it's trying to find out what namespace user
is pointing to. and to do that it needs to see if there is an alias first, because it just so happens that user
will refer to the special namespace so (find-ns user)
returns that one
Nice dig!
It’s useful for quickly debugging recursive functions without having to step through them. At least this is the primary way in which I’m using tracing myself.
Ha, I had never heard of it, but it looks like a cool project. It even has CIDER integration.
The tracing in CIDER is just a very thin wrapper over tools.trace
, which is useful, but definitely not fancy.
could we hook up this slack to the CIDER and CIDER-nrepl github projects so that issues and PR's show up here? would that be a welcome feature so that people could see the activity as it happens? or is it better for people to optionally subscribe to that as they like
I'm not sure there's a lot of value for most people in this room. But maybe it would encourage more people to get involved.
My energy levels in my spare time has been pretty low lately, not enough to muster up contributions, so I'd welcome others to come fill those gaps 😁
i'm busy with school and work so i have way less time to contribute. so i just follow along. i couldn't sleep last night so i did that at midnight instead of sleep
I couldn't think of a way to describe it that's healthy. So it's just strikethrough.
@gonewest818 your code coverage changes and general infrastructure improvements are super nice!
thanks!
Well, if someone knows what has to be done here to show those notifications - I can certainly do it.
i guess we would run github in unauthed mode: https://get.slack.help/hc/en-us/articles/232289568-GitHub-for-Slack
I’ve seen them in http://irc.gitter.im, because of their “we integrate tightly with git” thing.
☝️ right
sean mentioned that github integrations are open for anyone so we just need to do it
awesome. hopefully people click on pull requests to see how easy some changes can be.
I know that tooling code is inherently pretty ugly. But cider's is basically only "ugly" in the sense that I consider it "archaic" clojure, which makes sense given it's age.
> see how easy some changes can be Hah, funny the commit that showed up first from the github integration
@dpsutton - may bitcoin shower upon you from above, thanks for fixing that user/
completions bug, made my week
for sure. have you received the fix? i'm not sure but cider-nrepl may publish itself automatically after commits now. maybe try blowing away ~/.m2/repository/cider
and seeing if you get the new version
i tested that it worked for me. but i can't imagine the pain of a widely used namespace having no autocompletes
yeah it’s on melpa already
do you know if there’s a method in cider
to find all references to a symbol / method?
aka, find usages
just recently added helm-ag-project root. it doesn't obey the excluded dirs so had to kinda hack it
yeah i’m using that too - one thing on that is i wish the filter affected the file names
java packages are such a pita 🙂
i need to bind helm-ag-project
to a hotkey already
i also need to show the entire package name in the modeline for clojure files, i can never remember what package i’m in
@iwannaseethelight clj-refactor has a find usage function: https://github.com/clojure-emacs/clj-refactor.el/wiki/cljr-find-usages
When I write code in a file with ns foo
I like to have a (comment ...
section at the end with sexprs that I use for testing. I was wondering how I could send each sexpr to the REPL but with the namespace of the REPL, not foo
(as cider-eval-last-sexp-to-repl
does).
Right, but then I have to type <return>
in the REPL to eval it. Was hoping for something like cider-eval-last-sexp-to-repl
but using the REPL's current ns. Currently using C-c M-e
and polluting the foo
namespace in the REPL with my test vars.
(defun form-to-repl ()
(interactive)
(let ((code (cider-last-sexp)))
(with-current-buffer (cider-current-repl-buffer)
(end-of-buffer)
(insert code)
(cider-repl-return))))