cya
cya copied to clipboard
Use service account Admin resource to set weights
Issue To Be Solved
Currently, the transactions to update weights for fees just save values directly to storage. These should be resource functions with proper input validation.
Suggest A Solution
Add functions with input validaton to FlowServiceAccount.Administrator to:
- Set execution effort weights
- https://github.com/onflow/flow-core-contracts/blob/master/transactions/FlowServiceAccount/set_execution_effort_weights.cdc
- Set execution memory limits
- https://github.com/onflow/flow-core-contracts/blob/master/transactions/FlowServiceAccount/set_execution_memory_limit.cdc
- Set execution memory weights
- https://github.com/onflow/flow-core-contracts/blob/master/transactions/FlowServiceAccount/set_execution_memory_weights.cdc
Write tests to ensure the functions work and the input validation works