jsonschema-rs icon indicating copy to clipboard operation
jsonschema-rs copied to clipboard

`ValidationError` Fns are mostly pub(crate)

Open jqnatividad opened this issue 1 year ago • 1 comments

which prevents me from using them apart from ValidationError::custom() when trying to make custom validators.

jqnatividad avatar Jun 18 '24 22:06 jqnatividad

Oh, my thinking was that the only public-facing function would be custom, but it indeed looks more flexible to have more constructors public. Could you, please, share your use case?

Stranger6667 avatar Jul 14 '24 18:07 Stranger6667

Never mind @Stranger6667 . It turns out I only needed custom.

Check out the new dynenum custom keyword in qsv! 😄

https://github.com/jqnatividad/qsv/commit/cd4ec1264db895414f5da3abf26d807079eb2c2b

jqnatividad avatar Sep 23 '24 12:09 jqnatividad

Thank you for sharing! :) Really cool!

Somewhere in October/November I plan to rework the error handling so it is possible to do more customization with the error messages and I'll surely take a look back and try to improve the ergonomics

Stranger6667 avatar Sep 23 '24 12:09 Stranger6667