Alpha/Endorser: Log timeout errors

This commit is contained in:
MBourgoin 2018-06-14 09:30:35 +02:00 committed by Grégoire Henry
parent b9d97a7a94
commit 669b1b02e7

View File

@ -203,7 +203,10 @@ let endorse_for cctxt = function
endorsements
in
iter_p (endorse_for_delegate cctxt) done_waiting >>=? fun () ->
ignore errored; (* TODO: log *)
Lwt_list.iter_p (fun {timeout} ->
match Lwt.state timeout with
| Lwt.Fail f -> lwt_log_error "Endorsement failure: %s" (Printexc.to_string f)
| _ -> Lwt.return_unit) errored >>= fun () ->
return still_waiting