Fork me on GitHub
#clojure
<
2016-02-20
>
chancerussell00:02:15

Anyone here using Prismatic Schema and Stuart Sierra's component lib/pattern together?

nullptr00:02:10

chancerussell: i have both in the mix

chancerussell01:02:13

Solved now, but I was having trouble validating schema'd records that had additional keys assoc'd on during component start

chancerussell01:02:43

Turns out you can provide a map of extra keys after the defrecord field vector

tonyvanriet04:02:02

I find myself wanting for a function that takes a collection of symbols and builds a map where the key is the symbol name and the value is the symbol value was surprised I couldn’t find one googling around. am I just missing something, or would it be problematic, or a sin for any reason?

rmuslimov06:02:21

I’m trying to find coverage report for midje? But seems like only cloverage exists which doesn’t support midje

rmuslimov06:02:15

Any recommendations?

val_waeselynck08:02:52

@tonyvanriet you dont know about symbol names at run time so that would be a macro, not a function

val_waeselynck08:02:50

(defmacro bindings-map [& syms] (reduce (fn [m sym] (assoc m `(quote ~sym) sym)) {} syms))

profil11:02:29

Hey guys. How do you use the (first (filter ...)) pattern when using transducers? I have been running (first (sequence (comp ... (take 1)) coll)), but it is kind of ugly

profil11:02:53

Is it possible to run first on eduction?

profil11:02:13

nvm, first on eduction will still run through the entire coll..

jan16:02:34

Joined because I am trying to follow the instructions in the book »Web Development with Clojure« and could not get my first tests to run.

jan16:02:01

Reason being I used TIME instead of TIMESTAMP for my timestamp SQL column...

jan16:02:41

Well, now I'm on board. How's everybody doing? simple_smile

mikeb17:02:35

@jan welcome to the community.

jan17:02:20

@mikeb: Thanks, Mike. Good morning to you! simple_smile

mikeb17:02:03

@jan, how are you finding getting started?

jan17:02:50

Pretty good. This time simple_smile. I think I tried about a year ago and did not succeed. It was the setup that killed it. Now I have lein + atom + Parinfer + Proto Repl and I can easily follow the instructions from the book using the lein luminus template. So it is really quiet fun. I think esspecially the existence of Parinfer really helps, since I am completely new to Lisp.

yogthos18:02:02

@jan glad to hear that luminus and the book are helping 😉

jan18:02:42

@yogthos: oh hey there. Absolutely, I really like how the book is not wasting any time talking about the language and a bunch of functional concepts too much, but gets me straight to learning and appreciating how to built a webapp with Clojure. For me it is like Rich Hickey's »Simple Made Easy« coming to life. I currently maintain a lot of ruby (mostly with rails) and javascript at work and we definitely feel the pains of complexity. Seeing how building a webapp can be done by simply tying together a bunch of functions really makes my heart skip a beat. In short, you had me right when you said I would have to edit a .sql file. simple_smile

yogthos19:02:53

@jan the simplicity is really what attracts me to Clojure the most, I find that you can get a lot done by applying a small number of simple concepts. This really helps me focus on the problem I'm solving instead of thinking about language quirks

yogthos19:02:41

I definitely think the best way to learn is by working through a tangible projects, and you end up learning the concepts that you need along the way

jan19:02:15

@yogthos: agreed 100%.

jan19:02:47

@yogthos: Since I have you here simple_smile Is it okay, if I push the source code I am writing while reading the book to GitHub as a public repo? Or is that a copyright violation?

yogthos19:02:42

@jan I think that should be fine, Pragmatic make the source publicly available anyways

fxposter21:02:06

Hi everyone. I have one small question regarding the reloaded workflow and component. http://thinkrelevance.com/blog/2013/06/04/clojure-workflow-reloaded mentions that “reload-on-every-request functionality of ring-devel is incompatible with tools.namespace”. Is it still the case after 2.5 years? It seems that both ns-tracker is now updated to 0.2.x tools.namespace.