diff --git a/lib_node_shell/peer_validator.ml b/lib_node_shell/peer_validator.ml index 0f8015d09..e66329e6c 100644 --- a/lib_node_shell/peer_validator.ml +++ b/lib_node_shell/peer_validator.ml @@ -191,12 +191,13 @@ let rec worker_loop pv = end >>= function | Ok () -> worker_loop pv - | Error (( Unknown_ancestor + | Error ((( Unknown_ancestor | Block_locator.Invalid_locator _ - | Block_validator.Invalid_block _ ) :: _) -> + | Block_validator.Invalid_block _ ) :: _) as errors ) -> (* TODO ban the peer_id... *) lwt_log_info "Terminating the validation worker for peer %a (kickban)." P2p.Peer_id.pp_short pv.peer_id >>= fun () -> + lwt_debug "%a" Error_monad.pp_print_error errors >>= fun () -> Lwt_canceler.cancel pv.canceler >>= fun () -> Lwt.return_unit | Error [Block_validator.Unavailable_protocol { protocol } ] -> begin