Mavryk_raw_protocol_alpha.Protocol_treasury_storage
val get_buffer_address :
Raw_context.t ->
Contract_hash.t Mavryk_protocol_environment_alpha.Error_monad.tzresult
Mavryk_protocol_environment_alpha.Lwt.t
Get the address of the Buffer Contract receiving the Liquidity Baking subsidy
val get_protocol_treasury_address : Contract_hash.t
Get the address of the Protocol Treasury Contract receiving the Liquidity Baking subsidy
val on_subsidy_allowed :
Raw_context.t ->
per_block_vote:Per_block_votes_repr.per_block_vote ->
(Raw_context.t ->
Contract_hash.t ->
(Raw_context.t * 'a list)
Mavryk_protocol_environment_alpha.Error_monad.tzresult
Mavryk_protocol_environment_alpha.Lwt.t) ->
(Raw_context.t * 'a list * Per_block_votes_repr.Liquidity_baking_toggle_EMA.t)
Mavryk_protocol_environment_alpha.Error_monad.tzresult
Mavryk_protocol_environment_alpha.Lwt.t
on_subsidy_allowed ctxt ~per_block_vote f
updates the toggle EMA according to toggle_vote
. Then the callback function f
is called if the following conditions are met:
The role of the callback function f
is to send the subsidy to the CPMM, see apply_liquidity_baking_subsidy
in apply.ml
.