Proto_alpha/forge: more consistent style
This commit is contained in:
parent
e956c1f7bf
commit
d30894b2f9
@ -973,7 +973,8 @@ let bake (cctxt : #Proto_alpha.full) state =
|
|||||||
lwt_log_error Tag.DSL.(fun f ->
|
lwt_log_error Tag.DSL.(fun f ->
|
||||||
f "Level %a : previously baked"
|
f "Level %a : previously baked"
|
||||||
-% t event "double_bake_near_miss"
|
-% t event "double_bake_near_miss"
|
||||||
-% a level_tag level) >>= return
|
-% a level_tag level) >>= fun () ->
|
||||||
|
return_unit
|
||||||
| false ->
|
| false ->
|
||||||
(* Record baked blocks to prevent double baking and nonces to reveal later *)
|
(* Record baked blocks to prevent double baking and nonces to reveal later *)
|
||||||
State.record cctxt src_pkh level >>=? fun () ->
|
State.record cctxt src_pkh level >>=? fun () ->
|
||||||
@ -985,8 +986,8 @@ let bake (cctxt : #Proto_alpha.full) state =
|
|||||||
f "@[<v 4>Error while injecting block@ @[Included operations : %a@]@ %a@]"
|
f "@[<v 4>Error while injecting block@ @[Included operations : %a@]@ %a@]"
|
||||||
-% t event "block_injection_failed"
|
-% t event "block_injection_failed"
|
||||||
-% a raw_operations_tag (List.concat operations)
|
-% a raw_operations_tag (List.concat operations)
|
||||||
-% a errs_tag errs
|
-% a errs_tag errs) >>= fun () ->
|
||||||
) >>= fun () -> return_unit
|
return_unit
|
||||||
|
|
||||||
| Ok block_hash ->
|
| Ok block_hash ->
|
||||||
lwt_log_notice Tag.DSL.(fun f ->
|
lwt_log_notice Tag.DSL.(fun f ->
|
||||||
@ -998,8 +999,7 @@ let bake (cctxt : #Proto_alpha.full) state =
|
|||||||
-% a level_tag level
|
-% a level_tag level
|
||||||
-% s bake_priority_tag priority
|
-% s bake_priority_tag priority
|
||||||
-% a fitness_tag shell_header.fitness
|
-% a fitness_tag shell_header.fitness
|
||||||
-% a operations_tag operations
|
-% a operations_tag operations) >>= fun () ->
|
||||||
) >>= fun () ->
|
|
||||||
|
|
||||||
begin if seed_nonce_hash <> None then
|
begin if seed_nonce_hash <> None then
|
||||||
Client_baking_nonces.add cctxt block_hash seed_nonce
|
Client_baking_nonces.add cctxt block_hash seed_nonce
|
||||||
@ -1171,8 +1171,7 @@ let reveal_potential_nonces cctxt new_head =
|
|||||||
lwt_warn Tag.DSL.(fun f ->
|
lwt_warn Tag.DSL.(fun f ->
|
||||||
f "Cannot read nonces: %a"
|
f "Cannot read nonces: %a"
|
||||||
-% t event "read_nonce_fail"
|
-% t event "read_nonce_fail"
|
||||||
-% a errs_tag err)
|
-% a errs_tag err) >>= fun () ->
|
||||||
>>= fun () ->
|
|
||||||
return_unit
|
return_unit
|
||||||
|
|
||||||
(** [create] starts the main loop of the baker. The loop monitors new blocks and
|
(** [create] starts the main loop of the baker. The loop monitors new blocks and
|
||||||
|
Loading…
Reference in New Issue
Block a user