clojure-spec

About: http://clojure.org/about/spec Guide: http://clojure.org/guides/spec API: https://clojure.github.io/spec.alpha/clojure.spec.alpha-api.html
2021-06-10T17:52:15.075700Z

hi, i have a big collection of specced data that went into mongodb and lost all the namespace info. I suppose I can transform it all by recursively using the information in (s/describe) of the top-level (big) data structure. But before doing that, I thought I'd ask if something like that already exists. Anything similar? Just to complicate it a little: there are also plenty of non-namespaced and non-specced keys that got in there as well. They shouldnt be given a namespace.

2021-06-11T14:33:02.076400Z

Thanks for you reply! Yeah, i realize that now, but the problem is that a lot of production data was stored without the namespace info before I noticed, and it's not something i can re-do. Anyway, the approach with using s/describe also doesnt work, because of things like merge etc. So guess I'll have to write custom code for the exact data structure.