Source

ocaml-bitbucket / api.ml

Diff from to
     | `Http (n, _err) -> fprintf ppf "HTTP Error %d@." n
     | `Json_parse exn -> fprintf ppf "Error at Json parse: %s@." (Printexc.to_string exn)
     | `Other exn      -> fprintf ppf "Error: %s@." (Printexc.to_string exn)
-    | `Json_conv ((_,v) as e) -> 
-        (* CR jfuruse: This is bit strange. Meta_conv.Error.format should print [v] too? *)
-        Format.eprintf "%a@.Error input: %s@." 
-          (Meta_conv.Error.format (fun _ _ -> ())) e
-          (Json.show v)
+    | `Json_conv e    -> Json_conv.format_full_error Format.err_formatter e
 end
 
 module Data = struct