Fork me on GitHub
#clojure-spec
<
2021-05-05
>
pinkfrog15:05:35

For a new project, use spec or spec2? If I go with spec, will it be obsoleted sometime?

dvingo19:05:26

I recently got into malli - https://github.com/metosin/malli can highly recommend if you're looking to invest in something - it's also quite simple to generate clojure.spec.alpha or clojure.alpha.spec forms from malli schemas if you ever do want to switch

naomarik21:05:46

I've been using malli since before it had a version and it's made my life so easy

andy.fingerhut15:05:55

It seems unlikely that spec2 will obsolete spec1 in 2021.

andy.fingerhut15:05:17

spec2 will not cause spec1 to change its behavior.

Alex Miller (Clojure team)16:05:38

spec 2 is not ready for use yet, so spec

Alex Miller (Clojure team)16:05:59

when spec 2 is ready, it will include help for migrating to it

seancorfield17:05:13

@alexmiller Since this seems to be a “Frequently Asked Question” about Spec 2, maybe you could put a big bold notice on the repo that says “EXPERIMENTAL: DO NOT USE YET!” or something? 🙂

Alex Miller (Clojure team)18:05:28

It says "This library is a work in progress provided to gather feedback during development." and there are no releases of it so....

emccue18:05:43

yeah but "v2 not ready yet" doesn't alleviate people's concerns about whether they should invest in spec 1

Alex Miller (Clojure team)18:05:22

spec 1 is a thing, feel free to use it

Alex Miller (Clojure team)18:05:15

the spec language between the two is substantially the same. part of releasing spec 2 will be providing a migration path from spec 1