This page is not created by, affiliated with, or supported by Slack Technologies, Inc.
- # atom-editor (5)
- # babashka (6)
- # beginners (29)
- # calva (16)
- # cider (1)
- # clj-kondo (20)
- # cljs-dev (44)
- # clojure (29)
- # clojure-europe (19)
- # clojure-nl (8)
- # clojure-norway (7)
- # clojure-spec (2)
- # clojure-sweden (1)
- # clojure-uk (56)
- # clojurescript (32)
- # code-reviews (30)
- # conjure (24)
- # crux (15)
- # cursive (49)
- # datomic (4)
- # fulcro (31)
- # helix (3)
- # instaparse (4)
- # kaocha (100)
- # lambdaisland (2)
- # mid-cities-meetup (1)
- # monads (1)
- # off-topic (42)
- # pathom (13)
- # pedestal (6)
- # portal (5)
- # re-frame (6)
- # reagent (9)
- # reitit (11)
- # remote-jobs (1)
- # rewrite-clj (11)
- # shadow-cljs (44)
- # sql (22)
- # tools-deps (13)
- # uncomplicate (1)
@smith.adriane Just checking: you did switch your credentials from username/password over to the new username/token?
I did. I just got a response in #clojars that I posted a few hours ago. The problem was the size of my jar. I guess I was too impatient when I reposted in #clojure!
imo clojure is a marxist language because it liberates you from all the superstructures of all the other programming languages lol
When there are failing tests in our CICD, it would be pretty cool if the test output could report the last people to touch the test ns in git. I was wondering if someone knew about existing functionality like this? Maybe a Clojure test lib, or some blog post discussing an implementation of what I’m thinking of?
Perhaps one could use
with-tap-output, then handle errors programmatically and have Clojure ask git who the failing ns file “owner” is, printing that along with the regular test output. It doesn’t seem straightforward 🙂
Is it a matter of redirecting stdout output somewhere else during the tests, intercept the text and do regex inspection to find the interesting bits, inject strings where appropriate and forward to stdout?
almost all clojure test runners can output results as data. which one you are using?
Thanks for the rubber ducking + statement of general fact 🙂 I didn’t know that, and knowing it gives me confidence that it makes sense to invest time pursuing the issue!
I think we might be using more than one. One subproject uses https://github.com/lambdaisland/kaocha , for example
Looking into this, it seems to me that for Kaocha I might need to inject a test report that does what I want. https://github.com/lambdaisland/kaocha/blob/master/src/kaocha/report.clj
What conventions do you use when renaming namespaces?
I typically only rename in a consistent way rather than shortening on an arbitrary name I like. For instance, it would be common to rename
algo, which I find confusing in the longer term. Instead, I would reduce the first "node" to a capital letter, it if is used frequently and well-known. If it still remains clear, I can allow myself to do the same with any subsequent "node" and append all those capital letters. For instance,
library.something.algo would preferably become
L.something.algo, and possibly
In my own application, I tend to replace "root" nodes with
$. So, if my main namespace is
, then I can rename
Seems good to me. For the last thing about shortening for your own app, I'd choose a different symbol, since that will create confusion/problems with ClojureScript (`$` may create an expectation that you are using jQuery or something).
What I do is to only have abbreviations (somewhat arbitrary ones) for 3-5 namespaces in my own app that are commonly used, and for the rest I just use the long version (no
what I attempt to do is treat aliases as canonical - so if I alias a namespace to
algo, I will use that same alias everywhere
this way I build up a short hand language in my head of what I’m talking about, so I know
algo is always
I tend to use pretty short aliases - e.g.
s - but I also prefer to never
refer so I feel like I get something back by using short aliases 😛
What I dislike about dropping "nodes" is that it is easy to loose track of where that namespace come from, especially if we end up with such a generic name as
algo. That why I keep those capital letters.
I do that only if it's really, really obvious. For instance:
glogi.console ("glogi" is already very specific and recognizable)
F.app ("F" reminds me of Fulcro and it is used very often, "com.fulcrologic" is truly unnecessary, and "application" can be somewhat exceptionally shortened to "app" because it is so guessable)
that makes sense. what I’ll do with long & generic namespaces is abbreviate it by the last two or three words - e.g.
Mandatory link :) https://stuartsierra.com/2015/05/10/clojure-namespace-aliases the other week I implemented a rewrite-clj thing that makes a given project conform with it. Works really nicely, will share in a few months when rewrite-cljc is released
Hm, is there a more idiomatic way to write
(mapv #(%1 %2) [funcs...] [vals...]) ? Just wondering.