Skip to content

Commit

Permalink
Updates check table in fee specs
Browse files Browse the repository at this point in the history
  • Loading branch information
grarco committed Feb 8, 2023
1 parent d9945ea commit 62c3a8e
Showing 1 changed file with 5 additions and 5 deletions.
10 changes: 5 additions & 5 deletions documentation/specs/src/economics/fee-system.md
Original file line number Diff line number Diff line change
Expand Up @@ -331,11 +331,11 @@ explains the last statement of the previous section.

This section summarizes the checks performed in protocol.

| Method | Checks | If check fails |
| ------------------------------- | --------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | ---------------------- |
| `CheckTx` and `ProcessProposal` | <ul><li> Each wrapper tx `GasLimit` doesn't surpass `MaxBlockGas` protocol parameter</li><li> Fees are paid with a whitelisted token and meet the minimum amount required of fee per unit of gas</li><li>If unshielding: <ul><li>tx data must deserialize to `Transfer`</li><li>`source` must be the masp</li><li>`target` must match the wrapper signer</li><li>`token` must match the `Fee` one</li></ul></li></ul> | Reject the block |
| `ProcessProposal` | <ul><li>If unshielding: <ul><li>`amount` is the minimum required</li><li>the transfer must run successfully</li></ul></li><li>Wrapper transactions are listed before decrypted transactions</li><li>Paying address has enough funds to cover fee</li><li>Cumulated `GasLimit` isn't greater than the `MaxBlockGas` parameter</li></ul> | Reject the block |
| `FinalizeBlock` | <ul><li>For every tx, gas used isn't greater than the `GasLimit` allocated in the corresponding wrapper</li></ul> | Reject the transaction |
| Method | Checks | If check fails |
| ------------------------------- | -------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | ---------------------- |
| `CheckTx` and `ProcessProposal` | <ul><li> Each wrapper tx `GasLimit` doesn't surpass `MaxBlockGas` protocol parameter</li><li> Fees are paid with a whitelisted token and meet the minimum amount required of fee per unit of gas</li><li>If unshielding: <ul><li>tx data must deserialize to `Transfer`</li><li>`source` must be the masp</li><li>`target` must match the wrapper signer</li><li>`token` must match the `Fee` one</li><li>`amount` is the minimum required</li><li>the transfer must run successfully</li></ul><li>Paying address has enough funds to cover fee</li></li></ul> | Reject the block |
| `ProcessProposal` | <ul><li>Wrapper transactions are listed before decrypted transactions</li><li>Cumulated `GasLimit` isn't greater than the `MaxBlockGas` parameter</li></ul> | Reject the block |
| `FinalizeBlock` | <ul><li>For every tx, gas used isn't greater than the `GasLimit` allocated in the corresponding wrapper</li></ul> | Reject the transaction |

## Alternatives considered

Expand Down

0 comments on commit 62c3a8e

Please sign in to comment.