Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[Question] Is there a way to generate error output? #105

Open
JeroenDeDauw opened this issue Mar 13, 2022 · 2 comments
Open

[Question] Is there a way to generate error output? #105

JeroenDeDauw opened this issue Mar 13, 2022 · 2 comments

Comments

@JeroenDeDauw
Copy link

I am aware that the ValidationResult returned by validate() can contain a ValidationError.

Does this library provide a way to turn a ValidationError into an error text that can be shown to the user? Looks like generating such a message is somewhat involved, with ValidationError containing multiple potentially relevant fields, including subErrors. So I rather not reinvent the wheel here.

For my use cases this message does not need to be fancy or particularly user friendly. Something akin to a stack trace would work great and is miles better than just dumping a serialized version of ValidationError.

@JeroenDeDauw
Copy link
Author

@sorinsarca
Copy link
Member

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants