Fork me on GitHub
#malli
<
2024-01-10
>
dave21:01:36

hi there, i just upgraded from 0.8.9 to the latest for malli and now i am getting this error. is there a way i can find out what schema it is having the exception about?

ikitommi18:01:38

hi @UB9H5TE2X. You can ask (ex-data *e) to get more details. There should not be breaking changes in the schema syntax, but I think :or requires now at least one child:

(m/schema [:or])
; =throws=> :malli.core/child-error
(ex-data *e)
; {:type :malli.core/child-error,
;  :message :malli.core/child-error,
;  :data {:type :or, :properties nil, :children nil, :min 1, :max nil}}

ikitommi18:01:50

with upcoming 0.14.0, you get much better errors thanks to new dev-mode: