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

get parsing errors details? #12

Open
mudrz opened this issue Jan 15, 2022 · 1 comment
Open

get parsing errors details? #12

mudrz opened this issue Jan 15, 2022 · 1 comment
Labels
forwarded-to-js-devs This report has been forwarded to Jane Street's internal review system.

Comments

@mudrz
Copy link

mudrz commented Jan 15, 2022

when I run dune exec ... (even with --verbose) if the json format differs from the defined type I get errors like:

!Fatal error: exception Ppx_yojson_conv_lib__Yojson_conv.Of_yojson_error(_, _)
Raised at Ppx_yojson_conv_lib__Yojson_conv.of_yojson_error in file "yojson_conv.ml", line 57, characters 34-80
Called from Dune__exe__Json.user_of_yojson.(fun).iter in file "..."

Is it possible somehow to get more details for the error, for example:

  • the name of the field that failed parsing
  • the expected type and the actual type
    ?
@github-iron github-iron added the forwarded-to-js-devs This report has been forwarded to Jane Street's internal review system. label Jan 17, 2022
@dylanirlbeck
Copy link

This would be very helpful! I'm also encountering this as I build out an API client.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
forwarded-to-js-devs This report has been forwarded to Jane Street's internal review system.
Projects
None yet
Development

No branches or pull requests

3 participants