Client: avoid unrequired monitor

This commit is contained in:
Grégoire Henry 2017-03-09 14:35:43 +01:00
parent 556c965af7
commit 82628a6ca2

View File

@ -28,17 +28,17 @@ let run cctxt ?max_priority ~delay ?min_date delegates =
Lwt.return_unit
in
let forge =
Client_mining_blocks.monitor
cctxt ?min_date ~min_heads:1 () >>= fun block_stream ->
(* Temporary desactivate the monitoring of endorsement:
too slow for now. *)
(* Client_mining_operations.monitor_endorsement *)
if Client_proto_args.Daemon.(!all || !mining) then begin
Client_mining_blocks.monitor
cctxt ?min_date ~min_heads:1 () >>= fun block_stream ->
(* Temporary desactivate the monitoring of endorsement:
too slow for now. *)
(* Client_mining_operations.monitor_endorsement *)
(* cctxt >>= fun endorsement_stream -> *)
let endorsement_stream, _push = Lwt_stream.create () in
if Client_proto_args.Daemon.(!all || !mining) then
let endorsement_stream, _push = Lwt_stream.create () in
Client_mining_forge.create cctxt
?max_priority delegates block_stream endorsement_stream
else
end else
Lwt.return_unit
in
denunciation >>= fun () ->