Files
evm/plugin
Ceyhun OnurandGitHub c14d46dc0f Reward Manager precompile (#260)
* add initial precompile configs and handle them

* add verify to precompile configs

* add unit tests for initial configs and verify

* add a nil check for initial fee config verification

* conditionally verify allowlist

* Update precompile/stateful_precompile_config.go

Co-authored-by: aaronbuchwald <[email protected]>

* add config test to precompile package

* add 0 test case for gas limit

* add comments for allowlist storage keys

* move allow list role to different file

* Update precompile/allow_list.go

Co-authored-by: aaronbuchwald <[email protected]>

* rename test

* Update precompile/allow_list.go

Co-authored-by: Darioush Jalali <[email protected]>

* rename test & use func to create config

* Remove unnecessary role checks

* use config constructor for precompile tests

* Update accounts/abi/bind/precompile_template.go

Co-authored-by: Darioush Jalali <[email protected]>

* Update precompile/contract_native_minter.go

Co-authored-by: Darioush Jalali <[email protected]>

* Update precompile/contract_deployer_allow_list.go

Co-authored-by: Darioush Jalali <[email protected]>

* Update precompile/allow_list.go

Co-authored-by: Darioush Jalali <[email protected]>

* add equals methods

* initialize reward manager precompile by precompilegen

* add reward upgrade to block verification

* handle empty case in configure

* use single field to decide allow fee recipieints

* add coinbase verification

* configure miner with coinbase in state accordingly

* Remove abis

* use header coinbase for verification

* remove hashToBool util methods

* use require and remove unneccessary address field from test

* add unit tests

* cleanups

* Update consensus/dummy/consensus.go

Co-authored-by: Darioush Jalali <[email protected]>

* Update contract-examples/contracts/IAllowList.sol

Co-authored-by: Darioush Jalali <[email protected]>

* Update core/stateful_precompile_test.go

Co-authored-by: Darioush Jalali <[email protected]>

* Update core/stateful_precompile_test.go

Co-authored-by: Darioush Jalali <[email protected]>

* Update core/stateful_precompile_test.go

Co-authored-by: Darioush Jalali <[email protected]>

* Update precompile/reward_manager.go

Co-authored-by: Darioush Jalali <[email protected]>

* Update precompile/reward_manager.go

Co-authored-by: Darioush Jalali <[email protected]>

* Update precompile/reward_manager.go

Co-authored-by: Darioush Jalali <[email protected]>

* review fixes

* add e2e tests and example contract

* add initial config to test

* Update contract-examples/tasks.ts

Co-authored-by: Darioush Jalali <[email protected]>

* Update contract-examples/test/ExampleRewardDistributor.ts

Co-authored-by: Darioush Jalali <[email protected]>

* Update contract-examples/test/ExampleRewardDistributor.ts

Co-authored-by: Darioush Jalali <[email protected]>

* review fixes

* Update consensus/dummy/consensus.go

Co-authored-by: aaronbuchwald <[email protected]>

* Update params/config.go

Co-authored-by: aaronbuchwald <[email protected]>

* Update params/config.go

Co-authored-by: aaronbuchwald <[email protected]>

* fixs after review

* add string method to reward manager

* revert coinbase syntactic verification

* review fixes

* review fixes

* add disabled precompile test cases

* use hash value instead of address

* config cleanup

* Update contract-examples/tasks.ts

Co-authored-by: Darioush Jalali <[email protected]>

* Update contract-examples/tasks.ts

Co-authored-by: Darioush Jalali <[email protected]>

* more nit fixes

* fix conflict

* add disabled test case
2022-11-21 14:17:25 -05:00
..
2022-11-21 14:17:25 -05:00
2021-12-15 12:28:56 -08:00
2022-04-13 15:28:00 -07:00
2021-12-15 12:28:56 -08:00