The implementation of staking rewards withdrawals on the Gnosis Chain differs from Ethereum, and rewards aren't distributed automatically. Consequently, automating rewards distribution through an application layer protocol becomes essential. This project is motivated by Gnosis validators' desire for automated staking rewards distribution and maintains the opt-in/opt-out approach proposed by the community. The repository includes a claim registry contract enabling validators to set claim thresholds and frequencies. For claim execution, the PowerPool keepers network is chosen as the most Web3.0 idiomatic approach.
See implementation details for technical overview.
forge install
cp .env.example .env
*set your environment variables
source .env
forge script script/Deploy.s.sol:Deploy --rpc-url $GNOSIS_RPC_URL --broadcast --etherscan-api-key $ETHERSCAN_API_KEY --verify --watch
*Proxy address to call is got from .env
PROXY_ADDRESS
variable by default, change it if necessary
forge script script/Upgrade.s.sol:Upgrade --rpc-url $GNOSIS_RPC_URL --broadcast --etherscan-api-key $ETHERSCAN_API_KEY --verify --watch
forge doc --serve --port 4000
Go to Power Pool app
- Create a job on Gnosis chain.
- Make sure to use resolver condition.
- Set proxy address for both target contract and resolver contract since ClaimRegistry combine this functionalities. If contracts are verified than you will be able to choose target functions, otherwise paste ABI manually.
- Job balance may be topped up via UI.
Name | Gnosis Mainnet | Chiado |
---|---|---|
ERC1967 Proxy | 0xe4d0a119cc2546c1ec4945c04b04985d1e59cdba | 0x28f1ba1f2Db9Aa0ca4b3B7cD9Ae327f6E872867D |
ClaimRegistryUpgradeable (implementation) | 0x7b2461e35fd7c45ce2dcdab964a722ffb0fc483c | 0x630098a725042A25588B194928c43224e6fE6E82 |