Fork me on GitHub
#clojure-spec
<
2017-07-13
>
bbrinck00:07:43

Several people on this channel have asked about pretty-printing spec failures. I’ve just released Expound, a library that formats clojure.spec errors https://github.com/bhb/expound

richiardiandrea07:07:53

bbrinck: great great great thanks!

bbrinck00:07:05

I’ve got a lot more features planned, but hopefully this first release is useful to people on this channel

bbrinck00:07:34

cc @samueldev (who also asked about this awhile back)

samueldev01:07:32

Awesome @bbrinck I'm going to try this out tomorrow morning!

naomarik06:07:07

How can I constrain a multispec to a specific key? With the event example in spec guide I’ve tried this: (gen/sample (s/gen :event/event {:event/type #(s/gen #{:event/search})})) which doesn’t work

naomarik06:07:00

Solved it using gen/fmap to constrain the type, wondering if more succinct solution is available though.

rickmoynihan10:07:29

@bbrinck: awesome!! I’ve been wanting something like this for a long time… Another thing that might be useful is integrating this into prone for rendering spec errors in stack traces over http (in dev): https://github.com/magnars/prone

bbrinck12:07:15

Good idea!