diff --git a/cli/commands/assignSubmitter.go b/cli/commands/assignSubmitter.go index 68c9e3ae..a6a2480c 100644 --- a/cli/commands/assignSubmitter.go +++ b/cli/commands/assignSubmitter.go @@ -4,8 +4,8 @@ import ( "context" "fmt" + "github.com/Layr-Labs/eigenlayer-contracts/pkg/bindings/EigenPod" "github.com/Layr-Labs/eigenpod-proofs-generation/cli/core" - "github.com/Layr-Labs/eigenpod-proofs-generation/cli/core/onchain" "github.com/ethereum/go-ethereum/common" "github.com/ethereum/go-ethereum/ethclient" "github.com/fatih/color" @@ -44,7 +44,7 @@ func AssignSubmitterCommand(args TAssignSubmitterArgs) error { return fmt.Errorf("failed to parse --sender: %w", err) } - pod, err := onchain.NewEigenPod(common.HexToAddress(args.EigenpodAddress), eth) + pod, err := EigenPod.NewEigenPod(common.HexToAddress(args.EigenpodAddress), eth) if err != nil { return fmt.Errorf("error contacting eigenpod: %w", err) } diff --git a/cli/commands/checkpoint.go b/cli/commands/checkpoint.go index 645a8bc5..04bbce60 100644 --- a/cli/commands/checkpoint.go +++ b/cli/commands/checkpoint.go @@ -3,8 +3,8 @@ package commands import ( "context" + "github.com/Layr-Labs/eigenlayer-contracts/pkg/bindings/EigenPod" "github.com/Layr-Labs/eigenpod-proofs-generation/cli/core" - "github.com/Layr-Labs/eigenpod-proofs-generation/cli/core/onchain" "github.com/Layr-Labs/eigenpod-proofs-generation/cli/utils" "github.com/ethereum/go-ethereum/accounts/abi/bind" "github.com/ethereum/go-ethereum/common" @@ -42,7 +42,7 @@ func CheckpointCommand(args TCheckpointCommandArgs) error { currentCheckpoint, err := core.GetCurrentCheckpoint(args.EigenpodAddress, eth) core.PanicOnError("failed to load checkpoint", err) - eigenpod, err := onchain.NewEigenPod(common.HexToAddress(args.EigenpodAddress), eth) + eigenpod, err := EigenPod.NewEigenPod(common.HexToAddress(args.EigenpodAddress), eth) core.PanicOnError("failed to connect to eigenpod", err) if currentCheckpoint == 0 { diff --git a/cli/commands/computeCheckpointableValue.go b/cli/commands/computeCheckpointableValue.go deleted file mode 100644 index fa2b0b22..00000000 --- a/cli/commands/computeCheckpointableValue.go +++ /dev/null @@ -1,338 +0,0 @@ -package commands - -import ( - "context" - _ "embed" - "fmt" - "math/big" - "strings" - - "github.com/Layr-Labs/eigenpod-proofs-generation/cli/core" - "github.com/Layr-Labs/eigenpod-proofs-generation/cli/core/multicall" - "github.com/Layr-Labs/eigenpod-proofs-generation/cli/core/onchain" - "github.com/Layr-Labs/eigenpod-proofs-generation/cli/utils" - "github.com/attestantio/go-eth2-client/spec/phase0" - "github.com/ethereum/go-ethereum/accounts/abi" - "github.com/ethereum/go-ethereum/common" - "github.com/ethereum/go-ethereum/ethclient" -) - -type TComputeCheckpointableValueCommandArgs struct { - Node string - BeaconNode string -} - -// TODO: this is duplicated -func PodManagerContracts() map[uint64]string { - return map[uint64]string{ - 1: "0x91E677b07F7AF907ec9a428aafA9fc14a0d3A338", - 17000: "0x30770d7E3e71112d7A6b7259542D1f680a70e315", //testnet holesky - } -} - -type TQueryAllEigenpodsOnNetworkArgs struct { - Ctx context.Context - AllValidators []core.ValidatorWithIndex - Eth *ethclient.Client - EigenpodAbi abi.ABI - PodManagerAbi abi.ABI - PodManagerAddress string - Mc *multicall.MulticallClient -} - -func queryAllEigenpodsOnNetwork(args TQueryAllEigenpodsOnNetworkArgs) ([]string, error) { - // see which validators are eigenpods - // - // 1. can ignore anything that isn't withdrawing to the execution chain. - executionLayerWithdrawalCredentialValidators := utils.Filter(args.AllValidators, func(validator core.ValidatorWithIndex) bool { - return validator.Validator.WithdrawalCredentials[0] == 1 - }) - - interestingWithdrawalAddresses := getKeys(utils.Reduce(executionLayerWithdrawalCredentialValidators, func(accum map[string]int, next core.ValidatorWithIndex) map[string]int { - accum[common.Bytes2Hex(next.Validator.WithdrawalCredentials[12:])] = 1 - return accum - }, map[string]int{})) - - fmt.Printf("Querying %d addresses to see if they may be eigenpods\n", len(interestingWithdrawalAddresses)) - podOwners, err := multicall.DoMultiCallManyReportingFailures[*common.Address](*args.Mc, utils.Map(interestingWithdrawalAddresses, func(address string, index uint64) *multicall.MultiCallMetaData[*common.Address] { - callMeta, err := multicall.MultiCall( - common.HexToAddress(address), - args.EigenpodAbi, - func(data []byte) (*common.Address, error) { - res, err := args.EigenpodAbi.Unpack("podOwner", data) - if err != nil { - return nil, err - } - return abi.ConvertType(res[0], new(common.Address)).(*common.Address), nil - }, "podOwner", - ) - core.PanicOnError("failed to form mc", err) - return callMeta - })...) - - if podOwners == nil || err != nil || len(*podOwners) == 0 { - core.PanicOnError("failed to fetch podOwners", err) - core.Panic("loaded no pod owners") - return nil, err - } - - // now we can filter by which addresses actually claimed to have podOwner() - podToPodOwner := map[string]*common.Address{} - addressesWithPodOwners := utils.FilterI(interestingWithdrawalAddresses, func(address string, i uint64) bool { - success := (*podOwners)[i].Success - if success { - podToPodOwner[address] = (*podOwners)[i].Value - } - return success - }) - - // array[eigenpods given the owner] - fmt.Printf("Querying %d addresses on (EigenPodManager=%s) to see if it knows about these eigenpods\n", len(addressesWithPodOwners), args.PodManagerAddress) - - eigenpodForOwner, err := multicall.DoMultiCallManyReportingFailures( - *args.Mc, - utils.Map(addressesWithPodOwners, func(address string, i uint64) *multicall.MultiCallMetaData[*common.Address] { - claimedOwner := *podToPodOwner[address] - call, err := multicall.MultiCall( - common.HexToAddress(args.PodManagerAddress), - args.PodManagerAbi, - func(data []byte) (*common.Address, error) { - res, err := args.PodManagerAbi.Unpack("ownerToPod", data) - if err != nil { - return nil, err - } - return abi.ConvertType(res[0], new(common.Address)).(*common.Address), nil - }, - "ownerToPod", - claimedOwner, - ) - core.PanicOnError("failed to form multicall", err) - return call - })..., - ) - core.PanicOnError("failed to query", err) - - // now, see which of `addressesWithPodOwners` properly were eigenpods. - return utils.FilterI(addressesWithPodOwners, func(address string, i uint64) bool { - return (*eigenpodForOwner)[i].Success && (*eigenpodForOwner)[i].Value.Cmp(common.HexToAddress(addressesWithPodOwners[i])) == 0 - }), nil -} - -//go:embed multicallAbi.json -var multicallAbi string - -func ComputeCheckpointableValueCommand(args TComputeCheckpointableValueCommandArgs) error { - ctx := context.Background() - - eigenpodAbi, err := abi.JSON(strings.NewReader(onchain.EigenPodABI)) - core.PanicOnError("failed to load eigenpod abi", err) - - podManagerAbi, err := abi.JSON(strings.NewReader(onchain.EigenPodManagerABI)) - core.PanicOnError("failed to load eigenpod manager abi", err) - - eth, beaconClient, chainId, err := core.GetClients(ctx, args.Node, args.BeaconNode, true) - core.PanicOnError("failed to reach ethereum clients", err) - - mc, err := multicall.NewMulticallClient(ctx, eth, &multicall.TMulticallClientOptions{ - MaxBatchSizeBytes: 8192, - }) - core.PanicOnError("error initializing mc", err) - - podManagerAddress, ok := PodManagerContracts()[chainId.Uint64()] - if !ok { - core.Panic("unsupported network") - } - - // fetch latest beacon state. - beaconState, err := beaconClient.GetBeaconState(ctx, "head") - core.PanicOnError("failed to load beacon state", err) - - allBalances, err := beaconState.ValidatorBalances() - core.PanicOnError("failed to parse beacon balances", err) - - _allValidators, err := beaconState.Validators() - core.PanicOnError("failed to fetch validators", err) - allValidators := utils.Map(_allValidators, func(validator *phase0.Validator, i uint64) core.ValidatorWithIndex { - return core.ValidatorWithIndex{ - Validator: validator, - Index: i, - } - }) - - allEigenpods, err := queryAllEigenpodsOnNetwork(TQueryAllEigenpodsOnNetworkArgs{ - Ctx: ctx, - AllValidators: allValidators, - Eth: eth, - EigenpodAbi: eigenpodAbi, - PodManagerAbi: podManagerAbi, - PodManagerAddress: podManagerAddress, - Mc: mc, - }) - core.PanicOnError("queryAllEigenpodsOnNetwork", err) - - isEigenpodSet := utils.Reduce(allEigenpods, func(allEigenpodSet map[string]int, eigenpod string) map[string]int { - allEigenpodSet[strings.ToLower(eigenpod)] = 1 - return allEigenpodSet - }, map[string]int{}) - - fmt.Printf("%d eigenpods discovered on the network", len(allEigenpods)) - - // Compute all pending rewards for each eigenpod; - // see: https://github.com/Layr-Labs/eigenlayer-contracts/blob/dev/src/contracts/pods/EigenPod.sol#L656 - // - // futureCheckpointableRewards(eigenpod) := (podBalanceGwei + checkpoint.balanceDeltasGwei) - // - // where: - // podBalanceGwei = address(pod).balanceGwei - pod.withdrawableRestakedExecutionLayerGwei - // and - // checkpoint.balanceDeltasGwei = sumBeaconBalancesGwei - sumRestakedBalancesGwei - multicallAbiRef, err := abi.JSON(strings.NewReader(multicallAbi)) - core.PanicOnError("failed to load multicall abi", err) - - fmt.Printf("Loading Eigenpod ETH balances....\n") - podNativeEthBalances, err := multicall.DoMultiCallMany( - *mc, - utils.Map(allEigenpods, func(eigenpod string, index uint64) *multicall.MultiCallMetaData[*big.Int] { - call, err := multicall.MultiCall( - common.HexToAddress("0xcA11bde05977b3631167028862bE2a173976CA11"), - multicallAbiRef, - func(b []byte) (*big.Int, error) { - res, err := multicallAbiRef.Unpack("getEthBalance", b) - if err != nil { - return nil, err - } - out := abi.ConvertType(res[0], new(big.Int)).(*big.Int) - return out, nil - }, - "getEthBalance", - common.HexToAddress(eigenpod), - ) - core.PanicOnError("failed to form multicall", err) - return call - })..., - ) - if err != nil || podNativeEthBalances == nil { - core.PanicOnError("failed to multicall eigenpod balances", err) - core.Panic("failed to load eigenpod balances") - } - - fmt.Printf("Loading EigenPod.withdrawableRestakedExecutionLayerGwei....\n") - withdrawableRestakedExecutionLayerGwei, err := multicall.DoMultiCallMany( - *mc, - utils.Map(allEigenpods, func(eigenpod string, index uint64) *multicall.MultiCallMetaData[uint64] { - call, err := multicall.MultiCall( - common.HexToAddress(eigenpod), - eigenpodAbi, - func(b []byte) (uint64, error) { - res, err := eigenpodAbi.Unpack("withdrawableRestakedExecutionLayerGwei", b) - if err != nil { - return 0, err - } - out := abi.ConvertType(res[0], new(uint64)).(*uint64) - return *out, nil - }, - "withdrawableRestakedExecutionLayerGwei", - ) - core.PanicOnError("failed to form multicall", err) - return call - })..., - ) - if err != nil || withdrawableRestakedExecutionLayerGwei == nil { - core.PanicOnError("failed to multicall eigenpod.withdrawableRestakedExecutionLayerGwei", err) - core.Panic("failed to load eigenpod withdrawableRestakedExecutionLayerGwei") - } - - allPendingExecutionWei := utils.Map(allEigenpods, func(eigenpod string, index uint64) *big.Int { - podCurrentNativeWei := (*podNativeEthBalances)[index] - podWithdrawableRestakedExecutionLayerWei := core.IGweiToWei(new(big.Int).SetUint64((*withdrawableRestakedExecutionLayerGwei)[index])) - return new(big.Int).Sub(podCurrentNativeWei, podWithdrawableRestakedExecutionLayerWei) - }) - - allValidatorsForEigenpod := utils.Reduce(allValidators, func(validatorsByPod map[string][]core.ValidatorWithIndex, validator core.ValidatorWithIndex) map[string][]core.ValidatorWithIndex { - withdrawalAddress := common.BytesToAddress(validator.Validator.WithdrawalCredentials[12:]) - eigenpod := strings.ToLower(withdrawalAddress.Hex()[2:]) // remove 0x - - if isEigenpodSet[eigenpod] == 1 { - if validatorsByPod[eigenpod] == nil { - validatorsByPod[eigenpod] = []core.ValidatorWithIndex{} - } - - validatorsByPod[eigenpod] = append(validatorsByPod[eigenpod], validator) - } - return validatorsByPod - }, map[string][]core.ValidatorWithIndex{}) - - type ValidatorPodPair struct { - Validator core.ValidatorWithIndex - Pod string - } - - allEigenlayerValidatorsWithPod := utils.Reduce(getKeys(allValidatorsForEigenpod), func(validators []ValidatorPodPair, eigenpod string) []ValidatorPodPair { - validators = append(validators, utils.Map(allValidatorsForEigenpod[eigenpod], func(validator core.ValidatorWithIndex, i uint64) ValidatorPodPair { - return ValidatorPodPair{ - Validator: validator, - Pod: eigenpod, - } - })...) - return validators - }, []ValidatorPodPair{}) - - allValidatorInfoRequests := utils.Map(allEigenlayerValidatorsWithPod, func(validatorPodPair ValidatorPodPair, index uint64) *multicall.MultiCallMetaData[*onchain.IEigenPodValidatorInfo] { - res, err := core.FetchMultipleOnchainValidatorInfoMulticalls(validatorPodPair.Pod, []*phase0.Validator{validatorPodPair.Validator.Validator}) - core.PanicOnError("failed to form mc", err) - return res[0] - }) - allValidatorInfo, err := multicall.DoMultiCallMany(*mc, allValidatorInfoRequests...) - core.PanicOnError("failed to multicall validator info", err) - - i := 0 - allValidatorInfoLookupByIndex := utils.Reduce(*allValidatorInfo, func(validatorInfoLookup map[uint64]*onchain.IEigenPodValidatorInfo, cur *onchain.IEigenPodValidatorInfo) map[uint64]*onchain.IEigenPodValidatorInfo { - validatorInfoLookup[allEigenlayerValidatorsWithPod[i].Validator.Index] = cur - i++ - return validatorInfoLookup - }, map[uint64]*onchain.IEigenPodValidatorInfo{}) - - beaconBalancesWei := utils.Map(allEigenlayerValidatorsWithPod, func(validatorPodPair ValidatorPodPair, i uint64) *big.Int { - validatorInfo := (*allValidatorInfo)[i] - if validatorInfo.Status != core.ValidatorStatusActive { - return big.NewInt(0) - } - - balanceGwei := allBalances[validatorPodPair.Validator.Index] - return core.IGweiToWei(new(big.Int).SetUint64(uint64(balanceGwei))) - }) - - sumBeaconBalancesWei := utils.BigSum(beaconBalancesWei) - restakedBalancesByValidator := utils.Reduce(allEigenlayerValidatorsWithPod, func(accum map[uint64]*big.Int, next ValidatorPodPair) map[uint64]*big.Int { - info := allValidatorInfoLookupByIndex[next.Validator.Index] - if info.Status != core.ValidatorStatusActive { - accum[next.Validator.Index] = big.NewInt(0) - } else { - accum[next.Validator.Index] = core.IGweiToWei(new(big.Int).SetUint64(info.RestakedBalanceGwei)) - } - - return accum - }, map[uint64]*big.Int{}) - - sumRestakedBalancesWei := utils.BigSum(getValues(restakedBalancesByValidator)) - pendingBeaconWei := big.NewInt(0).Sub(sumBeaconBalancesWei, sumRestakedBalancesWei) - pendingExecutionWei := utils.BigSum(allPendingExecutionWei) - - totalPendingRewards := big.NewInt(0).Add(pendingExecutionWei, pendingBeaconWei) - - totalRewards := map[string]*big.Float{ - // `podBalanceGwei` - `withdrawableRestakedExecutionLayerGwei` - "pending_execution_wei": new(big.Float).SetInt(pendingExecutionWei), - "pending_execution_eth": core.GweiToEther(core.WeiToGwei(pendingExecutionWei)), - - // sumBeaconBalances - sum(activeValidators.info.restakedBalanceGwei) - "pending_beacon_wei": new(big.Float).SetInt(pendingBeaconWei), - "pending_beacon_eth": core.GweiToEther(core.WeiToGwei(pendingBeaconWei)), - - "total_pending_shares_wei": new(big.Float).SetInt(totalPendingRewards), - "total_pending_shares_gwei": core.WeiToGwei(totalPendingRewards), - "total_pending_shares_eth": core.GweiToEther(core.WeiToGwei(totalPendingRewards)), - } - printAsJSON(totalRewards) - return nil -} diff --git a/cli/commands/multicallAbi.json b/cli/commands/multicallAbi.json deleted file mode 100644 index 0da96a59..00000000 --- a/cli/commands/multicallAbi.json +++ /dev/null @@ -1,440 +0,0 @@ -[ - { - "inputs": [ - { - "components": [ - { - "internalType": "address", - "name": "target", - "type": "address" - }, - { - "internalType": "bytes", - "name": "callData", - "type": "bytes" - } - ], - "internalType": "struct Multicall3.Call[]", - "name": "calls", - "type": "tuple[]" - } - ], - "name": "aggregate", - "outputs": [ - { - "internalType": "uint256", - "name": "blockNumber", - "type": "uint256" - }, - { - "internalType": "bytes[]", - "name": "returnData", - "type": "bytes[]" - } - ], - "stateMutability": "payable", - "type": "function" - }, - { - "inputs": [ - { - "components": [ - { - "internalType": "address", - "name": "target", - "type": "address" - }, - { - "internalType": "bool", - "name": "allowFailure", - "type": "bool" - }, - { - "internalType": "bytes", - "name": "callData", - "type": "bytes" - } - ], - "internalType": "struct Multicall3.Call3[]", - "name": "calls", - "type": "tuple[]" - } - ], - "name": "aggregate3", - "outputs": [ - { - "components": [ - { - "internalType": "bool", - "name": "success", - "type": "bool" - }, - { - "internalType": "bytes", - "name": "returnData", - "type": "bytes" - } - ], - "internalType": "struct Multicall3.Result[]", - "name": "returnData", - "type": "tuple[]" - } - ], - "stateMutability": "payable", - "type": "function" - }, - { - "inputs": [ - { - "components": [ - { - "internalType": "address", - "name": "target", - "type": "address" - }, - { - "internalType": "bool", - "name": "allowFailure", - "type": "bool" - }, - { - "internalType": "uint256", - "name": "value", - "type": "uint256" - }, - { - "internalType": "bytes", - "name": "callData", - "type": "bytes" - } - ], - "internalType": "struct Multicall3.Call3Value[]", - "name": "calls", - "type": "tuple[]" - } - ], - "name": "aggregate3Value", - "outputs": [ - { - "components": [ - { - "internalType": "bool", - "name": "success", - "type": "bool" - }, - { - "internalType": "bytes", - "name": "returnData", - "type": "bytes" - } - ], - "internalType": "struct Multicall3.Result[]", - "name": "returnData", - "type": "tuple[]" - } - ], - "stateMutability": "payable", - "type": "function" - }, - { - "inputs": [ - { - "components": [ - { - "internalType": "address", - "name": "target", - "type": "address" - }, - { - "internalType": "bytes", - "name": "callData", - "type": "bytes" - } - ], - "internalType": "struct Multicall3.Call[]", - "name": "calls", - "type": "tuple[]" - } - ], - "name": "blockAndAggregate", - "outputs": [ - { - "internalType": "uint256", - "name": "blockNumber", - "type": "uint256" - }, - { - "internalType": "bytes32", - "name": "blockHash", - "type": "bytes32" - }, - { - "components": [ - { - "internalType": "bool", - "name": "success", - "type": "bool" - }, - { - "internalType": "bytes", - "name": "returnData", - "type": "bytes" - } - ], - "internalType": "struct Multicall3.Result[]", - "name": "returnData", - "type": "tuple[]" - } - ], - "stateMutability": "payable", - "type": "function" - }, - { - "inputs": [], - "name": "getBasefee", - "outputs": [ - { - "internalType": "uint256", - "name": "basefee", - "type": "uint256" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "uint256", - "name": "blockNumber", - "type": "uint256" - } - ], - "name": "getBlockHash", - "outputs": [ - { - "internalType": "bytes32", - "name": "blockHash", - "type": "bytes32" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "getBlockNumber", - "outputs": [ - { - "internalType": "uint256", - "name": "blockNumber", - "type": "uint256" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "getChainId", - "outputs": [ - { - "internalType": "uint256", - "name": "chainid", - "type": "uint256" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "getCurrentBlockCoinbase", - "outputs": [ - { - "internalType": "address", - "name": "coinbase", - "type": "address" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "getCurrentBlockDifficulty", - "outputs": [ - { - "internalType": "uint256", - "name": "difficulty", - "type": "uint256" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "getCurrentBlockGasLimit", - "outputs": [ - { - "internalType": "uint256", - "name": "gaslimit", - "type": "uint256" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "getCurrentBlockTimestamp", - "outputs": [ - { - "internalType": "uint256", - "name": "timestamp", - "type": "uint256" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "addr", - "type": "address" - } - ], - "name": "getEthBalance", - "outputs": [ - { - "internalType": "uint256", - "name": "balance", - "type": "uint256" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "getLastBlockHash", - "outputs": [ - { - "internalType": "bytes32", - "name": "blockHash", - "type": "bytes32" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "bool", - "name": "requireSuccess", - "type": "bool" - }, - { - "components": [ - { - "internalType": "address", - "name": "target", - "type": "address" - }, - { - "internalType": "bytes", - "name": "callData", - "type": "bytes" - } - ], - "internalType": "struct Multicall3.Call[]", - "name": "calls", - "type": "tuple[]" - } - ], - "name": "tryAggregate", - "outputs": [ - { - "components": [ - { - "internalType": "bool", - "name": "success", - "type": "bool" - }, - { - "internalType": "bytes", - "name": "returnData", - "type": "bytes" - } - ], - "internalType": "struct Multicall3.Result[]", - "name": "returnData", - "type": "tuple[]" - } - ], - "stateMutability": "payable", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "bool", - "name": "requireSuccess", - "type": "bool" - }, - { - "components": [ - { - "internalType": "address", - "name": "target", - "type": "address" - }, - { - "internalType": "bytes", - "name": "callData", - "type": "bytes" - } - ], - "internalType": "struct Multicall3.Call[]", - "name": "calls", - "type": "tuple[]" - } - ], - "name": "tryBlockAndAggregate", - "outputs": [ - { - "internalType": "uint256", - "name": "blockNumber", - "type": "uint256" - }, - { - "internalType": "bytes32", - "name": "blockHash", - "type": "bytes32" - }, - { - "components": [ - { - "internalType": "bool", - "name": "success", - "type": "bool" - }, - { - "internalType": "bytes", - "name": "returnData", - "type": "bytes" - } - ], - "internalType": "struct Multicall3.Result[]", - "name": "returnData", - "type": "tuple[]" - } - ], - "stateMutability": "payable", - "type": "function" - } - ] \ No newline at end of file diff --git a/cli/commands/staleBalance.go b/cli/commands/staleBalance.go index 41f1f4c5..e172bf46 100644 --- a/cli/commands/staleBalance.go +++ b/cli/commands/staleBalance.go @@ -5,9 +5,9 @@ import ( "fmt" "math/big" + "github.com/Layr-Labs/eigenlayer-contracts/pkg/bindings/EigenPod" eigenpodproofs "github.com/Layr-Labs/eigenpod-proofs-generation" "github.com/Layr-Labs/eigenpod-proofs-generation/cli/core" - "github.com/Layr-Labs/eigenpod-proofs-generation/cli/core/onchain" "github.com/ethereum/go-ethereum/accounts/abi/bind" "github.com/ethereum/go-ethereum/common" "github.com/fatih/color" @@ -57,7 +57,7 @@ func FixStaleBalance(args TFixStaleBalanceArgs) error { ownerAccount, err := core.PrepareAccount(&args.Sender, chainId, false /* noSend */) core.PanicOnError("failed to parse sender PK", err) - eigenpod, err := onchain.NewEigenPod(common.HexToAddress(args.EigenpodAddress), eth) + eigenpod, err := EigenPod.NewEigenPod(common.HexToAddress(args.EigenpodAddress), eth) core.PanicOnError("failed to reach eigenpod", err) currentCheckpointTimestamp, err := eigenpod.CurrentCheckpointTimestamp(nil) @@ -97,11 +97,11 @@ func FixStaleBalance(args TFixStaleBalanceArgs) error { txn, err := eigenpod.VerifyStaleBalance( ownerAccount.TransactionOptions, oracleBeaconTimesetamp, - onchain.BeaconChainProofsStateRootProof{ + EigenPod.BeaconChainProofsStateRootProof{ Proof: proof.StateRootProof.Proof.ToByteSlice(), BeaconStateRoot: proof.StateRootProof.BeaconStateRoot, }, - onchain.BeaconChainProofsValidatorProof{ + EigenPod.BeaconChainProofsValidatorProof{ ValidatorFields: proofCast(proof.ValidatorFields[0]), Proof: proof.ValidatorFieldsProofs[0].ToByteSlice(), }, diff --git a/cli/core/checkpoint.go b/cli/core/checkpoint.go index d8ab7f88..5bd2db41 100644 --- a/cli/core/checkpoint.go +++ b/cli/core/checkpoint.go @@ -9,8 +9,8 @@ import ( "os" "strconv" + "github.com/Layr-Labs/eigenlayer-contracts/pkg/bindings/EigenPod" eigenpodproofs "github.com/Layr-Labs/eigenpod-proofs-generation" - "github.com/Layr-Labs/eigenpod-proofs-generation/cli/core/onchain" v1 "github.com/attestantio/go-eth2-client/api/v1" "github.com/attestantio/go-eth2-client/spec" "github.com/ethereum/go-ethereum/accounts/abi/bind" @@ -79,7 +79,7 @@ func SubmitCheckpointProofBatch(ctx context.Context, owner, eigenpodAddress stri fmt.Printf("Using account(0x%s) to submit onchain\n", common.Bytes2Hex(ownerAccount.FromAddress[:])) } - eigenPod, err := onchain.NewEigenPod(common.HexToAddress(eigenpodAddress), eth) + eigenPod, err := EigenPod.NewEigenPod(common.HexToAddress(eigenpodAddress), eth) if err != nil { return nil, err } @@ -89,7 +89,7 @@ func SubmitCheckpointProofBatch(ctx context.Context, owner, eigenpodAddress stri }) txn, err := eigenPod.VerifyCheckpointProofs( ownerAccount.TransactionOptions, - onchain.BeaconChainProofsBalanceContainerProof{ + EigenPod.BeaconChainProofsBalanceContainerProof{ BalanceContainerRoot: proof.ValidatorBalancesRoot, Proof: proof.Proof.ToByteSlice(), }, diff --git a/cli/core/findStalePods.go b/cli/core/findStalePods.go index 2aeddbce..dc37ec21 100644 --- a/cli/core/findStalePods.go +++ b/cli/core/findStalePods.go @@ -7,14 +7,17 @@ import ( "math/big" "strings" - "github.com/Layr-Labs/eigenpod-proofs-generation/cli/core/onchain" + "github.com/ethereum/go-ethereum/accounts/abi" + + "github.com/Layr-Labs/eigenlayer-contracts/pkg/bindings/EigenPod" + "github.com/Layr-Labs/eigenlayer-contracts/pkg/bindings/EigenPodManager" + "github.com/Layr-Labs/eigenlayer-contracts/pkg/bindings/IEigenPod" "github.com/Layr-Labs/eigenpod-proofs-generation/cli/utils" + "github.com/attestantio/go-eth2-client/spec" "github.com/attestantio/go-eth2-client/spec/phase0" - "github.com/ethereum/go-ethereum/accounts/abi/bind" "github.com/ethereum/go-ethereum/common" "github.com/ethereum/go-ethereum/ethclient" - "github.com/ethereum/go-ethereum/params" - "github.com/pkg/errors" + "github.com/jbrower95/multicall-go" ) func PodManagerContracts() map[uint64]string { @@ -24,111 +27,189 @@ func PodManagerContracts() map[uint64]string { } } -type Cache struct { - PodOwnerShares map[string]PodOwnerShare -} - // multiply by a fraction func FracMul(a *big.Int, x *big.Int, y *big.Int) *big.Int { _a := new(big.Int).Mul(a, x) return _a.Div(_a, y) } -func keys[A comparable, B any](coll map[A]B) []A { - if len(coll) == 0 { - return []A{} - } - out := make([]A, len(coll)) - i := 0 - for key := range coll { - out[i] = key - i++ +func executionWithdrawalAddress(withdrawalCredentials []byte) *string { + if withdrawalCredentials[0] != 1 { + return nil } - return out -} - -type PodOwnerShare struct { - SharesWei *big.Int - ExecutionLayerBalanceWei *big.Int - IsEigenpod bool + addr := common.Bytes2Hex(withdrawalCredentials[12:]) + return &addr } -var cache Cache // valid for the duration of a command. - -func isEigenpod(eth *ethclient.Client, chainId uint64, eigenpodAddress string) (bool, error) { - if cache.PodOwnerShares == nil { - cache.PodOwnerShares = make(map[string]PodOwnerShare) - } - - if val, ok := cache.PodOwnerShares[eigenpodAddress]; ok { - return val.IsEigenpod, nil +func validEigenpodsOnly(candidateAddresses []common.Address, mc *multicall.MulticallClient, chainId uint64, eth *ethclient.Client) ([]common.Address, error) { + EigenPodAbi, err := abi.JSON(strings.NewReader(EigenPod.EigenPodABI)) + if err != nil { + return nil, fmt.Errorf("failed to load eigenpod abi: %s", err) } - - // default to false - cache.PodOwnerShares[eigenpodAddress] = PodOwnerShare{ - SharesWei: big.NewInt(0), - ExecutionLayerBalanceWei: big.NewInt(0), - IsEigenpod: false, + EigenPodManagerAbi, err := abi.JSON(strings.NewReader(EigenPodManager.EigenPodManagerABI)) + if err != nil { + return nil, fmt.Errorf("failed to load eigenpod manager abi: %s", err) } - podManAddress, ok := PodManagerContracts()[chainId] + podManagerAddress, ok := PodManagerContracts()[chainId] if !ok { - return false, fmt.Errorf("chain %d not supported", chainId) + return nil, fmt.Errorf("Unsupported chainId: %d", chainId) } - podMan, err := onchain.NewEigenPodManager(common.HexToAddress(podManAddress), eth) - if err != nil { - return false, fmt.Errorf("error contacting eigenpod manager: %w", err) + + ////// step 1: cast all addresses to EigenPod, and attempt to read the pod owner. + var lastError error + + calls := utils.Map(candidateAddresses, func(addr common.Address, i uint64) *multicall.MultiCallMetaData[common.Address] { + mc, err := multicall.Describe[common.Address]( + addr, + EigenPodAbi, + "podOwner", + ) + if err != nil { + lastError = err + return nil + } + return mc + }) + if lastError != nil { + return nil, lastError } - if podMan == nil { - return false, errors.New("failed to find eigenpod manager") + reportedPodOwners, err := multicall.DoManyAllowFailures( + mc, + calls..., + ) + if err != nil || reportedPodOwners == nil { + return nil, fmt.Errorf("failed to load podOwners: %w", err) } - pod, err := onchain.NewEigenPod(common.HexToAddress(eigenpodAddress), eth) - if err != nil { - return false, fmt.Errorf("error contacting eigenpod: %w", err) + type PodOwnerResult struct { + Query common.Address + Response multicall.TypedMulticall3Result[*common.Address] } - owner, err := pod.PodOwner(nil) - if err != nil { - return false, fmt.Errorf("error loading podowner: %w", err) + podOwnerPairs := utils.Filter(utils.Map(*reportedPodOwners, func(res multicall.TypedMulticall3Result[*common.Address], i uint64) PodOwnerResult { + return PodOwnerResult{ + Query: candidateAddresses[i], + Response: res, + } + }), func(m PodOwnerResult) bool { + return m.Response.Success + }) + + ////// step 2: using the pod manager, check `ownerToPod` and validate which ones point back at the same address. + authoritativeOwnerToPodCalls := utils.Map(podOwnerPairs, func(res PodOwnerResult, i uint64) *multicall.MultiCallMetaData[common.Address] { + mc, err := multicall.Describe[common.Address]( + common.HexToAddress(podManagerAddress), + EigenPodManagerAbi, + "ownerToPod", + res.Response.Value, + ) + if err != nil { + lastError = err + return nil + } + return mc + }) + if lastError != nil { + return nil, lastError } - expectedPod, err := podMan.OwnerToPod(&bind.CallOpts{}, owner) + authoritativeOwnerToPod, err := multicall.DoMany(mc, authoritativeOwnerToPodCalls...) + nullAddress := common.BigToAddress(big.NewInt(0)) + + ////// step 3: the valid eigenrestpods are the ones where authoritativeOwnerToPod[i] == candidateAddresses[i]. + return utils.Map(utils.FilterI(podOwnerPairs, func(res PodOwnerResult, i uint64) bool { + return (res.Query.Cmp(*(*authoritativeOwnerToPod)[i]) == 0) && (*authoritativeOwnerToPod)[i].Cmp(nullAddress) != 0 + }), func(v PodOwnerResult, i uint64) common.Address { + return v.Query + }), nil +} + +func ComputeBalanceDeviationSync(ctx context.Context, eth *ethclient.Client, state *spec.VersionedBeaconState, eigenpod common.Address) (*big.Float, error) { + pod, err := IEigenPod.NewIEigenPod(eigenpod, eth) if err != nil { - return false, fmt.Errorf("ownerToPod() failed: %s", err.Error()) - } - if expectedPod.Cmp(common.HexToAddress(eigenpodAddress)) != 0 { - return false, nil + return nil, err } - podOwnerShares, err := podMan.PodOwnerShares(nil, owner) + allValidators, err := state.Validators() + PanicOnError("failed to read validators", err) + + allValidatorsWithIndexes := utils.Map(allValidators, func(v *phase0.Validator, i uint64) ValidatorWithIndex { + return ValidatorWithIndex{ + Validator: v, + Index: i, + } + }) + + podValidators := utils.FilterI[ValidatorWithIndex](allValidatorsWithIndexes, func(v ValidatorWithIndex, u uint64) bool { + addr := executionWithdrawalAddress(v.Validator.WithdrawalCredentials) + return addr != nil && eigenpod.Cmp(common.HexToAddress(*addr)) == 0 + }) + + validatorBalances, err := state.ValidatorBalances() + PanicOnError("failed to read beacon state validator balances", err) + + validatorInfo, err := FetchMultipleOnchainValidatorInfoWithFailures(ctx, eth, eigenpod.Hex(), podValidators) if err != nil { - return false, fmt.Errorf("PodOwnerShares() failed: %s", err.Error()) + return nil, err } - balance, err := eth.BalanceAt(context.Background(), common.HexToAddress(eigenpodAddress), nil) + podBalanceWei, err := eth.BalanceAt(ctx, eigenpod, nil) if err != nil { - return false, fmt.Errorf("balance check failed: %s", err.Error()) + return nil, err } - // Simulate fetching from contracts - // Implement contract fetching logic here - cache.PodOwnerShares[eigenpodAddress] = PodOwnerShare{ - SharesWei: podOwnerShares, - ExecutionLayerBalanceWei: balance, - IsEigenpod: true, + sumCurrentBeaconBalancesGwei := utils.BigSum( + utils.Map(podValidators, func(v ValidatorWithIndex, i uint64) *big.Int { + if validatorInfo[i].Info != nil && validatorInfo[i].Info.Status == 1 /* ACTIVE */ { + return new(big.Int).SetUint64(uint64(validatorBalances[v.Index])) + } + return big.NewInt(0) + }), + ) + + sumPreviousBeaconBalancesGwei := utils.BigSum(utils.Map(podValidators, func(v ValidatorWithIndex, i uint64) *big.Int { + if validatorInfo[i].Info != nil && validatorInfo[i].Info.Status == 1 /* ACTIVE */ { + return new(big.Int).SetUint64(validatorInfo[i].Info.RestakedBalanceGwei) + } + return big.NewInt(0) + })) + + // activeValidators := utils.FilterI(podValidators, func(v ValidatorWithIndex, i uint64) bool { + // return validatorInfo[i].Info.Status == 1 + // }) + + regGwei, err := pod.WithdrawableRestakedExecutionLayerGwei(nil) + PanicOnError("failed to load restakedExecutionLayerGwei", err) + // fmt.Printf("-----------------------------------\n") + // fmt.Printf("Pod: %s\n", eigenpod.Hex()) + // fmt.Printf("# validators: %d\n", len(podValidators)) + // fmt.Printf("# active validators: %d\n", len(activeValidators)) + // fmt.Printf("delta := 1 - ((podBalanceGwei + sumCurrentBeaconBalancesGwei) / (regGwei + sumPreviousBeaconBalancesGwei)\n") + // fmt.Printf("delta := 1 - ((%s + %s) / (%d + %s)\n", WeiToGwei(podBalanceWei).String(), sumCurrentBeaconBalancesGwei.String(), regGwei, sumPreviousBeaconBalancesGwei.String()) + + currentState := new(big.Float).Add(WeiToGwei(podBalanceWei), new(big.Float).SetInt(sumCurrentBeaconBalancesGwei)) + prevState := new(big.Float).Add(new(big.Float).SetUint64(regGwei), new(big.Float).SetInt(sumPreviousBeaconBalancesGwei)) + + var delta *big.Float + + if prevState.Cmp(big.NewFloat(0)) == 0 { + delta = big.NewFloat(0) + } else { + delta = new(big.Float).Sub( + big.NewFloat(1), + new(big.Float).Quo( + currentState, + prevState, + ), + ) } - return true, nil -} + // fmt.Printf("(delta=%s%%)\n", new(big.Float).Mul(delta, big.NewFloat(100)).String()) + // fmt.Printf("-----------------------------------\n\n") -func executionWithdrawalAddress(withdrawalCredentials []byte) *string { - if withdrawalCredentials[0] != 1 { - return nil - } - addr := common.Bytes2Hex(withdrawalCredentials[12:]) - return &addr + return delta, nil } func FindStaleEigenpods(ctx context.Context, eth *ethclient.Client, nodeUrl string, beacon BeaconClient, chainId *big.Int, verbose bool, tolerance float64) (map[string][]ValidatorWithIndex, error) { @@ -137,6 +218,11 @@ func FindStaleEigenpods(ctx context.Context, eth *ethclient.Client, nodeUrl stri return nil, fmt.Errorf("error downloading beacon state: %s", err.Error()) } + mc, err := multicall.NewMulticallClient(ctx, eth, nil) + if err != nil { + return nil, err + } + // Simulate fetching validators _allValidators, err := beaconState.Validators() if err != nil { @@ -161,149 +247,32 @@ func FindStaleEigenpods(ctx context.Context, eth *ethclient.Client, nodeUrl stri return true }) - withdrawalAddressesToCheck := make(map[uint64]string) - for _, validator := range allSlashedValidators { - withdrawalAddressesToCheck[validator.Index] = *executionWithdrawalAddress(validator.Validator.WithdrawalCredentials) - } + allSlashedWithdrawalAddresses := utils.Unique( + utils.Map(allSlashedValidators, func(v ValidatorWithIndex, i uint64) common.Address { + return common.HexToAddress(*executionWithdrawalAddress(v.Validator.WithdrawalCredentials)) + }), + ) - if len(withdrawalAddressesToCheck) == 0 { - log.Println("No EigenValidators were slashed.") - return map[string][]ValidatorWithIndex{}, nil - } + // fmt.Printf("Checking %d slashed withdrawal addresses for eigenpod status\n", len(allSlashedWithdrawalAddresses)) - allSlashedValidatorsBelongingToEigenpods := utils.Filter(allSlashedValidators, func(validator ValidatorWithIndex) bool { - podAddr := *executionWithdrawalAddress(validator.Validator.WithdrawalCredentials) - isPod, err := isEigenpod(eth, chainId.Uint64(), podAddr) - if err != nil { - if verbose { - if !strings.Contains(err.Error(), "no contract code at given address") { - log.Printf("error checking whether contract(%s) was eigenpod: %s\n", podAddr, err.Error()) - } - } - return false - } else if verbose && isPod { - log.Printf("Detected slashed pod: %s", podAddr) - } - return isPod - }) + slashedEigenpods, err := validEigenpodsOnly(allSlashedWithdrawalAddresses, mc, chainId.Uint64(), eth) - allValidatorInfo := make(map[uint64]onchain.IEigenPodValidatorInfo) - for _, validator := range allSlashedValidatorsBelongingToEigenpods { - eigenpodAddress := *executionWithdrawalAddress(validator.Validator.WithdrawalCredentials) - pod, err := onchain.NewEigenPod(common.HexToAddress(eigenpodAddress), eth) - if err != nil { - // failed to load validator info. - return map[string][]ValidatorWithIndex{}, fmt.Errorf("failed to dial eigenpod: %s", err.Error()) - } - - info, err := pod.ValidatorPubkeyToInfo(nil, validator.Validator.PublicKey[:]) - if err != nil { - // failed to load validator info. - return map[string][]ValidatorWithIndex{}, err - } - allValidatorInfo[validator.Index] = info - } - - allActiveSlashedValidatorsBelongingToEigenpods := utils.Filter(allSlashedValidatorsBelongingToEigenpods, func(validator ValidatorWithIndex) bool { - validatorInfo := allValidatorInfo[validator.Index] - return validatorInfo.Status == 1 // "ACTIVE" - }) - - if verbose { - log.Printf("%d EigenValidators have been slashed\n", len(allSlashedValidatorsBelongingToEigenpods)) - log.Printf("%d EigenValidators have been slashed + active\n", len(allActiveSlashedValidatorsBelongingToEigenpods)) - } - - slashedEigenpods := utils.Reduce(allActiveSlashedValidatorsBelongingToEigenpods, func(pods map[string][]ValidatorWithIndex, validator ValidatorWithIndex) map[string][]ValidatorWithIndex { - podAddress := executionWithdrawalAddress(validator.Validator.WithdrawalCredentials) - if podAddress != nil { - if pods[*podAddress] == nil { - pods[*podAddress] = []ValidatorWithIndex{} - } - pods[*podAddress] = append(pods[*podAddress], validator) - } - return pods - }, map[string][]ValidatorWithIndex{}) - - allValidatorBalances, err := beaconState.ValidatorBalances() - if err != nil { - return nil, err + if len(slashedEigenpods) == 0 { + log.Println("No eigenpods were slashed.") + return map[string][]ValidatorWithIndex{}, nil } - totalAssetsWeiByEigenpod := utils.Reduce(keys(slashedEigenpods), func(allBalances map[string]*big.Int, eigenpod string) map[string]*big.Int { - // total assets of an eigenpod are determined as; - // SUM( - // - native ETH in the pod - // - any active validators and their associated balances - // ) - validatorsForEigenpod := utils.Filter(allValidatorsWithIndices, func(v ValidatorWithIndex) bool { - withdrawal := executionWithdrawalAddress(v.Validator.WithdrawalCredentials) - return withdrawal != nil && strings.EqualFold(*withdrawal, eigenpod) - }) - - podValidatorInfo, err := FetchMultipleOnchainValidatorInfo(ctx, eth, eigenpod, validatorsForEigenpod) - if err != nil { - return allBalances - } - - allActiveValidatorsForEigenpod := utils.Filter(podValidatorInfo, func(v ValidatorWithOnchainInfo) bool { - if v.Info.Status != 1 { // ignore any inactive validators - return false - } - - withdrawal := executionWithdrawalAddress(v.Validator.WithdrawalCredentials) - return withdrawal != nil && strings.EqualFold(*withdrawal, eigenpod) - }) - - allActiveValidatorBalancesSummedGwei := utils.Reduce(allActiveValidatorsForEigenpod, func(accum phase0.Gwei, validator ValidatorWithOnchainInfo) phase0.Gwei { - return accum + allValidatorBalances[validator.Index] - }, phase0.Gwei(0)) - activeValidatorBalancesSum := new(big.Int).Mul( - new(big.Int).SetUint64(uint64(allActiveValidatorBalancesSummedGwei)), - new(big.Int).SetUint64(params.GWei), - ) - - if verbose { - log.Printf("[%s] podOwnerShares(%sETH), anticipated balance = beacon(%s across %d validators) + executionBalance(%sETH)\n", - eigenpod, - IweiToEther(cache.PodOwnerShares[eigenpod].SharesWei).String(), - IweiToEther(activeValidatorBalancesSum).String(), - len(allActiveValidatorsForEigenpod), - IweiToEther(cache.PodOwnerShares[eigenpod].ExecutionLayerBalanceWei).String(), - ) // converting gwei to wei - } - - allBalances[eigenpod] = new(big.Int).Add(cache.PodOwnerShares[eigenpod].ExecutionLayerBalanceWei, activeValidatorBalancesSum) - return allBalances - }, map[string]*big.Int{}) + // 2. given the set of slashed eigenpods, determine which are unhealthy. if verbose { log.Printf("%d EigenPods were slashed\n", len(slashedEigenpods)) } - unhealthyEigenpods := utils.Filter(keys(slashedEigenpods), func(eigenpod string) bool { - currentTotalAssets, ok := totalAssetsWeiByEigenpod[eigenpod] - if !ok { - return false - } - currentShares := cache.PodOwnerShares[eigenpod].SharesWei - - delta := new(big.Int).Sub(currentShares, currentTotalAssets) - allowableDelta := FracMul(currentShares, big.NewInt(int64(tolerance)), big.NewInt(100)) - if delta.Cmp(allowableDelta) >= 0 { - if verbose { - log.Printf("[%s] %sETH drop in assets (max drop allowed: %sETH, current shares: %sETH, anticipated shares: %sETH)\n", - eigenpod, - IweiToEther(delta).String(), - IweiToEther(allowableDelta).String(), - IweiToEther(currentShares).String(), - IweiToEther(currentTotalAssets).String(), - ) - } - return true - } + unhealthyEigenpods := utils.Filter(slashedEigenpods, func(eigenpod common.Address) bool { + deviation, err := ComputeBalanceDeviationSync(ctx, eth, beaconState, eigenpod) + PanicOnError("failed to compute balance deviation for eigenpod", err) - return false + return deviation.Cmp(big.NewFloat(tolerance)) > 0 }) if len(unhealthyEigenpods) == 0 { @@ -319,7 +288,10 @@ func FindStaleEigenpods(ctx context.Context, eth *ethclient.Client, nodeUrl stri var entries map[string][]ValidatorWithIndex = make(map[string][]ValidatorWithIndex) for _, val := range unhealthyEigenpods { - entries[val] = slashedEigenpods[val] + entries[val.Hex()] = utils.Filter(allValidatorsWithIndices, func(v ValidatorWithIndex) bool { + execAddr := executionWithdrawalAddress(v.Validator.WithdrawalCredentials) + return execAddr != nil && common.HexToAddress(*execAddr).Cmp(val) == 0 + }) } return entries, nil diff --git a/cli/core/multicall/multicall.go b/cli/core/multicall/multicall.go deleted file mode 100644 index 27e96833..00000000 --- a/cli/core/multicall/multicall.go +++ /dev/null @@ -1,295 +0,0 @@ -package multicall - -import ( - "context" - "errors" - "fmt" - "math" - "strings" - - "github.com/Layr-Labs/eigenpod-proofs-generation/cli/utils" - "github.com/ethereum/go-ethereum/accounts/abi" - "github.com/ethereum/go-ethereum/accounts/abi/bind" - "github.com/ethereum/go-ethereum/common" - "github.com/ethereum/go-ethereum/ethclient" -) - -type MultiCallMetaData[T interface{}] struct { - Address common.Address - Data []byte - FunctionName string - Deserialize func([]byte) (T, error) -} - -type Multicall3Result struct { - Success bool - ReturnData []byte -} - -type TypedMulticall3Result[A any] struct { - Success bool - Value A - Error error -} - -type DeserializedMulticall3Result struct { - Success bool - Value any -} - -func (md *MultiCallMetaData[T]) Raw() RawMulticall { - return RawMulticall{ - Address: md.Address, - Data: md.Data, - FunctionName: md.FunctionName, - Deserialize: func(data []byte) (any, error) { - res, err := md.Deserialize(data) - return any(res), err - }, - } -} - -type RawMulticall struct { - Address common.Address - Data []byte - FunctionName string - Deserialize func([]byte) (any, error) -} - -type MulticallClient struct { - Contract *bind.BoundContract - ABI *abi.ABI - Context context.Context - MaxBatchSize uint64 - OverrideCallOptions *bind.CallOpts -} - -type ParamMulticall3Call3 struct { - Target common.Address - AllowFailure bool - CallData []byte -} - -type TMulticallClientOptions struct { - OverrideContractAddress *common.Address - MaxBatchSizeBytes uint64 - OverrideCallOptions *bind.CallOpts -} - -// maxBatchSizeBytes - 0: no batching. -func NewMulticallClient(ctx context.Context, eth *ethclient.Client, options *TMulticallClientOptions) (*MulticallClient, error) { - if eth == nil { - return nil, errors.New("no ethclient passed") - } - - // taken from: https://www.multicall3.com/ - parsed, err := abi.JSON(strings.NewReader(`[{"inputs":[{"components":[{"internalType":"address","name":"target","type":"address"},{"internalType":"bytes","name":"callData","type":"bytes"}],"internalType":"struct Multicall3.Call[]","name":"calls","type":"tuple[]"}],"name":"aggregate","outputs":[{"internalType":"uint256","name":"blockNumber","type":"uint256"},{"internalType":"bytes[]","name":"returnData","type":"bytes[]"}],"stateMutability":"payable","type":"function"},{"inputs":[{"components":[{"internalType":"address","name":"target","type":"address"},{"internalType":"bool","name":"allowFailure","type":"bool"},{"internalType":"bytes","name":"callData","type":"bytes"}],"internalType":"struct Multicall3.Call3[]","name":"calls","type":"tuple[]"}],"name":"aggregate3","outputs":[{"components":[{"internalType":"bool","name":"success","type":"bool"},{"internalType":"bytes","name":"returnData","type":"bytes"}],"internalType":"struct Multicall3.Result[]","name":"returnData","type":"tuple[]"}],"stateMutability":"payable","type":"function"},{"inputs":[{"components":[{"internalType":"address","name":"target","type":"address"},{"internalType":"bool","name":"allowFailure","type":"bool"},{"internalType":"uint256","name":"value","type":"uint256"},{"internalType":"bytes","name":"callData","type":"bytes"}],"internalType":"struct Multicall3.Call3Value[]","name":"calls","type":"tuple[]"}],"name":"aggregate3Value","outputs":[{"components":[{"internalType":"bool","name":"success","type":"bool"},{"internalType":"bytes","name":"returnData","type":"bytes"}],"internalType":"struct Multicall3.Result[]","name":"returnData","type":"tuple[]"}],"stateMutability":"payable","type":"function"},{"inputs":[{"components":[{"internalType":"address","name":"target","type":"address"},{"internalType":"bytes","name":"callData","type":"bytes"}],"internalType":"struct Multicall3.Call[]","name":"calls","type":"tuple[]"}],"name":"blockAndAggregate","outputs":[{"internalType":"uint256","name":"blockNumber","type":"uint256"},{"internalType":"bytes32","name":"blockHash","type":"bytes32"},{"components":[{"internalType":"bool","name":"success","type":"bool"},{"internalType":"bytes","name":"returnData","type":"bytes"}],"internalType":"struct Multicall3.Result[]","name":"returnData","type":"tuple[]"}],"stateMutability":"payable","type":"function"},{"inputs":[],"name":"getBasefee","outputs":[{"internalType":"uint256","name":"basefee","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"blockNumber","type":"uint256"}],"name":"getBlockHash","outputs":[{"internalType":"bytes32","name":"blockHash","type":"bytes32"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"getBlockNumber","outputs":[{"internalType":"uint256","name":"blockNumber","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"getChainId","outputs":[{"internalType":"uint256","name":"chainid","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"getCurrentBlockCoinbase","outputs":[{"internalType":"address","name":"coinbase","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"getCurrentBlockDifficulty","outputs":[{"internalType":"uint256","name":"difficulty","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"getCurrentBlockGasLimit","outputs":[{"internalType":"uint256","name":"gaslimit","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"getCurrentBlockTimestamp","outputs":[{"internalType":"uint256","name":"timestamp","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"addr","type":"address"}],"name":"getEthBalance","outputs":[{"internalType":"uint256","name":"balance","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"getLastBlockHash","outputs":[{"internalType":"bytes32","name":"blockHash","type":"bytes32"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"bool","name":"requireSuccess","type":"bool"},{"components":[{"internalType":"address","name":"target","type":"address"},{"internalType":"bytes","name":"callData","type":"bytes"}],"internalType":"struct Multicall3.Call[]","name":"calls","type":"tuple[]"}],"name":"tryAggregate","outputs":[{"components":[{"internalType":"bool","name":"success","type":"bool"},{"internalType":"bytes","name":"returnData","type":"bytes"}],"internalType":"struct Multicall3.Result[]","name":"returnData","type":"tuple[]"}],"stateMutability":"payable","type":"function"},{"inputs":[{"internalType":"bool","name":"requireSuccess","type":"bool"},{"components":[{"internalType":"address","name":"target","type":"address"},{"internalType":"bytes","name":"callData","type":"bytes"}],"internalType":"struct Multicall3.Call[]","name":"calls","type":"tuple[]"}],"name":"tryBlockAndAggregate","outputs":[{"internalType":"uint256","name":"blockNumber","type":"uint256"},{"internalType":"bytes32","name":"blockHash","type":"bytes32"},{"components":[{"internalType":"bool","name":"success","type":"bool"},{"internalType":"bytes","name":"returnData","type":"bytes"}],"internalType":"struct Multicall3.Result[]","name":"returnData","type":"tuple[]"}],"stateMutability":"payable","type":"function"}]`)) - if err != nil { - return nil, fmt.Errorf("error parsing multicall abi: %s", err.Error()) - } - - contractAddress := func() common.Address { - if options == nil || options.OverrideContractAddress == nil { - // also taken from: https://www.multicall3.com/ -- it's deployed at the same addr on most chains - return common.HexToAddress("0xcA11bde05977b3631167028862bE2a173976CA11") - } - return *options.OverrideContractAddress - }() - - maxBatchSize := func() uint64 { - if options == nil || options.MaxBatchSizeBytes == 0 { - return math.MaxUint64 - } else { - return options.MaxBatchSizeBytes - } - }() - - callOptions := func() *bind.CallOpts { - if options != nil { - return options.OverrideCallOptions - } - return nil - }() - - return &MulticallClient{OverrideCallOptions: callOptions, MaxBatchSize: maxBatchSize, Context: ctx, ABI: &parsed, Contract: bind.NewBoundContract(contractAddress, parsed, eth, eth, eth)}, nil -} - -// Call invokes the (constant) contract method with params as input values and -// sets the output to result. The result type might be a single field for simple -// returns, a slice of interfaces for anonymous returns and a struct for named -// returns. -func MultiCall[T any](contractAddress common.Address, abi abi.ABI, deserialize func([]byte) (T, error), method string, params ...interface{}) (*MultiCallMetaData[T], error) { - callData, err := abi.Pack(method, params...) - if err != nil { - return nil, fmt.Errorf("error packing multicall: %s", err.Error()) - } - return &MultiCallMetaData[T]{ - Address: contractAddress, - Data: callData, - FunctionName: method, - Deserialize: deserialize, - }, nil -} - -func DoMultiCall[A any, B any](mc MulticallClient, a *MultiCallMetaData[A], b *MultiCallMetaData[B]) (*A, *B, error) { - res, err := doMultiCallMany(mc, a.Raw(), b.Raw()) - if err != nil { - return nil, nil, fmt.Errorf("error performing multicall: %s", err.Error()) - } - return any(res[0].Value).(*A), any(res[1].Value).(*B), nil -} - -func DoMultiCallMany[A any](mc MulticallClient, requests ...*MultiCallMetaData[A]) (*[]A, error) { - res, err := doMultiCallMany(mc, utils.Map(requests, func(mc *MultiCallMetaData[A], index uint64) RawMulticall { - return mc.Raw() - })...) - if err != nil { - return nil, fmt.Errorf("multicall failed: %s", err.Error()) - } - - anyFailures := utils.Filter(res, func(cur DeserializedMulticall3Result) bool { - return !cur.Success - }) - if len(anyFailures) > 0 { - return nil, errors.New("1 or more calls failed") - } - - // unwind results - unwoundResults := utils.Map(res, func(d DeserializedMulticall3Result, i uint64) A { - // force these back to A - if !d.Success { - panic(errors.New("unexpected multicall failure")) - } - return any(d.Value).(A) - }) - return &unwoundResults, nil -} - -func DoMultiCallManyReportingFailures[A any](mc MulticallClient, requests ...*MultiCallMetaData[A]) (*[]TypedMulticall3Result[A], error) { - res, err := doMultiCallMany(mc, utils.Map(requests, func(mc *MultiCallMetaData[A], index uint64) RawMulticall { - return mc.Raw() - })...) - if err != nil { - return nil, fmt.Errorf("multicall failed: %s", err.Error()) - } - - // unwind results - unwoundResults := utils.Map(res, func(d DeserializedMulticall3Result, i uint64) TypedMulticall3Result[A] { - val, ok := any(d.Value).(A) - if !ok { - return TypedMulticall3Result[A]{ - Value: val, - Success: false, - } - } - - return TypedMulticall3Result[A]{ - Value: val, - Success: d.Success, - } - }) - return &unwoundResults, nil -} - -/* - * Some RPC providers may limit the amount of calldata you can send in one eth_call, which (for those who have 1000's of validators), means - * you can't just spam one enormous multicall request. - * - * This function checks whether the calldata appended exceeds maxBatchSizeBytes - */ -func chunkCalls(allCalls []ParamMulticall3Call3, maxBatchSizeBytes int) [][]ParamMulticall3Call3 { - // chunk by the maximum size of calldata, which is 1024 per call. - results := [][]ParamMulticall3Call3{} - currentBatchSize := 0 - currentBatch := []ParamMulticall3Call3{} - - for _, call := range allCalls { - if (currentBatchSize + len(call.CallData)) > maxBatchSizeBytes { - // we can't fit in this batch, so dump the current batch and start a new one - results = append(results, currentBatch) - currentBatchSize = 0 - currentBatch = []ParamMulticall3Call3{} - } - - currentBatch = append(currentBatch, call) - currentBatchSize += len(call.CallData) - } - - // check if we forgot to add the last batch - if len(currentBatch) > 0 { - results = append(results, currentBatch) - } - - return results -} - -func doMultiCallMany(mc MulticallClient, calls ...RawMulticall) ([]DeserializedMulticall3Result, error) { - typedCalls := make([]ParamMulticall3Call3, len(calls)) - for i, call := range calls { - typedCalls[i] = ParamMulticall3Call3{ - Target: call.Address, - AllowFailure: true, - CallData: call.Data, - } - } - - // see if we need to chunk them now - chunkedCalls := chunkCalls(typedCalls, func() int { - if mc.MaxBatchSize == 0 { - return math.MaxInt64 - } else { - return int(mc.MaxBatchSize) - } - }()) - var results = make([]interface{}, len(calls)) - var totalResults = 0 - - chunkNumber := 1 - for _, multicalls := range chunkedCalls { - var res []interface{} - chunkNumber++ - err := mc.Contract.Call(mc.OverrideCallOptions, &res, "aggregate3", multicalls) - if err != nil { - return nil, fmt.Errorf("aggregate3 failed: %s", err) - } - - multicallResults := *abi.ConvertType(res[0], new([]Multicall3Result)).(*[]Multicall3Result) - for i := 0; i < len(multicallResults); i++ { - results[totalResults+i] = multicallResults[i] - } - totalResults += len(multicallResults) - } - - outputs := make([]DeserializedMulticall3Result, len(calls)) - for i, call := range calls { - res := results[i].(Multicall3Result) - if res.Success { - if res.ReturnData != nil { - val, err := call.Deserialize(res.ReturnData) - if err != nil { - outputs[i] = DeserializedMulticall3Result{ - Value: err, - Success: false, - } - } else { - outputs[i] = DeserializedMulticall3Result{ - Value: val, - Success: res.Success, - } - } - } else { - outputs[i] = DeserializedMulticall3Result{ - Value: errors.New("no data returned"), - Success: false, - } - } - } else { - outputs[i] = DeserializedMulticall3Result{ - Success: false, - Value: errors.New("call failed"), - } - } - } - - return outputs, nil -} diff --git a/cli/core/onchain/EigenPod.go b/cli/core/onchain/EigenPod.go deleted file mode 100644 index 87f51385..00000000 --- a/cli/core/onchain/EigenPod.go +++ /dev/null @@ -1,2485 +0,0 @@ -// Code generated - DO NOT EDIT. -// This file is a generated binding and any manual changes will be lost. - -package onchain - -import ( - "errors" - "math/big" - "strings" - - ethereum "github.com/ethereum/go-ethereum" - "github.com/ethereum/go-ethereum/accounts/abi" - "github.com/ethereum/go-ethereum/accounts/abi/bind" - "github.com/ethereum/go-ethereum/common" - "github.com/ethereum/go-ethereum/core/types" - "github.com/ethereum/go-ethereum/event" -) - -// Reference imports to suppress errors if they are not otherwise used. -var ( - _ = errors.New - _ = big.NewInt - _ = strings.NewReader - _ = ethereum.NotFound - _ = bind.Bind - _ = common.Big1 - _ = types.BloomLookup - _ = event.NewSubscription - _ = abi.ConvertType -) - -// BeaconChainProofsBalanceContainerProof is an auto generated low-level Go binding around an user-defined struct. -type BeaconChainProofsBalanceContainerProof struct { - BalanceContainerRoot [32]byte - Proof []byte -} - -// BeaconChainProofsBalanceProof is an auto generated low-level Go binding around an user-defined struct. -type BeaconChainProofsBalanceProof struct { - PubkeyHash [32]byte - BalanceRoot [32]byte - Proof []byte -} - -// BeaconChainProofsStateRootProof is an auto generated low-level Go binding around an user-defined struct. -type BeaconChainProofsStateRootProof struct { - BeaconStateRoot [32]byte - Proof []byte -} - -// BeaconChainProofsValidatorProof is an auto generated low-level Go binding around an user-defined struct. -type BeaconChainProofsValidatorProof struct { - ValidatorFields [][32]byte - Proof []byte -} - -// IEigenPodCheckpoint is an auto generated low-level Go binding around an user-defined struct. -type IEigenPodCheckpoint struct { - BeaconBlockRoot [32]byte - ProofsRemaining *big.Int - PodBalanceGwei uint64 - BalanceDeltasGwei *big.Int -} - -// IEigenPodValidatorInfo is an auto generated low-level Go binding around an user-defined struct. -type IEigenPodValidatorInfo struct { - ValidatorIndex uint64 - RestakedBalanceGwei uint64 - LastCheckpointedAt uint64 - Status uint8 -} - -// EigenPodMetaData contains all meta data concerning the EigenPod contract. -var EigenPodMetaData = &bind.MetaData{ - ABI: "[{\"type\":\"constructor\",\"inputs\":[{\"name\":\"_ethPOS\",\"type\":\"address\",\"internalType\":\"contractIETHPOSDeposit\"},{\"name\":\"_eigenPodManager\",\"type\":\"address\",\"internalType\":\"contractIEigenPodManager\"},{\"name\":\"_GENESIS_TIME\",\"type\":\"uint64\",\"internalType\":\"uint64\"}],\"stateMutability\":\"nonpayable\"},{\"type\":\"receive\",\"stateMutability\":\"payable\"},{\"type\":\"function\",\"name\":\"GENESIS_TIME\",\"inputs\":[],\"outputs\":[{\"name\":\"\",\"type\":\"uint64\",\"internalType\":\"uint64\"}],\"stateMutability\":\"view\"},{\"type\":\"function\",\"name\":\"activeValidatorCount\",\"inputs\":[],\"outputs\":[{\"name\":\"\",\"type\":\"uint256\",\"internalType\":\"uint256\"}],\"stateMutability\":\"view\"},{\"type\":\"function\",\"name\":\"checkpointBalanceExitedGwei\",\"inputs\":[{\"name\":\"\",\"type\":\"uint64\",\"internalType\":\"uint64\"}],\"outputs\":[{\"name\":\"\",\"type\":\"uint64\",\"internalType\":\"uint64\"}],\"stateMutability\":\"view\"},{\"type\":\"function\",\"name\":\"currentCheckpoint\",\"inputs\":[],\"outputs\":[{\"name\":\"\",\"type\":\"tuple\",\"internalType\":\"structIEigenPod.Checkpoint\",\"components\":[{\"name\":\"beaconBlockRoot\",\"type\":\"bytes32\",\"internalType\":\"bytes32\"},{\"name\":\"proofsRemaining\",\"type\":\"uint24\",\"internalType\":\"uint24\"},{\"name\":\"podBalanceGwei\",\"type\":\"uint64\",\"internalType\":\"uint64\"},{\"name\":\"balanceDeltasGwei\",\"type\":\"int128\",\"internalType\":\"int128\"}]}],\"stateMutability\":\"view\"},{\"type\":\"function\",\"name\":\"currentCheckpointTimestamp\",\"inputs\":[],\"outputs\":[{\"name\":\"\",\"type\":\"uint64\",\"internalType\":\"uint64\"}],\"stateMutability\":\"view\"},{\"type\":\"function\",\"name\":\"eigenPodManager\",\"inputs\":[],\"outputs\":[{\"name\":\"\",\"type\":\"address\",\"internalType\":\"contractIEigenPodManager\"}],\"stateMutability\":\"view\"},{\"type\":\"function\",\"name\":\"ethPOS\",\"inputs\":[],\"outputs\":[{\"name\":\"\",\"type\":\"address\",\"internalType\":\"contractIETHPOSDeposit\"}],\"stateMutability\":\"view\"},{\"type\":\"function\",\"name\":\"getParentBlockRoot\",\"inputs\":[{\"name\":\"timestamp\",\"type\":\"uint64\",\"internalType\":\"uint64\"}],\"outputs\":[{\"name\":\"\",\"type\":\"bytes32\",\"internalType\":\"bytes32\"}],\"stateMutability\":\"view\"},{\"type\":\"function\",\"name\":\"initialize\",\"inputs\":[{\"name\":\"_podOwner\",\"type\":\"address\",\"internalType\":\"address\"}],\"outputs\":[],\"stateMutability\":\"nonpayable\"},{\"type\":\"function\",\"name\":\"lastCheckpointTimestamp\",\"inputs\":[],\"outputs\":[{\"name\":\"\",\"type\":\"uint64\",\"internalType\":\"uint64\"}],\"stateMutability\":\"view\"},{\"type\":\"function\",\"name\":\"podOwner\",\"inputs\":[],\"outputs\":[{\"name\":\"\",\"type\":\"address\",\"internalType\":\"address\"}],\"stateMutability\":\"view\"},{\"type\":\"function\",\"name\":\"proofSubmitter\",\"inputs\":[],\"outputs\":[{\"name\":\"\",\"type\":\"address\",\"internalType\":\"address\"}],\"stateMutability\":\"view\"},{\"type\":\"function\",\"name\":\"recoverTokens\",\"inputs\":[{\"name\":\"tokenList\",\"type\":\"address[]\",\"internalType\":\"contractIERC20[]\"},{\"name\":\"amountsToWithdraw\",\"type\":\"uint256[]\",\"internalType\":\"uint256[]\"},{\"name\":\"recipient\",\"type\":\"address\",\"internalType\":\"address\"}],\"outputs\":[],\"stateMutability\":\"nonpayable\"},{\"type\":\"function\",\"name\":\"setProofSubmitter\",\"inputs\":[{\"name\":\"newProofSubmitter\",\"type\":\"address\",\"internalType\":\"address\"}],\"outputs\":[],\"stateMutability\":\"nonpayable\"},{\"type\":\"function\",\"name\":\"stake\",\"inputs\":[{\"name\":\"pubkey\",\"type\":\"bytes\",\"internalType\":\"bytes\"},{\"name\":\"signature\",\"type\":\"bytes\",\"internalType\":\"bytes\"},{\"name\":\"depositDataRoot\",\"type\":\"bytes32\",\"internalType\":\"bytes32\"}],\"outputs\":[],\"stateMutability\":\"payable\"},{\"type\":\"function\",\"name\":\"startCheckpoint\",\"inputs\":[{\"name\":\"revertIfNoBalance\",\"type\":\"bool\",\"internalType\":\"bool\"}],\"outputs\":[],\"stateMutability\":\"nonpayable\"},{\"type\":\"function\",\"name\":\"validatorPubkeyHashToInfo\",\"inputs\":[{\"name\":\"validatorPubkeyHash\",\"type\":\"bytes32\",\"internalType\":\"bytes32\"}],\"outputs\":[{\"name\":\"\",\"type\":\"tuple\",\"internalType\":\"structIEigenPod.ValidatorInfo\",\"components\":[{\"name\":\"validatorIndex\",\"type\":\"uint64\",\"internalType\":\"uint64\"},{\"name\":\"restakedBalanceGwei\",\"type\":\"uint64\",\"internalType\":\"uint64\"},{\"name\":\"lastCheckpointedAt\",\"type\":\"uint64\",\"internalType\":\"uint64\"},{\"name\":\"status\",\"type\":\"uint8\",\"internalType\":\"enumIEigenPod.VALIDATOR_STATUS\"}]}],\"stateMutability\":\"view\"},{\"type\":\"function\",\"name\":\"validatorPubkeyToInfo\",\"inputs\":[{\"name\":\"validatorPubkey\",\"type\":\"bytes\",\"internalType\":\"bytes\"}],\"outputs\":[{\"name\":\"\",\"type\":\"tuple\",\"internalType\":\"structIEigenPod.ValidatorInfo\",\"components\":[{\"name\":\"validatorIndex\",\"type\":\"uint64\",\"internalType\":\"uint64\"},{\"name\":\"restakedBalanceGwei\",\"type\":\"uint64\",\"internalType\":\"uint64\"},{\"name\":\"lastCheckpointedAt\",\"type\":\"uint64\",\"internalType\":\"uint64\"},{\"name\":\"status\",\"type\":\"uint8\",\"internalType\":\"enumIEigenPod.VALIDATOR_STATUS\"}]}],\"stateMutability\":\"view\"},{\"type\":\"function\",\"name\":\"validatorStatus\",\"inputs\":[{\"name\":\"validatorPubkey\",\"type\":\"bytes\",\"internalType\":\"bytes\"}],\"outputs\":[{\"name\":\"\",\"type\":\"uint8\",\"internalType\":\"enumIEigenPod.VALIDATOR_STATUS\"}],\"stateMutability\":\"view\"},{\"type\":\"function\",\"name\":\"validatorStatus\",\"inputs\":[{\"name\":\"pubkeyHash\",\"type\":\"bytes32\",\"internalType\":\"bytes32\"}],\"outputs\":[{\"name\":\"\",\"type\":\"uint8\",\"internalType\":\"enumIEigenPod.VALIDATOR_STATUS\"}],\"stateMutability\":\"view\"},{\"type\":\"function\",\"name\":\"verifyCheckpointProofs\",\"inputs\":[{\"name\":\"balanceContainerProof\",\"type\":\"tuple\",\"internalType\":\"structBeaconChainProofs.BalanceContainerProof\",\"components\":[{\"name\":\"balanceContainerRoot\",\"type\":\"bytes32\",\"internalType\":\"bytes32\"},{\"name\":\"proof\",\"type\":\"bytes\",\"internalType\":\"bytes\"}]},{\"name\":\"proofs\",\"type\":\"tuple[]\",\"internalType\":\"structBeaconChainProofs.BalanceProof[]\",\"components\":[{\"name\":\"pubkeyHash\",\"type\":\"bytes32\",\"internalType\":\"bytes32\"},{\"name\":\"balanceRoot\",\"type\":\"bytes32\",\"internalType\":\"bytes32\"},{\"name\":\"proof\",\"type\":\"bytes\",\"internalType\":\"bytes\"}]}],\"outputs\":[],\"stateMutability\":\"nonpayable\"},{\"type\":\"function\",\"name\":\"verifyStaleBalance\",\"inputs\":[{\"name\":\"beaconTimestamp\",\"type\":\"uint64\",\"internalType\":\"uint64\"},{\"name\":\"stateRootProof\",\"type\":\"tuple\",\"internalType\":\"structBeaconChainProofs.StateRootProof\",\"components\":[{\"name\":\"beaconStateRoot\",\"type\":\"bytes32\",\"internalType\":\"bytes32\"},{\"name\":\"proof\",\"type\":\"bytes\",\"internalType\":\"bytes\"}]},{\"name\":\"proof\",\"type\":\"tuple\",\"internalType\":\"structBeaconChainProofs.ValidatorProof\",\"components\":[{\"name\":\"validatorFields\",\"type\":\"bytes32[]\",\"internalType\":\"bytes32[]\"},{\"name\":\"proof\",\"type\":\"bytes\",\"internalType\":\"bytes\"}]}],\"outputs\":[],\"stateMutability\":\"nonpayable\"},{\"type\":\"function\",\"name\":\"verifyWithdrawalCredentials\",\"inputs\":[{\"name\":\"beaconTimestamp\",\"type\":\"uint64\",\"internalType\":\"uint64\"},{\"name\":\"stateRootProof\",\"type\":\"tuple\",\"internalType\":\"structBeaconChainProofs.StateRootProof\",\"components\":[{\"name\":\"beaconStateRoot\",\"type\":\"bytes32\",\"internalType\":\"bytes32\"},{\"name\":\"proof\",\"type\":\"bytes\",\"internalType\":\"bytes\"}]},{\"name\":\"validatorIndices\",\"type\":\"uint40[]\",\"internalType\":\"uint40[]\"},{\"name\":\"validatorFieldsProofs\",\"type\":\"bytes[]\",\"internalType\":\"bytes[]\"},{\"name\":\"validatorFields\",\"type\":\"bytes32[][]\",\"internalType\":\"bytes32[][]\"}],\"outputs\":[],\"stateMutability\":\"nonpayable\"},{\"type\":\"function\",\"name\":\"withdrawRestakedBeaconChainETH\",\"inputs\":[{\"name\":\"recipient\",\"type\":\"address\",\"internalType\":\"address\"},{\"name\":\"amountWei\",\"type\":\"uint256\",\"internalType\":\"uint256\"}],\"outputs\":[],\"stateMutability\":\"nonpayable\"},{\"type\":\"function\",\"name\":\"withdrawableRestakedExecutionLayerGwei\",\"inputs\":[],\"outputs\":[{\"name\":\"\",\"type\":\"uint64\",\"internalType\":\"uint64\"}],\"stateMutability\":\"view\"},{\"type\":\"event\",\"name\":\"CheckpointCreated\",\"inputs\":[{\"name\":\"checkpointTimestamp\",\"type\":\"uint64\",\"indexed\":true,\"internalType\":\"uint64\"},{\"name\":\"beaconBlockRoot\",\"type\":\"bytes32\",\"indexed\":true,\"internalType\":\"bytes32\"},{\"name\":\"validatorCount\",\"type\":\"uint256\",\"indexed\":false,\"internalType\":\"uint256\"}],\"anonymous\":false},{\"type\":\"event\",\"name\":\"CheckpointFinalized\",\"inputs\":[{\"name\":\"checkpointTimestamp\",\"type\":\"uint64\",\"indexed\":true,\"internalType\":\"uint64\"},{\"name\":\"totalShareDeltaWei\",\"type\":\"int256\",\"indexed\":false,\"internalType\":\"int256\"}],\"anonymous\":false},{\"type\":\"event\",\"name\":\"EigenPodStaked\",\"inputs\":[{\"name\":\"pubkey\",\"type\":\"bytes\",\"indexed\":false,\"internalType\":\"bytes\"}],\"anonymous\":false},{\"type\":\"event\",\"name\":\"Initialized\",\"inputs\":[{\"name\":\"version\",\"type\":\"uint8\",\"indexed\":false,\"internalType\":\"uint8\"}],\"anonymous\":false},{\"type\":\"event\",\"name\":\"NonBeaconChainETHReceived\",\"inputs\":[{\"name\":\"amountReceived\",\"type\":\"uint256\",\"indexed\":false,\"internalType\":\"uint256\"}],\"anonymous\":false},{\"type\":\"event\",\"name\":\"ProofSubmitterUpdated\",\"inputs\":[{\"name\":\"prevProofSubmitter\",\"type\":\"address\",\"indexed\":false,\"internalType\":\"address\"},{\"name\":\"newProofSubmitter\",\"type\":\"address\",\"indexed\":false,\"internalType\":\"address\"}],\"anonymous\":false},{\"type\":\"event\",\"name\":\"RestakedBeaconChainETHWithdrawn\",\"inputs\":[{\"name\":\"recipient\",\"type\":\"address\",\"indexed\":true,\"internalType\":\"address\"},{\"name\":\"amount\",\"type\":\"uint256\",\"indexed\":false,\"internalType\":\"uint256\"}],\"anonymous\":false},{\"type\":\"event\",\"name\":\"ValidatorBalanceUpdated\",\"inputs\":[{\"name\":\"validatorIndex\",\"type\":\"uint40\",\"indexed\":false,\"internalType\":\"uint40\"},{\"name\":\"balanceTimestamp\",\"type\":\"uint64\",\"indexed\":false,\"internalType\":\"uint64\"},{\"name\":\"newValidatorBalanceGwei\",\"type\":\"uint64\",\"indexed\":false,\"internalType\":\"uint64\"}],\"anonymous\":false},{\"type\":\"event\",\"name\":\"ValidatorCheckpointed\",\"inputs\":[{\"name\":\"checkpointTimestamp\",\"type\":\"uint64\",\"indexed\":true,\"internalType\":\"uint64\"},{\"name\":\"validatorIndex\",\"type\":\"uint40\",\"indexed\":true,\"internalType\":\"uint40\"}],\"anonymous\":false},{\"type\":\"event\",\"name\":\"ValidatorRestaked\",\"inputs\":[{\"name\":\"validatorIndex\",\"type\":\"uint40\",\"indexed\":false,\"internalType\":\"uint40\"}],\"anonymous\":false},{\"type\":\"event\",\"name\":\"ValidatorWithdrawn\",\"inputs\":[{\"name\":\"checkpointTimestamp\",\"type\":\"uint64\",\"indexed\":true,\"internalType\":\"uint64\"},{\"name\":\"validatorIndex\",\"type\":\"uint40\",\"indexed\":true,\"internalType\":\"uint40\"}],\"anonymous\":false}]", -} - -// EigenPodABI is the input ABI used to generate the binding from. -// Deprecated: Use EigenPodMetaData.ABI instead. -var EigenPodABI = EigenPodMetaData.ABI - -// EigenPod is an auto generated Go binding around an Ethereum contract. -type EigenPod struct { - EigenPodCaller // Read-only binding to the contract - EigenPodTransactor // Write-only binding to the contract - EigenPodFilterer // Log filterer for contract events -} - -// EigenPodCaller is an auto generated read-only Go binding around an Ethereum contract. -type EigenPodCaller struct { - contract *bind.BoundContract // Generic contract wrapper for the low level calls -} - -// EigenPodTransactor is an auto generated write-only Go binding around an Ethereum contract. -type EigenPodTransactor struct { - contract *bind.BoundContract // Generic contract wrapper for the low level calls -} - -// EigenPodFilterer is an auto generated log filtering Go binding around an Ethereum contract events. -type EigenPodFilterer struct { - contract *bind.BoundContract // Generic contract wrapper for the low level calls -} - -// EigenPodSession is an auto generated Go binding around an Ethereum contract, -// with pre-set call and transact options. -type EigenPodSession struct { - Contract *EigenPod // Generic contract binding to set the session for - CallOpts bind.CallOpts // Call options to use throughout this session - TransactOpts bind.TransactOpts // Transaction auth options to use throughout this session -} - -// EigenPodCallerSession is an auto generated read-only Go binding around an Ethereum contract, -// with pre-set call options. -type EigenPodCallerSession struct { - Contract *EigenPodCaller // Generic contract caller binding to set the session for - CallOpts bind.CallOpts // Call options to use throughout this session -} - -// EigenPodTransactorSession is an auto generated write-only Go binding around an Ethereum contract, -// with pre-set transact options. -type EigenPodTransactorSession struct { - Contract *EigenPodTransactor // Generic contract transactor binding to set the session for - TransactOpts bind.TransactOpts // Transaction auth options to use throughout this session -} - -// EigenPodRaw is an auto generated low-level Go binding around an Ethereum contract. -type EigenPodRaw struct { - Contract *EigenPod // Generic contract binding to access the raw methods on -} - -// EigenPodCallerRaw is an auto generated low-level read-only Go binding around an Ethereum contract. -type EigenPodCallerRaw struct { - Contract *EigenPodCaller // Generic read-only contract binding to access the raw methods on -} - -// EigenPodTransactorRaw is an auto generated low-level write-only Go binding around an Ethereum contract. -type EigenPodTransactorRaw struct { - Contract *EigenPodTransactor // Generic write-only contract binding to access the raw methods on -} - -// NewEigenPod creates a new instance of EigenPod, bound to a specific deployed contract. -func NewEigenPod(address common.Address, backend bind.ContractBackend) (*EigenPod, error) { - contract, err := bindEigenPod(address, backend, backend, backend) - if err != nil { - return nil, err - } - return &EigenPod{EigenPodCaller: EigenPodCaller{contract: contract}, EigenPodTransactor: EigenPodTransactor{contract: contract}, EigenPodFilterer: EigenPodFilterer{contract: contract}}, nil -} - -// NewEigenPodCaller creates a new read-only instance of EigenPod, bound to a specific deployed contract. -func NewEigenPodCaller(address common.Address, caller bind.ContractCaller) (*EigenPodCaller, error) { - contract, err := bindEigenPod(address, caller, nil, nil) - if err != nil { - return nil, err - } - return &EigenPodCaller{contract: contract}, nil -} - -// NewEigenPodTransactor creates a new write-only instance of EigenPod, bound to a specific deployed contract. -func NewEigenPodTransactor(address common.Address, transactor bind.ContractTransactor) (*EigenPodTransactor, error) { - contract, err := bindEigenPod(address, nil, transactor, nil) - if err != nil { - return nil, err - } - return &EigenPodTransactor{contract: contract}, nil -} - -// NewEigenPodFilterer creates a new log filterer instance of EigenPod, bound to a specific deployed contract. -func NewEigenPodFilterer(address common.Address, filterer bind.ContractFilterer) (*EigenPodFilterer, error) { - contract, err := bindEigenPod(address, nil, nil, filterer) - if err != nil { - return nil, err - } - return &EigenPodFilterer{contract: contract}, nil -} - -// bindEigenPod binds a generic wrapper to an already deployed contract. -func bindEigenPod(address common.Address, caller bind.ContractCaller, transactor bind.ContractTransactor, filterer bind.ContractFilterer) (*bind.BoundContract, error) { - parsed, err := EigenPodMetaData.GetAbi() - if err != nil { - return nil, err - } - return bind.NewBoundContract(address, *parsed, caller, transactor, filterer), nil -} - -// Call invokes the (constant) contract method with params as input values and -// sets the output to result. The result type might be a single field for simple -// returns, a slice of interfaces for anonymous returns and a struct for named -// returns. -func (_EigenPod *EigenPodRaw) Call(opts *bind.CallOpts, result *[]interface{}, method string, params ...interface{}) error { - return _EigenPod.Contract.EigenPodCaller.contract.Call(opts, result, method, params...) -} - -// Transfer initiates a plain transaction to move funds to the contract, calling -// its default method if one is available. -func (_EigenPod *EigenPodRaw) Transfer(opts *bind.TransactOpts) (*types.Transaction, error) { - return _EigenPod.Contract.EigenPodTransactor.contract.Transfer(opts) -} - -// Transact invokes the (paid) contract method with params as input values. -func (_EigenPod *EigenPodRaw) Transact(opts *bind.TransactOpts, method string, params ...interface{}) (*types.Transaction, error) { - return _EigenPod.Contract.EigenPodTransactor.contract.Transact(opts, method, params...) -} - -// Call invokes the (constant) contract method with params as input values and -// sets the output to result. The result type might be a single field for simple -// returns, a slice of interfaces for anonymous returns and a struct for named -// returns. -func (_EigenPod *EigenPodCallerRaw) Call(opts *bind.CallOpts, result *[]interface{}, method string, params ...interface{}) error { - return _EigenPod.Contract.contract.Call(opts, result, method, params...) -} - -// Transfer initiates a plain transaction to move funds to the contract, calling -// its default method if one is available. -func (_EigenPod *EigenPodTransactorRaw) Transfer(opts *bind.TransactOpts) (*types.Transaction, error) { - return _EigenPod.Contract.contract.Transfer(opts) -} - -// Transact invokes the (paid) contract method with params as input values. -func (_EigenPod *EigenPodTransactorRaw) Transact(opts *bind.TransactOpts, method string, params ...interface{}) (*types.Transaction, error) { - return _EigenPod.Contract.contract.Transact(opts, method, params...) -} - -// GENESISTIME is a free data retrieval call binding the contract method 0xf2882461. -// -// Solidity: function GENESIS_TIME() view returns(uint64) -func (_EigenPod *EigenPodCaller) GENESISTIME(opts *bind.CallOpts) (uint64, error) { - var out []interface{} - err := _EigenPod.contract.Call(opts, &out, "GENESIS_TIME") - - if err != nil { - return *new(uint64), err - } - - out0 := *abi.ConvertType(out[0], new(uint64)).(*uint64) - - return out0, err - -} - -// GENESISTIME is a free data retrieval call binding the contract method 0xf2882461. -// -// Solidity: function GENESIS_TIME() view returns(uint64) -func (_EigenPod *EigenPodSession) GENESISTIME() (uint64, error) { - return _EigenPod.Contract.GENESISTIME(&_EigenPod.CallOpts) -} - -// GENESISTIME is a free data retrieval call binding the contract method 0xf2882461. -// -// Solidity: function GENESIS_TIME() view returns(uint64) -func (_EigenPod *EigenPodCallerSession) GENESISTIME() (uint64, error) { - return _EigenPod.Contract.GENESISTIME(&_EigenPod.CallOpts) -} - -// ActiveValidatorCount is a free data retrieval call binding the contract method 0x2340e8d3. -// -// Solidity: function activeValidatorCount() view returns(uint256) -func (_EigenPod *EigenPodCaller) ActiveValidatorCount(opts *bind.CallOpts) (*big.Int, error) { - var out []interface{} - err := _EigenPod.contract.Call(opts, &out, "activeValidatorCount") - - if err != nil { - return *new(*big.Int), err - } - - out0 := *abi.ConvertType(out[0], new(*big.Int)).(**big.Int) - - return out0, err - -} - -// ActiveValidatorCount is a free data retrieval call binding the contract method 0x2340e8d3. -// -// Solidity: function activeValidatorCount() view returns(uint256) -func (_EigenPod *EigenPodSession) ActiveValidatorCount() (*big.Int, error) { - return _EigenPod.Contract.ActiveValidatorCount(&_EigenPod.CallOpts) -} - -// ActiveValidatorCount is a free data retrieval call binding the contract method 0x2340e8d3. -// -// Solidity: function activeValidatorCount() view returns(uint256) -func (_EigenPod *EigenPodCallerSession) ActiveValidatorCount() (*big.Int, error) { - return _EigenPod.Contract.ActiveValidatorCount(&_EigenPod.CallOpts) -} - -// CheckpointBalanceExitedGwei is a free data retrieval call binding the contract method 0x52396a59. -// -// Solidity: function checkpointBalanceExitedGwei(uint64 ) view returns(uint64) -func (_EigenPod *EigenPodCaller) CheckpointBalanceExitedGwei(opts *bind.CallOpts, arg0 uint64) (uint64, error) { - var out []interface{} - err := _EigenPod.contract.Call(opts, &out, "checkpointBalanceExitedGwei", arg0) - - if err != nil { - return *new(uint64), err - } - - out0 := *abi.ConvertType(out[0], new(uint64)).(*uint64) - - return out0, err - -} - -// CheckpointBalanceExitedGwei is a free data retrieval call binding the contract method 0x52396a59. -// -// Solidity: function checkpointBalanceExitedGwei(uint64 ) view returns(uint64) -func (_EigenPod *EigenPodSession) CheckpointBalanceExitedGwei(arg0 uint64) (uint64, error) { - return _EigenPod.Contract.CheckpointBalanceExitedGwei(&_EigenPod.CallOpts, arg0) -} - -// CheckpointBalanceExitedGwei is a free data retrieval call binding the contract method 0x52396a59. -// -// Solidity: function checkpointBalanceExitedGwei(uint64 ) view returns(uint64) -func (_EigenPod *EigenPodCallerSession) CheckpointBalanceExitedGwei(arg0 uint64) (uint64, error) { - return _EigenPod.Contract.CheckpointBalanceExitedGwei(&_EigenPod.CallOpts, arg0) -} - -// CurrentCheckpoint is a free data retrieval call binding the contract method 0x47d28372. -// -// Solidity: function currentCheckpoint() view returns((bytes32,uint24,uint64,int128)) -func (_EigenPod *EigenPodCaller) CurrentCheckpoint(opts *bind.CallOpts) (IEigenPodCheckpoint, error) { - var out []interface{} - err := _EigenPod.contract.Call(opts, &out, "currentCheckpoint") - - if err != nil { - return *new(IEigenPodCheckpoint), err - } - - out0 := *abi.ConvertType(out[0], new(IEigenPodCheckpoint)).(*IEigenPodCheckpoint) - - return out0, err - -} - -// CurrentCheckpoint is a free data retrieval call binding the contract method 0x47d28372. -// -// Solidity: function currentCheckpoint() view returns((bytes32,uint24,uint64,int128)) -func (_EigenPod *EigenPodSession) CurrentCheckpoint() (IEigenPodCheckpoint, error) { - return _EigenPod.Contract.CurrentCheckpoint(&_EigenPod.CallOpts) -} - -// CurrentCheckpoint is a free data retrieval call binding the contract method 0x47d28372. -// -// Solidity: function currentCheckpoint() view returns((bytes32,uint24,uint64,int128)) -func (_EigenPod *EigenPodCallerSession) CurrentCheckpoint() (IEigenPodCheckpoint, error) { - return _EigenPod.Contract.CurrentCheckpoint(&_EigenPod.CallOpts) -} - -// CurrentCheckpointTimestamp is a free data retrieval call binding the contract method 0x42ecff2a. -// -// Solidity: function currentCheckpointTimestamp() view returns(uint64) -func (_EigenPod *EigenPodCaller) CurrentCheckpointTimestamp(opts *bind.CallOpts) (uint64, error) { - var out []interface{} - err := _EigenPod.contract.Call(opts, &out, "currentCheckpointTimestamp") - - if err != nil { - return *new(uint64), err - } - - out0 := *abi.ConvertType(out[0], new(uint64)).(*uint64) - - return out0, err - -} - -// CurrentCheckpointTimestamp is a free data retrieval call binding the contract method 0x42ecff2a. -// -// Solidity: function currentCheckpointTimestamp() view returns(uint64) -func (_EigenPod *EigenPodSession) CurrentCheckpointTimestamp() (uint64, error) { - return _EigenPod.Contract.CurrentCheckpointTimestamp(&_EigenPod.CallOpts) -} - -// CurrentCheckpointTimestamp is a free data retrieval call binding the contract method 0x42ecff2a. -// -// Solidity: function currentCheckpointTimestamp() view returns(uint64) -func (_EigenPod *EigenPodCallerSession) CurrentCheckpointTimestamp() (uint64, error) { - return _EigenPod.Contract.CurrentCheckpointTimestamp(&_EigenPod.CallOpts) -} - -// EigenPodManager is a free data retrieval call binding the contract method 0x4665bcda. -// -// Solidity: function eigenPodManager() view returns(address) -func (_EigenPod *EigenPodCaller) EigenPodManager(opts *bind.CallOpts) (common.Address, error) { - var out []interface{} - err := _EigenPod.contract.Call(opts, &out, "eigenPodManager") - - if err != nil { - return *new(common.Address), err - } - - out0 := *abi.ConvertType(out[0], new(common.Address)).(*common.Address) - - return out0, err - -} - -// EigenPodManager is a free data retrieval call binding the contract method 0x4665bcda. -// -// Solidity: function eigenPodManager() view returns(address) -func (_EigenPod *EigenPodSession) EigenPodManager() (common.Address, error) { - return _EigenPod.Contract.EigenPodManager(&_EigenPod.CallOpts) -} - -// EigenPodManager is a free data retrieval call binding the contract method 0x4665bcda. -// -// Solidity: function eigenPodManager() view returns(address) -func (_EigenPod *EigenPodCallerSession) EigenPodManager() (common.Address, error) { - return _EigenPod.Contract.EigenPodManager(&_EigenPod.CallOpts) -} - -// EthPOS is a free data retrieval call binding the contract method 0x74cdd798. -// -// Solidity: function ethPOS() view returns(address) -func (_EigenPod *EigenPodCaller) EthPOS(opts *bind.CallOpts) (common.Address, error) { - var out []interface{} - err := _EigenPod.contract.Call(opts, &out, "ethPOS") - - if err != nil { - return *new(common.Address), err - } - - out0 := *abi.ConvertType(out[0], new(common.Address)).(*common.Address) - - return out0, err - -} - -// EthPOS is a free data retrieval call binding the contract method 0x74cdd798. -// -// Solidity: function ethPOS() view returns(address) -func (_EigenPod *EigenPodSession) EthPOS() (common.Address, error) { - return _EigenPod.Contract.EthPOS(&_EigenPod.CallOpts) -} - -// EthPOS is a free data retrieval call binding the contract method 0x74cdd798. -// -// Solidity: function ethPOS() view returns(address) -func (_EigenPod *EigenPodCallerSession) EthPOS() (common.Address, error) { - return _EigenPod.Contract.EthPOS(&_EigenPod.CallOpts) -} - -// GetParentBlockRoot is a free data retrieval call binding the contract method 0x6c0d2d5a. -// -// Solidity: function getParentBlockRoot(uint64 timestamp) view returns(bytes32) -func (_EigenPod *EigenPodCaller) GetParentBlockRoot(opts *bind.CallOpts, timestamp uint64) ([32]byte, error) { - var out []interface{} - err := _EigenPod.contract.Call(opts, &out, "getParentBlockRoot", timestamp) - - if err != nil { - return *new([32]byte), err - } - - out0 := *abi.ConvertType(out[0], new([32]byte)).(*[32]byte) - - return out0, err - -} - -// GetParentBlockRoot is a free data retrieval call binding the contract method 0x6c0d2d5a. -// -// Solidity: function getParentBlockRoot(uint64 timestamp) view returns(bytes32) -func (_EigenPod *EigenPodSession) GetParentBlockRoot(timestamp uint64) ([32]byte, error) { - return _EigenPod.Contract.GetParentBlockRoot(&_EigenPod.CallOpts, timestamp) -} - -// GetParentBlockRoot is a free data retrieval call binding the contract method 0x6c0d2d5a. -// -// Solidity: function getParentBlockRoot(uint64 timestamp) view returns(bytes32) -func (_EigenPod *EigenPodCallerSession) GetParentBlockRoot(timestamp uint64) ([32]byte, error) { - return _EigenPod.Contract.GetParentBlockRoot(&_EigenPod.CallOpts, timestamp) -} - -// LastCheckpointTimestamp is a free data retrieval call binding the contract method 0xee94d67c. -// -// Solidity: function lastCheckpointTimestamp() view returns(uint64) -func (_EigenPod *EigenPodCaller) LastCheckpointTimestamp(opts *bind.CallOpts) (uint64, error) { - var out []interface{} - err := _EigenPod.contract.Call(opts, &out, "lastCheckpointTimestamp") - - if err != nil { - return *new(uint64), err - } - - out0 := *abi.ConvertType(out[0], new(uint64)).(*uint64) - - return out0, err - -} - -// LastCheckpointTimestamp is a free data retrieval call binding the contract method 0xee94d67c. -// -// Solidity: function lastCheckpointTimestamp() view returns(uint64) -func (_EigenPod *EigenPodSession) LastCheckpointTimestamp() (uint64, error) { - return _EigenPod.Contract.LastCheckpointTimestamp(&_EigenPod.CallOpts) -} - -// LastCheckpointTimestamp is a free data retrieval call binding the contract method 0xee94d67c. -// -// Solidity: function lastCheckpointTimestamp() view returns(uint64) -func (_EigenPod *EigenPodCallerSession) LastCheckpointTimestamp() (uint64, error) { - return _EigenPod.Contract.LastCheckpointTimestamp(&_EigenPod.CallOpts) -} - -// PodOwner is a free data retrieval call binding the contract method 0x0b18ff66. -// -// Solidity: function podOwner() view returns(address) -func (_EigenPod *EigenPodCaller) PodOwner(opts *bind.CallOpts) (common.Address, error) { - var out []interface{} - err := _EigenPod.contract.Call(opts, &out, "podOwner") - - if err != nil { - return *new(common.Address), err - } - - out0 := *abi.ConvertType(out[0], new(common.Address)).(*common.Address) - - return out0, err - -} - -// PodOwner is a free data retrieval call binding the contract method 0x0b18ff66. -// -// Solidity: function podOwner() view returns(address) -func (_EigenPod *EigenPodSession) PodOwner() (common.Address, error) { - return _EigenPod.Contract.PodOwner(&_EigenPod.CallOpts) -} - -// PodOwner is a free data retrieval call binding the contract method 0x0b18ff66. -// -// Solidity: function podOwner() view returns(address) -func (_EigenPod *EigenPodCallerSession) PodOwner() (common.Address, error) { - return _EigenPod.Contract.PodOwner(&_EigenPod.CallOpts) -} - -// ProofSubmitter is a free data retrieval call binding the contract method 0x58753357. -// -// Solidity: function proofSubmitter() view returns(address) -func (_EigenPod *EigenPodCaller) ProofSubmitter(opts *bind.CallOpts) (common.Address, error) { - var out []interface{} - err := _EigenPod.contract.Call(opts, &out, "proofSubmitter") - - if err != nil { - return *new(common.Address), err - } - - out0 := *abi.ConvertType(out[0], new(common.Address)).(*common.Address) - - return out0, err - -} - -// ProofSubmitter is a free data retrieval call binding the contract method 0x58753357. -// -// Solidity: function proofSubmitter() view returns(address) -func (_EigenPod *EigenPodSession) ProofSubmitter() (common.Address, error) { - return _EigenPod.Contract.ProofSubmitter(&_EigenPod.CallOpts) -} - -// ProofSubmitter is a free data retrieval call binding the contract method 0x58753357. -// -// Solidity: function proofSubmitter() view returns(address) -func (_EigenPod *EigenPodCallerSession) ProofSubmitter() (common.Address, error) { - return _EigenPod.Contract.ProofSubmitter(&_EigenPod.CallOpts) -} - -// ValidatorPubkeyHashToInfo is a free data retrieval call binding the contract method 0x6fcd0e53. -// -// Solidity: function validatorPubkeyHashToInfo(bytes32 validatorPubkeyHash) view returns((uint64,uint64,uint64,uint8)) -func (_EigenPod *EigenPodCaller) ValidatorPubkeyHashToInfo(opts *bind.CallOpts, validatorPubkeyHash [32]byte) (IEigenPodValidatorInfo, error) { - var out []interface{} - err := _EigenPod.contract.Call(opts, &out, "validatorPubkeyHashToInfo", validatorPubkeyHash) - - if err != nil { - return *new(IEigenPodValidatorInfo), err - } - - out0 := *abi.ConvertType(out[0], new(IEigenPodValidatorInfo)).(*IEigenPodValidatorInfo) - - return out0, err - -} - -// ValidatorPubkeyHashToInfo is a free data retrieval call binding the contract method 0x6fcd0e53. -// -// Solidity: function validatorPubkeyHashToInfo(bytes32 validatorPubkeyHash) view returns((uint64,uint64,uint64,uint8)) -func (_EigenPod *EigenPodSession) ValidatorPubkeyHashToInfo(validatorPubkeyHash [32]byte) (IEigenPodValidatorInfo, error) { - return _EigenPod.Contract.ValidatorPubkeyHashToInfo(&_EigenPod.CallOpts, validatorPubkeyHash) -} - -// ValidatorPubkeyHashToInfo is a free data retrieval call binding the contract method 0x6fcd0e53. -// -// Solidity: function validatorPubkeyHashToInfo(bytes32 validatorPubkeyHash) view returns((uint64,uint64,uint64,uint8)) -func (_EigenPod *EigenPodCallerSession) ValidatorPubkeyHashToInfo(validatorPubkeyHash [32]byte) (IEigenPodValidatorInfo, error) { - return _EigenPod.Contract.ValidatorPubkeyHashToInfo(&_EigenPod.CallOpts, validatorPubkeyHash) -} - -// ValidatorPubkeyToInfo is a free data retrieval call binding the contract method 0xb522538a. -// -// Solidity: function validatorPubkeyToInfo(bytes validatorPubkey) view returns((uint64,uint64,uint64,uint8)) -func (_EigenPod *EigenPodCaller) ValidatorPubkeyToInfo(opts *bind.CallOpts, validatorPubkey []byte) (IEigenPodValidatorInfo, error) { - var out []interface{} - err := _EigenPod.contract.Call(opts, &out, "validatorPubkeyToInfo", validatorPubkey) - - if err != nil { - return *new(IEigenPodValidatorInfo), err - } - - out0 := *abi.ConvertType(out[0], new(IEigenPodValidatorInfo)).(*IEigenPodValidatorInfo) - - return out0, err - -} - -// ValidatorPubkeyToInfo is a free data retrieval call binding the contract method 0xb522538a. -// -// Solidity: function validatorPubkeyToInfo(bytes validatorPubkey) view returns((uint64,uint64,uint64,uint8)) -func (_EigenPod *EigenPodSession) ValidatorPubkeyToInfo(validatorPubkey []byte) (IEigenPodValidatorInfo, error) { - return _EigenPod.Contract.ValidatorPubkeyToInfo(&_EigenPod.CallOpts, validatorPubkey) -} - -// ValidatorPubkeyToInfo is a free data retrieval call binding the contract method 0xb522538a. -// -// Solidity: function validatorPubkeyToInfo(bytes validatorPubkey) view returns((uint64,uint64,uint64,uint8)) -func (_EigenPod *EigenPodCallerSession) ValidatorPubkeyToInfo(validatorPubkey []byte) (IEigenPodValidatorInfo, error) { - return _EigenPod.Contract.ValidatorPubkeyToInfo(&_EigenPod.CallOpts, validatorPubkey) -} - -// ValidatorStatus is a free data retrieval call binding the contract method 0x58eaee79. -// -// Solidity: function validatorStatus(bytes validatorPubkey) view returns(uint8) -func (_EigenPod *EigenPodCaller) ValidatorStatus(opts *bind.CallOpts, validatorPubkey []byte) (uint8, error) { - var out []interface{} - err := _EigenPod.contract.Call(opts, &out, "validatorStatus", validatorPubkey) - - if err != nil { - return *new(uint8), err - } - - out0 := *abi.ConvertType(out[0], new(uint8)).(*uint8) - - return out0, err - -} - -// ValidatorStatus is a free data retrieval call binding the contract method 0x58eaee79. -// -// Solidity: function validatorStatus(bytes validatorPubkey) view returns(uint8) -func (_EigenPod *EigenPodSession) ValidatorStatus(validatorPubkey []byte) (uint8, error) { - return _EigenPod.Contract.ValidatorStatus(&_EigenPod.CallOpts, validatorPubkey) -} - -// ValidatorStatus is a free data retrieval call binding the contract method 0x58eaee79. -// -// Solidity: function validatorStatus(bytes validatorPubkey) view returns(uint8) -func (_EigenPod *EigenPodCallerSession) ValidatorStatus(validatorPubkey []byte) (uint8, error) { - return _EigenPod.Contract.ValidatorStatus(&_EigenPod.CallOpts, validatorPubkey) -} - -// ValidatorStatus0 is a free data retrieval call binding the contract method 0x7439841f. -// -// Solidity: function validatorStatus(bytes32 pubkeyHash) view returns(uint8) -func (_EigenPod *EigenPodCaller) ValidatorStatus0(opts *bind.CallOpts, pubkeyHash [32]byte) (uint8, error) { - var out []interface{} - err := _EigenPod.contract.Call(opts, &out, "validatorStatus0", pubkeyHash) - - if err != nil { - return *new(uint8), err - } - - out0 := *abi.ConvertType(out[0], new(uint8)).(*uint8) - - return out0, err - -} - -// ValidatorStatus0 is a free data retrieval call binding the contract method 0x7439841f. -// -// Solidity: function validatorStatus(bytes32 pubkeyHash) view returns(uint8) -func (_EigenPod *EigenPodSession) ValidatorStatus0(pubkeyHash [32]byte) (uint8, error) { - return _EigenPod.Contract.ValidatorStatus0(&_EigenPod.CallOpts, pubkeyHash) -} - -// ValidatorStatus0 is a free data retrieval call binding the contract method 0x7439841f. -// -// Solidity: function validatorStatus(bytes32 pubkeyHash) view returns(uint8) -func (_EigenPod *EigenPodCallerSession) ValidatorStatus0(pubkeyHash [32]byte) (uint8, error) { - return _EigenPod.Contract.ValidatorStatus0(&_EigenPod.CallOpts, pubkeyHash) -} - -// WithdrawableRestakedExecutionLayerGwei is a free data retrieval call binding the contract method 0x3474aa16. -// -// Solidity: function withdrawableRestakedExecutionLayerGwei() view returns(uint64) -func (_EigenPod *EigenPodCaller) WithdrawableRestakedExecutionLayerGwei(opts *bind.CallOpts) (uint64, error) { - var out []interface{} - err := _EigenPod.contract.Call(opts, &out, "withdrawableRestakedExecutionLayerGwei") - - if err != nil { - return *new(uint64), err - } - - out0 := *abi.ConvertType(out[0], new(uint64)).(*uint64) - - return out0, err - -} - -// WithdrawableRestakedExecutionLayerGwei is a free data retrieval call binding the contract method 0x3474aa16. -// -// Solidity: function withdrawableRestakedExecutionLayerGwei() view returns(uint64) -func (_EigenPod *EigenPodSession) WithdrawableRestakedExecutionLayerGwei() (uint64, error) { - return _EigenPod.Contract.WithdrawableRestakedExecutionLayerGwei(&_EigenPod.CallOpts) -} - -// WithdrawableRestakedExecutionLayerGwei is a free data retrieval call binding the contract method 0x3474aa16. -// -// Solidity: function withdrawableRestakedExecutionLayerGwei() view returns(uint64) -func (_EigenPod *EigenPodCallerSession) WithdrawableRestakedExecutionLayerGwei() (uint64, error) { - return _EigenPod.Contract.WithdrawableRestakedExecutionLayerGwei(&_EigenPod.CallOpts) -} - -// Initialize is a paid mutator transaction binding the contract method 0xc4d66de8. -// -// Solidity: function initialize(address _podOwner) returns() -func (_EigenPod *EigenPodTransactor) Initialize(opts *bind.TransactOpts, _podOwner common.Address) (*types.Transaction, error) { - return _EigenPod.contract.Transact(opts, "initialize", _podOwner) -} - -// Initialize is a paid mutator transaction binding the contract method 0xc4d66de8. -// -// Solidity: function initialize(address _podOwner) returns() -func (_EigenPod *EigenPodSession) Initialize(_podOwner common.Address) (*types.Transaction, error) { - return _EigenPod.Contract.Initialize(&_EigenPod.TransactOpts, _podOwner) -} - -// Initialize is a paid mutator transaction binding the contract method 0xc4d66de8. -// -// Solidity: function initialize(address _podOwner) returns() -func (_EigenPod *EigenPodTransactorSession) Initialize(_podOwner common.Address) (*types.Transaction, error) { - return _EigenPod.Contract.Initialize(&_EigenPod.TransactOpts, _podOwner) -} - -// RecoverTokens is a paid mutator transaction binding the contract method 0xdda3346c. -// -// Solidity: function recoverTokens(address[] tokenList, uint256[] amountsToWithdraw, address recipient) returns() -func (_EigenPod *EigenPodTransactor) RecoverTokens(opts *bind.TransactOpts, tokenList []common.Address, amountsToWithdraw []*big.Int, recipient common.Address) (*types.Transaction, error) { - return _EigenPod.contract.Transact(opts, "recoverTokens", tokenList, amountsToWithdraw, recipient) -} - -// RecoverTokens is a paid mutator transaction binding the contract method 0xdda3346c. -// -// Solidity: function recoverTokens(address[] tokenList, uint256[] amountsToWithdraw, address recipient) returns() -func (_EigenPod *EigenPodSession) RecoverTokens(tokenList []common.Address, amountsToWithdraw []*big.Int, recipient common.Address) (*types.Transaction, error) { - return _EigenPod.Contract.RecoverTokens(&_EigenPod.TransactOpts, tokenList, amountsToWithdraw, recipient) -} - -// RecoverTokens is a paid mutator transaction binding the contract method 0xdda3346c. -// -// Solidity: function recoverTokens(address[] tokenList, uint256[] amountsToWithdraw, address recipient) returns() -func (_EigenPod *EigenPodTransactorSession) RecoverTokens(tokenList []common.Address, amountsToWithdraw []*big.Int, recipient common.Address) (*types.Transaction, error) { - return _EigenPod.Contract.RecoverTokens(&_EigenPod.TransactOpts, tokenList, amountsToWithdraw, recipient) -} - -// SetProofSubmitter is a paid mutator transaction binding the contract method 0xd06d5587. -// -// Solidity: function setProofSubmitter(address newProofSubmitter) returns() -func (_EigenPod *EigenPodTransactor) SetProofSubmitter(opts *bind.TransactOpts, newProofSubmitter common.Address) (*types.Transaction, error) { - return _EigenPod.contract.Transact(opts, "setProofSubmitter", newProofSubmitter) -} - -// SetProofSubmitter is a paid mutator transaction binding the contract method 0xd06d5587. -// -// Solidity: function setProofSubmitter(address newProofSubmitter) returns() -func (_EigenPod *EigenPodSession) SetProofSubmitter(newProofSubmitter common.Address) (*types.Transaction, error) { - return _EigenPod.Contract.SetProofSubmitter(&_EigenPod.TransactOpts, newProofSubmitter) -} - -// SetProofSubmitter is a paid mutator transaction binding the contract method 0xd06d5587. -// -// Solidity: function setProofSubmitter(address newProofSubmitter) returns() -func (_EigenPod *EigenPodTransactorSession) SetProofSubmitter(newProofSubmitter common.Address) (*types.Transaction, error) { - return _EigenPod.Contract.SetProofSubmitter(&_EigenPod.TransactOpts, newProofSubmitter) -} - -// Stake is a paid mutator transaction binding the contract method 0x9b4e4634. -// -// Solidity: function stake(bytes pubkey, bytes signature, bytes32 depositDataRoot) payable returns() -func (_EigenPod *EigenPodTransactor) Stake(opts *bind.TransactOpts, pubkey []byte, signature []byte, depositDataRoot [32]byte) (*types.Transaction, error) { - return _EigenPod.contract.Transact(opts, "stake", pubkey, signature, depositDataRoot) -} - -// Stake is a paid mutator transaction binding the contract method 0x9b4e4634. -// -// Solidity: function stake(bytes pubkey, bytes signature, bytes32 depositDataRoot) payable returns() -func (_EigenPod *EigenPodSession) Stake(pubkey []byte, signature []byte, depositDataRoot [32]byte) (*types.Transaction, error) { - return _EigenPod.Contract.Stake(&_EigenPod.TransactOpts, pubkey, signature, depositDataRoot) -} - -// Stake is a paid mutator transaction binding the contract method 0x9b4e4634. -// -// Solidity: function stake(bytes pubkey, bytes signature, bytes32 depositDataRoot) payable returns() -func (_EigenPod *EigenPodTransactorSession) Stake(pubkey []byte, signature []byte, depositDataRoot [32]byte) (*types.Transaction, error) { - return _EigenPod.Contract.Stake(&_EigenPod.TransactOpts, pubkey, signature, depositDataRoot) -} - -// StartCheckpoint is a paid mutator transaction binding the contract method 0x88676cad. -// -// Solidity: function startCheckpoint(bool revertIfNoBalance) returns() -func (_EigenPod *EigenPodTransactor) StartCheckpoint(opts *bind.TransactOpts, revertIfNoBalance bool) (*types.Transaction, error) { - return _EigenPod.contract.Transact(opts, "startCheckpoint", revertIfNoBalance) -} - -// StartCheckpoint is a paid mutator transaction binding the contract method 0x88676cad. -// -// Solidity: function startCheckpoint(bool revertIfNoBalance) returns() -func (_EigenPod *EigenPodSession) StartCheckpoint(revertIfNoBalance bool) (*types.Transaction, error) { - return _EigenPod.Contract.StartCheckpoint(&_EigenPod.TransactOpts, revertIfNoBalance) -} - -// StartCheckpoint is a paid mutator transaction binding the contract method 0x88676cad. -// -// Solidity: function startCheckpoint(bool revertIfNoBalance) returns() -func (_EigenPod *EigenPodTransactorSession) StartCheckpoint(revertIfNoBalance bool) (*types.Transaction, error) { - return _EigenPod.Contract.StartCheckpoint(&_EigenPod.TransactOpts, revertIfNoBalance) -} - -// VerifyCheckpointProofs is a paid mutator transaction binding the contract method 0xf074ba62. -// -// Solidity: function verifyCheckpointProofs((bytes32,bytes) balanceContainerProof, (bytes32,bytes32,bytes)[] proofs) returns() -func (_EigenPod *EigenPodTransactor) VerifyCheckpointProofs(opts *bind.TransactOpts, balanceContainerProof BeaconChainProofsBalanceContainerProof, proofs []BeaconChainProofsBalanceProof) (*types.Transaction, error) { - return _EigenPod.contract.Transact(opts, "verifyCheckpointProofs", balanceContainerProof, proofs) -} - -// VerifyCheckpointProofs is a paid mutator transaction binding the contract method 0xf074ba62. -// -// Solidity: function verifyCheckpointProofs((bytes32,bytes) balanceContainerProof, (bytes32,bytes32,bytes)[] proofs) returns() -func (_EigenPod *EigenPodSession) VerifyCheckpointProofs(balanceContainerProof BeaconChainProofsBalanceContainerProof, proofs []BeaconChainProofsBalanceProof) (*types.Transaction, error) { - return _EigenPod.Contract.VerifyCheckpointProofs(&_EigenPod.TransactOpts, balanceContainerProof, proofs) -} - -// VerifyCheckpointProofs is a paid mutator transaction binding the contract method 0xf074ba62. -// -// Solidity: function verifyCheckpointProofs((bytes32,bytes) balanceContainerProof, (bytes32,bytes32,bytes)[] proofs) returns() -func (_EigenPod *EigenPodTransactorSession) VerifyCheckpointProofs(balanceContainerProof BeaconChainProofsBalanceContainerProof, proofs []BeaconChainProofsBalanceProof) (*types.Transaction, error) { - return _EigenPod.Contract.VerifyCheckpointProofs(&_EigenPod.TransactOpts, balanceContainerProof, proofs) -} - -// VerifyStaleBalance is a paid mutator transaction binding the contract method 0x039157d2. -// -// Solidity: function verifyStaleBalance(uint64 beaconTimestamp, (bytes32,bytes) stateRootProof, (bytes32[],bytes) proof) returns() -func (_EigenPod *EigenPodTransactor) VerifyStaleBalance(opts *bind.TransactOpts, beaconTimestamp uint64, stateRootProof BeaconChainProofsStateRootProof, proof BeaconChainProofsValidatorProof) (*types.Transaction, error) { - return _EigenPod.contract.Transact(opts, "verifyStaleBalance", beaconTimestamp, stateRootProof, proof) -} - -// VerifyStaleBalance is a paid mutator transaction binding the contract method 0x039157d2. -// -// Solidity: function verifyStaleBalance(uint64 beaconTimestamp, (bytes32,bytes) stateRootProof, (bytes32[],bytes) proof) returns() -func (_EigenPod *EigenPodSession) VerifyStaleBalance(beaconTimestamp uint64, stateRootProof BeaconChainProofsStateRootProof, proof BeaconChainProofsValidatorProof) (*types.Transaction, error) { - return _EigenPod.Contract.VerifyStaleBalance(&_EigenPod.TransactOpts, beaconTimestamp, stateRootProof, proof) -} - -// VerifyStaleBalance is a paid mutator transaction binding the contract method 0x039157d2. -// -// Solidity: function verifyStaleBalance(uint64 beaconTimestamp, (bytes32,bytes) stateRootProof, (bytes32[],bytes) proof) returns() -func (_EigenPod *EigenPodTransactorSession) VerifyStaleBalance(beaconTimestamp uint64, stateRootProof BeaconChainProofsStateRootProof, proof BeaconChainProofsValidatorProof) (*types.Transaction, error) { - return _EigenPod.Contract.VerifyStaleBalance(&_EigenPod.TransactOpts, beaconTimestamp, stateRootProof, proof) -} - -// VerifyWithdrawalCredentials is a paid mutator transaction binding the contract method 0x3f65cf19. -// -// Solidity: function verifyWithdrawalCredentials(uint64 beaconTimestamp, (bytes32,bytes) stateRootProof, uint40[] validatorIndices, bytes[] validatorFieldsProofs, bytes32[][] validatorFields) returns() -func (_EigenPod *EigenPodTransactor) VerifyWithdrawalCredentials(opts *bind.TransactOpts, beaconTimestamp uint64, stateRootProof BeaconChainProofsStateRootProof, validatorIndices []*big.Int, validatorFieldsProofs [][]byte, validatorFields [][][32]byte) (*types.Transaction, error) { - return _EigenPod.contract.Transact(opts, "verifyWithdrawalCredentials", beaconTimestamp, stateRootProof, validatorIndices, validatorFieldsProofs, validatorFields) -} - -// VerifyWithdrawalCredentials is a paid mutator transaction binding the contract method 0x3f65cf19. -// -// Solidity: function verifyWithdrawalCredentials(uint64 beaconTimestamp, (bytes32,bytes) stateRootProof, uint40[] validatorIndices, bytes[] validatorFieldsProofs, bytes32[][] validatorFields) returns() -func (_EigenPod *EigenPodSession) VerifyWithdrawalCredentials(beaconTimestamp uint64, stateRootProof BeaconChainProofsStateRootProof, validatorIndices []*big.Int, validatorFieldsProofs [][]byte, validatorFields [][][32]byte) (*types.Transaction, error) { - return _EigenPod.Contract.VerifyWithdrawalCredentials(&_EigenPod.TransactOpts, beaconTimestamp, stateRootProof, validatorIndices, validatorFieldsProofs, validatorFields) -} - -// VerifyWithdrawalCredentials is a paid mutator transaction binding the contract method 0x3f65cf19. -// -// Solidity: function verifyWithdrawalCredentials(uint64 beaconTimestamp, (bytes32,bytes) stateRootProof, uint40[] validatorIndices, bytes[] validatorFieldsProofs, bytes32[][] validatorFields) returns() -func (_EigenPod *EigenPodTransactorSession) VerifyWithdrawalCredentials(beaconTimestamp uint64, stateRootProof BeaconChainProofsStateRootProof, validatorIndices []*big.Int, validatorFieldsProofs [][]byte, validatorFields [][][32]byte) (*types.Transaction, error) { - return _EigenPod.Contract.VerifyWithdrawalCredentials(&_EigenPod.TransactOpts, beaconTimestamp, stateRootProof, validatorIndices, validatorFieldsProofs, validatorFields) -} - -// WithdrawRestakedBeaconChainETH is a paid mutator transaction binding the contract method 0xc4907442. -// -// Solidity: function withdrawRestakedBeaconChainETH(address recipient, uint256 amountWei) returns() -func (_EigenPod *EigenPodTransactor) WithdrawRestakedBeaconChainETH(opts *bind.TransactOpts, recipient common.Address, amountWei *big.Int) (*types.Transaction, error) { - return _EigenPod.contract.Transact(opts, "withdrawRestakedBeaconChainETH", recipient, amountWei) -} - -// WithdrawRestakedBeaconChainETH is a paid mutator transaction binding the contract method 0xc4907442. -// -// Solidity: function withdrawRestakedBeaconChainETH(address recipient, uint256 amountWei) returns() -func (_EigenPod *EigenPodSession) WithdrawRestakedBeaconChainETH(recipient common.Address, amountWei *big.Int) (*types.Transaction, error) { - return _EigenPod.Contract.WithdrawRestakedBeaconChainETH(&_EigenPod.TransactOpts, recipient, amountWei) -} - -// WithdrawRestakedBeaconChainETH is a paid mutator transaction binding the contract method 0xc4907442. -// -// Solidity: function withdrawRestakedBeaconChainETH(address recipient, uint256 amountWei) returns() -func (_EigenPod *EigenPodTransactorSession) WithdrawRestakedBeaconChainETH(recipient common.Address, amountWei *big.Int) (*types.Transaction, error) { - return _EigenPod.Contract.WithdrawRestakedBeaconChainETH(&_EigenPod.TransactOpts, recipient, amountWei) -} - -// Receive is a paid mutator transaction binding the contract receive function. -// -// Solidity: receive() payable returns() -func (_EigenPod *EigenPodTransactor) Receive(opts *bind.TransactOpts) (*types.Transaction, error) { - return _EigenPod.contract.RawTransact(opts, nil) // calldata is disallowed for receive function -} - -// Receive is a paid mutator transaction binding the contract receive function. -// -// Solidity: receive() payable returns() -func (_EigenPod *EigenPodSession) Receive() (*types.Transaction, error) { - return _EigenPod.Contract.Receive(&_EigenPod.TransactOpts) -} - -// Receive is a paid mutator transaction binding the contract receive function. -// -// Solidity: receive() payable returns() -func (_EigenPod *EigenPodTransactorSession) Receive() (*types.Transaction, error) { - return _EigenPod.Contract.Receive(&_EigenPod.TransactOpts) -} - -// EigenPodCheckpointCreatedIterator is returned from FilterCheckpointCreated and is used to iterate over the raw logs and unpacked data for CheckpointCreated events raised by the EigenPod contract. -type EigenPodCheckpointCreatedIterator struct { - Event *EigenPodCheckpointCreated // Event containing the contract specifics and raw log - - contract *bind.BoundContract // Generic contract to use for unpacking event data - event string // Event name to use for unpacking event data - - logs chan types.Log // Log channel receiving the found contract events - sub ethereum.Subscription // Subscription for errors, completion and termination - done bool // Whether the subscription completed delivering logs - fail error // Occurred error to stop iteration -} - -// Next advances the iterator to the subsequent event, returning whether there -// are any more events found. In case of a retrieval or parsing error, false is -// returned and Error() can be queried for the exact failure. -func (it *EigenPodCheckpointCreatedIterator) Next() bool { - // If the iterator failed, stop iterating - if it.fail != nil { - return false - } - // If the iterator completed, deliver directly whatever's available - if it.done { - select { - case log := <-it.logs: - it.Event = new(EigenPodCheckpointCreated) - if err := it.contract.UnpackLog(it.Event, it.event, log); err != nil { - it.fail = err - return false - } - it.Event.Raw = log - return true - - default: - return false - } - } - // Iterator still in progress, wait for either a data or an error event - select { - case log := <-it.logs: - it.Event = new(EigenPodCheckpointCreated) - if err := it.contract.UnpackLog(it.Event, it.event, log); err != nil { - it.fail = err - return false - } - it.Event.Raw = log - return true - - case err := <-it.sub.Err(): - it.done = true - it.fail = err - return it.Next() - } -} - -// Error returns any retrieval or parsing error occurred during filtering. -func (it *EigenPodCheckpointCreatedIterator) Error() error { - return it.fail -} - -// Close terminates the iteration process, releasing any pending underlying -// resources. -func (it *EigenPodCheckpointCreatedIterator) Close() error { - it.sub.Unsubscribe() - return nil -} - -// EigenPodCheckpointCreated represents a CheckpointCreated event raised by the EigenPod contract. -type EigenPodCheckpointCreated struct { - CheckpointTimestamp uint64 - BeaconBlockRoot [32]byte - ValidatorCount *big.Int - Raw types.Log // Blockchain specific contextual infos -} - -// FilterCheckpointCreated is a free log retrieval operation binding the contract event 0x575796133bbed337e5b39aa49a30dc2556a91e0c6c2af4b7b886ae77ebef1076. -// -// Solidity: event CheckpointCreated(uint64 indexed checkpointTimestamp, bytes32 indexed beaconBlockRoot, uint256 validatorCount) -func (_EigenPod *EigenPodFilterer) FilterCheckpointCreated(opts *bind.FilterOpts, checkpointTimestamp []uint64, beaconBlockRoot [][32]byte) (*EigenPodCheckpointCreatedIterator, error) { - - var checkpointTimestampRule []interface{} - for _, checkpointTimestampItem := range checkpointTimestamp { - checkpointTimestampRule = append(checkpointTimestampRule, checkpointTimestampItem) - } - var beaconBlockRootRule []interface{} - for _, beaconBlockRootItem := range beaconBlockRoot { - beaconBlockRootRule = append(beaconBlockRootRule, beaconBlockRootItem) - } - - logs, sub, err := _EigenPod.contract.FilterLogs(opts, "CheckpointCreated", checkpointTimestampRule, beaconBlockRootRule) - if err != nil { - return nil, err - } - return &EigenPodCheckpointCreatedIterator{contract: _EigenPod.contract, event: "CheckpointCreated", logs: logs, sub: sub}, nil -} - -// WatchCheckpointCreated is a free log subscription operation binding the contract event 0x575796133bbed337e5b39aa49a30dc2556a91e0c6c2af4b7b886ae77ebef1076. -// -// Solidity: event CheckpointCreated(uint64 indexed checkpointTimestamp, bytes32 indexed beaconBlockRoot, uint256 validatorCount) -func (_EigenPod *EigenPodFilterer) WatchCheckpointCreated(opts *bind.WatchOpts, sink chan<- *EigenPodCheckpointCreated, checkpointTimestamp []uint64, beaconBlockRoot [][32]byte) (event.Subscription, error) { - - var checkpointTimestampRule []interface{} - for _, checkpointTimestampItem := range checkpointTimestamp { - checkpointTimestampRule = append(checkpointTimestampRule, checkpointTimestampItem) - } - var beaconBlockRootRule []interface{} - for _, beaconBlockRootItem := range beaconBlockRoot { - beaconBlockRootRule = append(beaconBlockRootRule, beaconBlockRootItem) - } - - logs, sub, err := _EigenPod.contract.WatchLogs(opts, "CheckpointCreated", checkpointTimestampRule, beaconBlockRootRule) - if err != nil { - return nil, err - } - return event.NewSubscription(func(quit <-chan struct{}) error { - defer sub.Unsubscribe() - for { - select { - case log := <-logs: - // New log arrived, parse the event and forward to the user - event := new(EigenPodCheckpointCreated) - if err := _EigenPod.contract.UnpackLog(event, "CheckpointCreated", log); err != nil { - return err - } - event.Raw = log - - select { - case sink <- event: - case err := <-sub.Err(): - return err - case <-quit: - return nil - } - case err := <-sub.Err(): - return err - case <-quit: - return nil - } - } - }), nil -} - -// ParseCheckpointCreated is a log parse operation binding the contract event 0x575796133bbed337e5b39aa49a30dc2556a91e0c6c2af4b7b886ae77ebef1076. -// -// Solidity: event CheckpointCreated(uint64 indexed checkpointTimestamp, bytes32 indexed beaconBlockRoot, uint256 validatorCount) -func (_EigenPod *EigenPodFilterer) ParseCheckpointCreated(log types.Log) (*EigenPodCheckpointCreated, error) { - event := new(EigenPodCheckpointCreated) - if err := _EigenPod.contract.UnpackLog(event, "CheckpointCreated", log); err != nil { - return nil, err - } - event.Raw = log - return event, nil -} - -// EigenPodCheckpointFinalizedIterator is returned from FilterCheckpointFinalized and is used to iterate over the raw logs and unpacked data for CheckpointFinalized events raised by the EigenPod contract. -type EigenPodCheckpointFinalizedIterator struct { - Event *EigenPodCheckpointFinalized // Event containing the contract specifics and raw log - - contract *bind.BoundContract // Generic contract to use for unpacking event data - event string // Event name to use for unpacking event data - - logs chan types.Log // Log channel receiving the found contract events - sub ethereum.Subscription // Subscription for errors, completion and termination - done bool // Whether the subscription completed delivering logs - fail error // Occurred error to stop iteration -} - -// Next advances the iterator to the subsequent event, returning whether there -// are any more events found. In case of a retrieval or parsing error, false is -// returned and Error() can be queried for the exact failure. -func (it *EigenPodCheckpointFinalizedIterator) Next() bool { - // If the iterator failed, stop iterating - if it.fail != nil { - return false - } - // If the iterator completed, deliver directly whatever's available - if it.done { - select { - case log := <-it.logs: - it.Event = new(EigenPodCheckpointFinalized) - if err := it.contract.UnpackLog(it.Event, it.event, log); err != nil { - it.fail = err - return false - } - it.Event.Raw = log - return true - - default: - return false - } - } - // Iterator still in progress, wait for either a data or an error event - select { - case log := <-it.logs: - it.Event = new(EigenPodCheckpointFinalized) - if err := it.contract.UnpackLog(it.Event, it.event, log); err != nil { - it.fail = err - return false - } - it.Event.Raw = log - return true - - case err := <-it.sub.Err(): - it.done = true - it.fail = err - return it.Next() - } -} - -// Error returns any retrieval or parsing error occurred during filtering. -func (it *EigenPodCheckpointFinalizedIterator) Error() error { - return it.fail -} - -// Close terminates the iteration process, releasing any pending underlying -// resources. -func (it *EigenPodCheckpointFinalizedIterator) Close() error { - it.sub.Unsubscribe() - return nil -} - -// EigenPodCheckpointFinalized represents a CheckpointFinalized event raised by the EigenPod contract. -type EigenPodCheckpointFinalized struct { - CheckpointTimestamp uint64 - TotalShareDeltaWei *big.Int - Raw types.Log // Blockchain specific contextual infos -} - -// FilterCheckpointFinalized is a free log retrieval operation binding the contract event 0x525408c201bc1576eb44116f6478f1c2a54775b19a043bcfdc708364f74f8e44. -// -// Solidity: event CheckpointFinalized(uint64 indexed checkpointTimestamp, int256 totalShareDeltaWei) -func (_EigenPod *EigenPodFilterer) FilterCheckpointFinalized(opts *bind.FilterOpts, checkpointTimestamp []uint64) (*EigenPodCheckpointFinalizedIterator, error) { - - var checkpointTimestampRule []interface{} - for _, checkpointTimestampItem := range checkpointTimestamp { - checkpointTimestampRule = append(checkpointTimestampRule, checkpointTimestampItem) - } - - logs, sub, err := _EigenPod.contract.FilterLogs(opts, "CheckpointFinalized", checkpointTimestampRule) - if err != nil { - return nil, err - } - return &EigenPodCheckpointFinalizedIterator{contract: _EigenPod.contract, event: "CheckpointFinalized", logs: logs, sub: sub}, nil -} - -// WatchCheckpointFinalized is a free log subscription operation binding the contract event 0x525408c201bc1576eb44116f6478f1c2a54775b19a043bcfdc708364f74f8e44. -// -// Solidity: event CheckpointFinalized(uint64 indexed checkpointTimestamp, int256 totalShareDeltaWei) -func (_EigenPod *EigenPodFilterer) WatchCheckpointFinalized(opts *bind.WatchOpts, sink chan<- *EigenPodCheckpointFinalized, checkpointTimestamp []uint64) (event.Subscription, error) { - - var checkpointTimestampRule []interface{} - for _, checkpointTimestampItem := range checkpointTimestamp { - checkpointTimestampRule = append(checkpointTimestampRule, checkpointTimestampItem) - } - - logs, sub, err := _EigenPod.contract.WatchLogs(opts, "CheckpointFinalized", checkpointTimestampRule) - if err != nil { - return nil, err - } - return event.NewSubscription(func(quit <-chan struct{}) error { - defer sub.Unsubscribe() - for { - select { - case log := <-logs: - // New log arrived, parse the event and forward to the user - event := new(EigenPodCheckpointFinalized) - if err := _EigenPod.contract.UnpackLog(event, "CheckpointFinalized", log); err != nil { - return err - } - event.Raw = log - - select { - case sink <- event: - case err := <-sub.Err(): - return err - case <-quit: - return nil - } - case err := <-sub.Err(): - return err - case <-quit: - return nil - } - } - }), nil -} - -// ParseCheckpointFinalized is a log parse operation binding the contract event 0x525408c201bc1576eb44116f6478f1c2a54775b19a043bcfdc708364f74f8e44. -// -// Solidity: event CheckpointFinalized(uint64 indexed checkpointTimestamp, int256 totalShareDeltaWei) -func (_EigenPod *EigenPodFilterer) ParseCheckpointFinalized(log types.Log) (*EigenPodCheckpointFinalized, error) { - event := new(EigenPodCheckpointFinalized) - if err := _EigenPod.contract.UnpackLog(event, "CheckpointFinalized", log); err != nil { - return nil, err - } - event.Raw = log - return event, nil -} - -// EigenPodEigenPodStakedIterator is returned from FilterEigenPodStaked and is used to iterate over the raw logs and unpacked data for EigenPodStaked events raised by the EigenPod contract. -type EigenPodEigenPodStakedIterator struct { - Event *EigenPodEigenPodStaked // Event containing the contract specifics and raw log - - contract *bind.BoundContract // Generic contract to use for unpacking event data - event string // Event name to use for unpacking event data - - logs chan types.Log // Log channel receiving the found contract events - sub ethereum.Subscription // Subscription for errors, completion and termination - done bool // Whether the subscription completed delivering logs - fail error // Occurred error to stop iteration -} - -// Next advances the iterator to the subsequent event, returning whether there -// are any more events found. In case of a retrieval or parsing error, false is -// returned and Error() can be queried for the exact failure. -func (it *EigenPodEigenPodStakedIterator) Next() bool { - // If the iterator failed, stop iterating - if it.fail != nil { - return false - } - // If the iterator completed, deliver directly whatever's available - if it.done { - select { - case log := <-it.logs: - it.Event = new(EigenPodEigenPodStaked) - if err := it.contract.UnpackLog(it.Event, it.event, log); err != nil { - it.fail = err - return false - } - it.Event.Raw = log - return true - - default: - return false - } - } - // Iterator still in progress, wait for either a data or an error event - select { - case log := <-it.logs: - it.Event = new(EigenPodEigenPodStaked) - if err := it.contract.UnpackLog(it.Event, it.event, log); err != nil { - it.fail = err - return false - } - it.Event.Raw = log - return true - - case err := <-it.sub.Err(): - it.done = true - it.fail = err - return it.Next() - } -} - -// Error returns any retrieval or parsing error occurred during filtering. -func (it *EigenPodEigenPodStakedIterator) Error() error { - return it.fail -} - -// Close terminates the iteration process, releasing any pending underlying -// resources. -func (it *EigenPodEigenPodStakedIterator) Close() error { - it.sub.Unsubscribe() - return nil -} - -// EigenPodEigenPodStaked represents a EigenPodStaked event raised by the EigenPod contract. -type EigenPodEigenPodStaked struct { - Pubkey []byte - Raw types.Log // Blockchain specific contextual infos -} - -// FilterEigenPodStaked is a free log retrieval operation binding the contract event 0x606865b7934a25d4aed43f6cdb426403353fa4b3009c4d228407474581b01e23. -// -// Solidity: event EigenPodStaked(bytes pubkey) -func (_EigenPod *EigenPodFilterer) FilterEigenPodStaked(opts *bind.FilterOpts) (*EigenPodEigenPodStakedIterator, error) { - - logs, sub, err := _EigenPod.contract.FilterLogs(opts, "EigenPodStaked") - if err != nil { - return nil, err - } - return &EigenPodEigenPodStakedIterator{contract: _EigenPod.contract, event: "EigenPodStaked", logs: logs, sub: sub}, nil -} - -// WatchEigenPodStaked is a free log subscription operation binding the contract event 0x606865b7934a25d4aed43f6cdb426403353fa4b3009c4d228407474581b01e23. -// -// Solidity: event EigenPodStaked(bytes pubkey) -func (_EigenPod *EigenPodFilterer) WatchEigenPodStaked(opts *bind.WatchOpts, sink chan<- *EigenPodEigenPodStaked) (event.Subscription, error) { - - logs, sub, err := _EigenPod.contract.WatchLogs(opts, "EigenPodStaked") - if err != nil { - return nil, err - } - return event.NewSubscription(func(quit <-chan struct{}) error { - defer sub.Unsubscribe() - for { - select { - case log := <-logs: - // New log arrived, parse the event and forward to the user - event := new(EigenPodEigenPodStaked) - if err := _EigenPod.contract.UnpackLog(event, "EigenPodStaked", log); err != nil { - return err - } - event.Raw = log - - select { - case sink <- event: - case err := <-sub.Err(): - return err - case <-quit: - return nil - } - case err := <-sub.Err(): - return err - case <-quit: - return nil - } - } - }), nil -} - -// ParseEigenPodStaked is a log parse operation binding the contract event 0x606865b7934a25d4aed43f6cdb426403353fa4b3009c4d228407474581b01e23. -// -// Solidity: event EigenPodStaked(bytes pubkey) -func (_EigenPod *EigenPodFilterer) ParseEigenPodStaked(log types.Log) (*EigenPodEigenPodStaked, error) { - event := new(EigenPodEigenPodStaked) - if err := _EigenPod.contract.UnpackLog(event, "EigenPodStaked", log); err != nil { - return nil, err - } - event.Raw = log - return event, nil -} - -// EigenPodInitializedIterator is returned from FilterInitialized and is used to iterate over the raw logs and unpacked data for Initialized events raised by the EigenPod contract. -type EigenPodInitializedIterator struct { - Event *EigenPodInitialized // Event containing the contract specifics and raw log - - contract *bind.BoundContract // Generic contract to use for unpacking event data - event string // Event name to use for unpacking event data - - logs chan types.Log // Log channel receiving the found contract events - sub ethereum.Subscription // Subscription for errors, completion and termination - done bool // Whether the subscription completed delivering logs - fail error // Occurred error to stop iteration -} - -// Next advances the iterator to the subsequent event, returning whether there -// are any more events found. In case of a retrieval or parsing error, false is -// returned and Error() can be queried for the exact failure. -func (it *EigenPodInitializedIterator) Next() bool { - // If the iterator failed, stop iterating - if it.fail != nil { - return false - } - // If the iterator completed, deliver directly whatever's available - if it.done { - select { - case log := <-it.logs: - it.Event = new(EigenPodInitialized) - if err := it.contract.UnpackLog(it.Event, it.event, log); err != nil { - it.fail = err - return false - } - it.Event.Raw = log - return true - - default: - return false - } - } - // Iterator still in progress, wait for either a data or an error event - select { - case log := <-it.logs: - it.Event = new(EigenPodInitialized) - if err := it.contract.UnpackLog(it.Event, it.event, log); err != nil { - it.fail = err - return false - } - it.Event.Raw = log - return true - - case err := <-it.sub.Err(): - it.done = true - it.fail = err - return it.Next() - } -} - -// Error returns any retrieval or parsing error occurred during filtering. -func (it *EigenPodInitializedIterator) Error() error { - return it.fail -} - -// Close terminates the iteration process, releasing any pending underlying -// resources. -func (it *EigenPodInitializedIterator) Close() error { - it.sub.Unsubscribe() - return nil -} - -// EigenPodInitialized represents a Initialized event raised by the EigenPod contract. -type EigenPodInitialized struct { - Version uint8 - Raw types.Log // Blockchain specific contextual infos -} - -// FilterInitialized is a free log retrieval operation binding the contract event 0x7f26b83ff96e1f2b6a682f133852f6798a09c465da95921460cefb3847402498. -// -// Solidity: event Initialized(uint8 version) -func (_EigenPod *EigenPodFilterer) FilterInitialized(opts *bind.FilterOpts) (*EigenPodInitializedIterator, error) { - - logs, sub, err := _EigenPod.contract.FilterLogs(opts, "Initialized") - if err != nil { - return nil, err - } - return &EigenPodInitializedIterator{contract: _EigenPod.contract, event: "Initialized", logs: logs, sub: sub}, nil -} - -// WatchInitialized is a free log subscription operation binding the contract event 0x7f26b83ff96e1f2b6a682f133852f6798a09c465da95921460cefb3847402498. -// -// Solidity: event Initialized(uint8 version) -func (_EigenPod *EigenPodFilterer) WatchInitialized(opts *bind.WatchOpts, sink chan<- *EigenPodInitialized) (event.Subscription, error) { - - logs, sub, err := _EigenPod.contract.WatchLogs(opts, "Initialized") - if err != nil { - return nil, err - } - return event.NewSubscription(func(quit <-chan struct{}) error { - defer sub.Unsubscribe() - for { - select { - case log := <-logs: - // New log arrived, parse the event and forward to the user - event := new(EigenPodInitialized) - if err := _EigenPod.contract.UnpackLog(event, "Initialized", log); err != nil { - return err - } - event.Raw = log - - select { - case sink <- event: - case err := <-sub.Err(): - return err - case <-quit: - return nil - } - case err := <-sub.Err(): - return err - case <-quit: - return nil - } - } - }), nil -} - -// ParseInitialized is a log parse operation binding the contract event 0x7f26b83ff96e1f2b6a682f133852f6798a09c465da95921460cefb3847402498. -// -// Solidity: event Initialized(uint8 version) -func (_EigenPod *EigenPodFilterer) ParseInitialized(log types.Log) (*EigenPodInitialized, error) { - event := new(EigenPodInitialized) - if err := _EigenPod.contract.UnpackLog(event, "Initialized", log); err != nil { - return nil, err - } - event.Raw = log - return event, nil -} - -// EigenPodNonBeaconChainETHReceivedIterator is returned from FilterNonBeaconChainETHReceived and is used to iterate over the raw logs and unpacked data for NonBeaconChainETHReceived events raised by the EigenPod contract. -type EigenPodNonBeaconChainETHReceivedIterator struct { - Event *EigenPodNonBeaconChainETHReceived // Event containing the contract specifics and raw log - - contract *bind.BoundContract // Generic contract to use for unpacking event data - event string // Event name to use for unpacking event data - - logs chan types.Log // Log channel receiving the found contract events - sub ethereum.Subscription // Subscription for errors, completion and termination - done bool // Whether the subscription completed delivering logs - fail error // Occurred error to stop iteration -} - -// Next advances the iterator to the subsequent event, returning whether there -// are any more events found. In case of a retrieval or parsing error, false is -// returned and Error() can be queried for the exact failure. -func (it *EigenPodNonBeaconChainETHReceivedIterator) Next() bool { - // If the iterator failed, stop iterating - if it.fail != nil { - return false - } - // If the iterator completed, deliver directly whatever's available - if it.done { - select { - case log := <-it.logs: - it.Event = new(EigenPodNonBeaconChainETHReceived) - if err := it.contract.UnpackLog(it.Event, it.event, log); err != nil { - it.fail = err - return false - } - it.Event.Raw = log - return true - - default: - return false - } - } - // Iterator still in progress, wait for either a data or an error event - select { - case log := <-it.logs: - it.Event = new(EigenPodNonBeaconChainETHReceived) - if err := it.contract.UnpackLog(it.Event, it.event, log); err != nil { - it.fail = err - return false - } - it.Event.Raw = log - return true - - case err := <-it.sub.Err(): - it.done = true - it.fail = err - return it.Next() - } -} - -// Error returns any retrieval or parsing error occurred during filtering. -func (it *EigenPodNonBeaconChainETHReceivedIterator) Error() error { - return it.fail -} - -// Close terminates the iteration process, releasing any pending underlying -// resources. -func (it *EigenPodNonBeaconChainETHReceivedIterator) Close() error { - it.sub.Unsubscribe() - return nil -} - -// EigenPodNonBeaconChainETHReceived represents a NonBeaconChainETHReceived event raised by the EigenPod contract. -type EigenPodNonBeaconChainETHReceived struct { - AmountReceived *big.Int - Raw types.Log // Blockchain specific contextual infos -} - -// FilterNonBeaconChainETHReceived is a free log retrieval operation binding the contract event 0x6fdd3dbdb173299608c0aa9f368735857c8842b581f8389238bf05bd04b3bf49. -// -// Solidity: event NonBeaconChainETHReceived(uint256 amountReceived) -func (_EigenPod *EigenPodFilterer) FilterNonBeaconChainETHReceived(opts *bind.FilterOpts) (*EigenPodNonBeaconChainETHReceivedIterator, error) { - - logs, sub, err := _EigenPod.contract.FilterLogs(opts, "NonBeaconChainETHReceived") - if err != nil { - return nil, err - } - return &EigenPodNonBeaconChainETHReceivedIterator{contract: _EigenPod.contract, event: "NonBeaconChainETHReceived", logs: logs, sub: sub}, nil -} - -// WatchNonBeaconChainETHReceived is a free log subscription operation binding the contract event 0x6fdd3dbdb173299608c0aa9f368735857c8842b581f8389238bf05bd04b3bf49. -// -// Solidity: event NonBeaconChainETHReceived(uint256 amountReceived) -func (_EigenPod *EigenPodFilterer) WatchNonBeaconChainETHReceived(opts *bind.WatchOpts, sink chan<- *EigenPodNonBeaconChainETHReceived) (event.Subscription, error) { - - logs, sub, err := _EigenPod.contract.WatchLogs(opts, "NonBeaconChainETHReceived") - if err != nil { - return nil, err - } - return event.NewSubscription(func(quit <-chan struct{}) error { - defer sub.Unsubscribe() - for { - select { - case log := <-logs: - // New log arrived, parse the event and forward to the user - event := new(EigenPodNonBeaconChainETHReceived) - if err := _EigenPod.contract.UnpackLog(event, "NonBeaconChainETHReceived", log); err != nil { - return err - } - event.Raw = log - - select { - case sink <- event: - case err := <-sub.Err(): - return err - case <-quit: - return nil - } - case err := <-sub.Err(): - return err - case <-quit: - return nil - } - } - }), nil -} - -// ParseNonBeaconChainETHReceived is a log parse operation binding the contract event 0x6fdd3dbdb173299608c0aa9f368735857c8842b581f8389238bf05bd04b3bf49. -// -// Solidity: event NonBeaconChainETHReceived(uint256 amountReceived) -func (_EigenPod *EigenPodFilterer) ParseNonBeaconChainETHReceived(log types.Log) (*EigenPodNonBeaconChainETHReceived, error) { - event := new(EigenPodNonBeaconChainETHReceived) - if err := _EigenPod.contract.UnpackLog(event, "NonBeaconChainETHReceived", log); err != nil { - return nil, err - } - event.Raw = log - return event, nil -} - -// EigenPodProofSubmitterUpdatedIterator is returned from FilterProofSubmitterUpdated and is used to iterate over the raw logs and unpacked data for ProofSubmitterUpdated events raised by the EigenPod contract. -type EigenPodProofSubmitterUpdatedIterator struct { - Event *EigenPodProofSubmitterUpdated // Event containing the contract specifics and raw log - - contract *bind.BoundContract // Generic contract to use for unpacking event data - event string // Event name to use for unpacking event data - - logs chan types.Log // Log channel receiving the found contract events - sub ethereum.Subscription // Subscription for errors, completion and termination - done bool // Whether the subscription completed delivering logs - fail error // Occurred error to stop iteration -} - -// Next advances the iterator to the subsequent event, returning whether there -// are any more events found. In case of a retrieval or parsing error, false is -// returned and Error() can be queried for the exact failure. -func (it *EigenPodProofSubmitterUpdatedIterator) Next() bool { - // If the iterator failed, stop iterating - if it.fail != nil { - return false - } - // If the iterator completed, deliver directly whatever's available - if it.done { - select { - case log := <-it.logs: - it.Event = new(EigenPodProofSubmitterUpdated) - if err := it.contract.UnpackLog(it.Event, it.event, log); err != nil { - it.fail = err - return false - } - it.Event.Raw = log - return true - - default: - return false - } - } - // Iterator still in progress, wait for either a data or an error event - select { - case log := <-it.logs: - it.Event = new(EigenPodProofSubmitterUpdated) - if err := it.contract.UnpackLog(it.Event, it.event, log); err != nil { - it.fail = err - return false - } - it.Event.Raw = log - return true - - case err := <-it.sub.Err(): - it.done = true - it.fail = err - return it.Next() - } -} - -// Error returns any retrieval or parsing error occurred during filtering. -func (it *EigenPodProofSubmitterUpdatedIterator) Error() error { - return it.fail -} - -// Close terminates the iteration process, releasing any pending underlying -// resources. -func (it *EigenPodProofSubmitterUpdatedIterator) Close() error { - it.sub.Unsubscribe() - return nil -} - -// EigenPodProofSubmitterUpdated represents a ProofSubmitterUpdated event raised by the EigenPod contract. -type EigenPodProofSubmitterUpdated struct { - PrevProofSubmitter common.Address - NewProofSubmitter common.Address - Raw types.Log // Blockchain specific contextual infos -} - -// FilterProofSubmitterUpdated is a free log retrieval operation binding the contract event 0xfb8129080a19d34dceac04ba253fc50304dc86c729bd63cdca4a969ad19a5eac. -// -// Solidity: event ProofSubmitterUpdated(address prevProofSubmitter, address newProofSubmitter) -func (_EigenPod *EigenPodFilterer) FilterProofSubmitterUpdated(opts *bind.FilterOpts) (*EigenPodProofSubmitterUpdatedIterator, error) { - - logs, sub, err := _EigenPod.contract.FilterLogs(opts, "ProofSubmitterUpdated") - if err != nil { - return nil, err - } - return &EigenPodProofSubmitterUpdatedIterator{contract: _EigenPod.contract, event: "ProofSubmitterUpdated", logs: logs, sub: sub}, nil -} - -// WatchProofSubmitterUpdated is a free log subscription operation binding the contract event 0xfb8129080a19d34dceac04ba253fc50304dc86c729bd63cdca4a969ad19a5eac. -// -// Solidity: event ProofSubmitterUpdated(address prevProofSubmitter, address newProofSubmitter) -func (_EigenPod *EigenPodFilterer) WatchProofSubmitterUpdated(opts *bind.WatchOpts, sink chan<- *EigenPodProofSubmitterUpdated) (event.Subscription, error) { - - logs, sub, err := _EigenPod.contract.WatchLogs(opts, "ProofSubmitterUpdated") - if err != nil { - return nil, err - } - return event.NewSubscription(func(quit <-chan struct{}) error { - defer sub.Unsubscribe() - for { - select { - case log := <-logs: - // New log arrived, parse the event and forward to the user - event := new(EigenPodProofSubmitterUpdated) - if err := _EigenPod.contract.UnpackLog(event, "ProofSubmitterUpdated", log); err != nil { - return err - } - event.Raw = log - - select { - case sink <- event: - case err := <-sub.Err(): - return err - case <-quit: - return nil - } - case err := <-sub.Err(): - return err - case <-quit: - return nil - } - } - }), nil -} - -// ParseProofSubmitterUpdated is a log parse operation binding the contract event 0xfb8129080a19d34dceac04ba253fc50304dc86c729bd63cdca4a969ad19a5eac. -// -// Solidity: event ProofSubmitterUpdated(address prevProofSubmitter, address newProofSubmitter) -func (_EigenPod *EigenPodFilterer) ParseProofSubmitterUpdated(log types.Log) (*EigenPodProofSubmitterUpdated, error) { - event := new(EigenPodProofSubmitterUpdated) - if err := _EigenPod.contract.UnpackLog(event, "ProofSubmitterUpdated", log); err != nil { - return nil, err - } - event.Raw = log - return event, nil -} - -// EigenPodRestakedBeaconChainETHWithdrawnIterator is returned from FilterRestakedBeaconChainETHWithdrawn and is used to iterate over the raw logs and unpacked data for RestakedBeaconChainETHWithdrawn events raised by the EigenPod contract. -type EigenPodRestakedBeaconChainETHWithdrawnIterator struct { - Event *EigenPodRestakedBeaconChainETHWithdrawn // Event containing the contract specifics and raw log - - contract *bind.BoundContract // Generic contract to use for unpacking event data - event string // Event name to use for unpacking event data - - logs chan types.Log // Log channel receiving the found contract events - sub ethereum.Subscription // Subscription for errors, completion and termination - done bool // Whether the subscription completed delivering logs - fail error // Occurred error to stop iteration -} - -// Next advances the iterator to the subsequent event, returning whether there -// are any more events found. In case of a retrieval or parsing error, false is -// returned and Error() can be queried for the exact failure. -func (it *EigenPodRestakedBeaconChainETHWithdrawnIterator) Next() bool { - // If the iterator failed, stop iterating - if it.fail != nil { - return false - } - // If the iterator completed, deliver directly whatever's available - if it.done { - select { - case log := <-it.logs: - it.Event = new(EigenPodRestakedBeaconChainETHWithdrawn) - if err := it.contract.UnpackLog(it.Event, it.event, log); err != nil { - it.fail = err - return false - } - it.Event.Raw = log - return true - - default: - return false - } - } - // Iterator still in progress, wait for either a data or an error event - select { - case log := <-it.logs: - it.Event = new(EigenPodRestakedBeaconChainETHWithdrawn) - if err := it.contract.UnpackLog(it.Event, it.event, log); err != nil { - it.fail = err - return false - } - it.Event.Raw = log - return true - - case err := <-it.sub.Err(): - it.done = true - it.fail = err - return it.Next() - } -} - -// Error returns any retrieval or parsing error occurred during filtering. -func (it *EigenPodRestakedBeaconChainETHWithdrawnIterator) Error() error { - return it.fail -} - -// Close terminates the iteration process, releasing any pending underlying -// resources. -func (it *EigenPodRestakedBeaconChainETHWithdrawnIterator) Close() error { - it.sub.Unsubscribe() - return nil -} - -// EigenPodRestakedBeaconChainETHWithdrawn represents a RestakedBeaconChainETHWithdrawn event raised by the EigenPod contract. -type EigenPodRestakedBeaconChainETHWithdrawn struct { - Recipient common.Address - Amount *big.Int - Raw types.Log // Blockchain specific contextual infos -} - -// FilterRestakedBeaconChainETHWithdrawn is a free log retrieval operation binding the contract event 0x8947fd2ce07ef9cc302c4e8f0461015615d91ce851564839e91cc804c2f49d8e. -// -// Solidity: event RestakedBeaconChainETHWithdrawn(address indexed recipient, uint256 amount) -func (_EigenPod *EigenPodFilterer) FilterRestakedBeaconChainETHWithdrawn(opts *bind.FilterOpts, recipient []common.Address) (*EigenPodRestakedBeaconChainETHWithdrawnIterator, error) { - - var recipientRule []interface{} - for _, recipientItem := range recipient { - recipientRule = append(recipientRule, recipientItem) - } - - logs, sub, err := _EigenPod.contract.FilterLogs(opts, "RestakedBeaconChainETHWithdrawn", recipientRule) - if err != nil { - return nil, err - } - return &EigenPodRestakedBeaconChainETHWithdrawnIterator{contract: _EigenPod.contract, event: "RestakedBeaconChainETHWithdrawn", logs: logs, sub: sub}, nil -} - -// WatchRestakedBeaconChainETHWithdrawn is a free log subscription operation binding the contract event 0x8947fd2ce07ef9cc302c4e8f0461015615d91ce851564839e91cc804c2f49d8e. -// -// Solidity: event RestakedBeaconChainETHWithdrawn(address indexed recipient, uint256 amount) -func (_EigenPod *EigenPodFilterer) WatchRestakedBeaconChainETHWithdrawn(opts *bind.WatchOpts, sink chan<- *EigenPodRestakedBeaconChainETHWithdrawn, recipient []common.Address) (event.Subscription, error) { - - var recipientRule []interface{} - for _, recipientItem := range recipient { - recipientRule = append(recipientRule, recipientItem) - } - - logs, sub, err := _EigenPod.contract.WatchLogs(opts, "RestakedBeaconChainETHWithdrawn", recipientRule) - if err != nil { - return nil, err - } - return event.NewSubscription(func(quit <-chan struct{}) error { - defer sub.Unsubscribe() - for { - select { - case log := <-logs: - // New log arrived, parse the event and forward to the user - event := new(EigenPodRestakedBeaconChainETHWithdrawn) - if err := _EigenPod.contract.UnpackLog(event, "RestakedBeaconChainETHWithdrawn", log); err != nil { - return err - } - event.Raw = log - - select { - case sink <- event: - case err := <-sub.Err(): - return err - case <-quit: - return nil - } - case err := <-sub.Err(): - return err - case <-quit: - return nil - } - } - }), nil -} - -// ParseRestakedBeaconChainETHWithdrawn is a log parse operation binding the contract event 0x8947fd2ce07ef9cc302c4e8f0461015615d91ce851564839e91cc804c2f49d8e. -// -// Solidity: event RestakedBeaconChainETHWithdrawn(address indexed recipient, uint256 amount) -func (_EigenPod *EigenPodFilterer) ParseRestakedBeaconChainETHWithdrawn(log types.Log) (*EigenPodRestakedBeaconChainETHWithdrawn, error) { - event := new(EigenPodRestakedBeaconChainETHWithdrawn) - if err := _EigenPod.contract.UnpackLog(event, "RestakedBeaconChainETHWithdrawn", log); err != nil { - return nil, err - } - event.Raw = log - return event, nil -} - -// EigenPodValidatorBalanceUpdatedIterator is returned from FilterValidatorBalanceUpdated and is used to iterate over the raw logs and unpacked data for ValidatorBalanceUpdated events raised by the EigenPod contract. -type EigenPodValidatorBalanceUpdatedIterator struct { - Event *EigenPodValidatorBalanceUpdated // Event containing the contract specifics and raw log - - contract *bind.BoundContract // Generic contract to use for unpacking event data - event string // Event name to use for unpacking event data - - logs chan types.Log // Log channel receiving the found contract events - sub ethereum.Subscription // Subscription for errors, completion and termination - done bool // Whether the subscription completed delivering logs - fail error // Occurred error to stop iteration -} - -// Next advances the iterator to the subsequent event, returning whether there -// are any more events found. In case of a retrieval or parsing error, false is -// returned and Error() can be queried for the exact failure. -func (it *EigenPodValidatorBalanceUpdatedIterator) Next() bool { - // If the iterator failed, stop iterating - if it.fail != nil { - return false - } - // If the iterator completed, deliver directly whatever's available - if it.done { - select { - case log := <-it.logs: - it.Event = new(EigenPodValidatorBalanceUpdated) - if err := it.contract.UnpackLog(it.Event, it.event, log); err != nil { - it.fail = err - return false - } - it.Event.Raw = log - return true - - default: - return false - } - } - // Iterator still in progress, wait for either a data or an error event - select { - case log := <-it.logs: - it.Event = new(EigenPodValidatorBalanceUpdated) - if err := it.contract.UnpackLog(it.Event, it.event, log); err != nil { - it.fail = err - return false - } - it.Event.Raw = log - return true - - case err := <-it.sub.Err(): - it.done = true - it.fail = err - return it.Next() - } -} - -// Error returns any retrieval or parsing error occurred during filtering. -func (it *EigenPodValidatorBalanceUpdatedIterator) Error() error { - return it.fail -} - -// Close terminates the iteration process, releasing any pending underlying -// resources. -func (it *EigenPodValidatorBalanceUpdatedIterator) Close() error { - it.sub.Unsubscribe() - return nil -} - -// EigenPodValidatorBalanceUpdated represents a ValidatorBalanceUpdated event raised by the EigenPod contract. -type EigenPodValidatorBalanceUpdated struct { - ValidatorIndex *big.Int - BalanceTimestamp uint64 - NewValidatorBalanceGwei uint64 - Raw types.Log // Blockchain specific contextual infos -} - -// FilterValidatorBalanceUpdated is a free log retrieval operation binding the contract event 0x0e5fac175b83177cc047381e030d8fb3b42b37bd1c025e22c280facad62c32df. -// -// Solidity: event ValidatorBalanceUpdated(uint40 validatorIndex, uint64 balanceTimestamp, uint64 newValidatorBalanceGwei) -func (_EigenPod *EigenPodFilterer) FilterValidatorBalanceUpdated(opts *bind.FilterOpts) (*EigenPodValidatorBalanceUpdatedIterator, error) { - - logs, sub, err := _EigenPod.contract.FilterLogs(opts, "ValidatorBalanceUpdated") - if err != nil { - return nil, err - } - return &EigenPodValidatorBalanceUpdatedIterator{contract: _EigenPod.contract, event: "ValidatorBalanceUpdated", logs: logs, sub: sub}, nil -} - -// WatchValidatorBalanceUpdated is a free log subscription operation binding the contract event 0x0e5fac175b83177cc047381e030d8fb3b42b37bd1c025e22c280facad62c32df. -// -// Solidity: event ValidatorBalanceUpdated(uint40 validatorIndex, uint64 balanceTimestamp, uint64 newValidatorBalanceGwei) -func (_EigenPod *EigenPodFilterer) WatchValidatorBalanceUpdated(opts *bind.WatchOpts, sink chan<- *EigenPodValidatorBalanceUpdated) (event.Subscription, error) { - - logs, sub, err := _EigenPod.contract.WatchLogs(opts, "ValidatorBalanceUpdated") - if err != nil { - return nil, err - } - return event.NewSubscription(func(quit <-chan struct{}) error { - defer sub.Unsubscribe() - for { - select { - case log := <-logs: - // New log arrived, parse the event and forward to the user - event := new(EigenPodValidatorBalanceUpdated) - if err := _EigenPod.contract.UnpackLog(event, "ValidatorBalanceUpdated", log); err != nil { - return err - } - event.Raw = log - - select { - case sink <- event: - case err := <-sub.Err(): - return err - case <-quit: - return nil - } - case err := <-sub.Err(): - return err - case <-quit: - return nil - } - } - }), nil -} - -// ParseValidatorBalanceUpdated is a log parse operation binding the contract event 0x0e5fac175b83177cc047381e030d8fb3b42b37bd1c025e22c280facad62c32df. -// -// Solidity: event ValidatorBalanceUpdated(uint40 validatorIndex, uint64 balanceTimestamp, uint64 newValidatorBalanceGwei) -func (_EigenPod *EigenPodFilterer) ParseValidatorBalanceUpdated(log types.Log) (*EigenPodValidatorBalanceUpdated, error) { - event := new(EigenPodValidatorBalanceUpdated) - if err := _EigenPod.contract.UnpackLog(event, "ValidatorBalanceUpdated", log); err != nil { - return nil, err - } - event.Raw = log - return event, nil -} - -// EigenPodValidatorCheckpointedIterator is returned from FilterValidatorCheckpointed and is used to iterate over the raw logs and unpacked data for ValidatorCheckpointed events raised by the EigenPod contract. -type EigenPodValidatorCheckpointedIterator struct { - Event *EigenPodValidatorCheckpointed // Event containing the contract specifics and raw log - - contract *bind.BoundContract // Generic contract to use for unpacking event data - event string // Event name to use for unpacking event data - - logs chan types.Log // Log channel receiving the found contract events - sub ethereum.Subscription // Subscription for errors, completion and termination - done bool // Whether the subscription completed delivering logs - fail error // Occurred error to stop iteration -} - -// Next advances the iterator to the subsequent event, returning whether there -// are any more events found. In case of a retrieval or parsing error, false is -// returned and Error() can be queried for the exact failure. -func (it *EigenPodValidatorCheckpointedIterator) Next() bool { - // If the iterator failed, stop iterating - if it.fail != nil { - return false - } - // If the iterator completed, deliver directly whatever's available - if it.done { - select { - case log := <-it.logs: - it.Event = new(EigenPodValidatorCheckpointed) - if err := it.contract.UnpackLog(it.Event, it.event, log); err != nil { - it.fail = err - return false - } - it.Event.Raw = log - return true - - default: - return false - } - } - // Iterator still in progress, wait for either a data or an error event - select { - case log := <-it.logs: - it.Event = new(EigenPodValidatorCheckpointed) - if err := it.contract.UnpackLog(it.Event, it.event, log); err != nil { - it.fail = err - return false - } - it.Event.Raw = log - return true - - case err := <-it.sub.Err(): - it.done = true - it.fail = err - return it.Next() - } -} - -// Error returns any retrieval or parsing error occurred during filtering. -func (it *EigenPodValidatorCheckpointedIterator) Error() error { - return it.fail -} - -// Close terminates the iteration process, releasing any pending underlying -// resources. -func (it *EigenPodValidatorCheckpointedIterator) Close() error { - it.sub.Unsubscribe() - return nil -} - -// EigenPodValidatorCheckpointed represents a ValidatorCheckpointed event raised by the EigenPod contract. -type EigenPodValidatorCheckpointed struct { - CheckpointTimestamp uint64 - ValidatorIndex *big.Int - Raw types.Log // Blockchain specific contextual infos -} - -// FilterValidatorCheckpointed is a free log retrieval operation binding the contract event 0xa91c59033c3423e18b54d0acecebb4972f9ea95aedf5f4cae3b677b02eaf3a3f. -// -// Solidity: event ValidatorCheckpointed(uint64 indexed checkpointTimestamp, uint40 indexed validatorIndex) -func (_EigenPod *EigenPodFilterer) FilterValidatorCheckpointed(opts *bind.FilterOpts, checkpointTimestamp []uint64, validatorIndex []*big.Int) (*EigenPodValidatorCheckpointedIterator, error) { - - var checkpointTimestampRule []interface{} - for _, checkpointTimestampItem := range checkpointTimestamp { - checkpointTimestampRule = append(checkpointTimestampRule, checkpointTimestampItem) - } - var validatorIndexRule []interface{} - for _, validatorIndexItem := range validatorIndex { - validatorIndexRule = append(validatorIndexRule, validatorIndexItem) - } - - logs, sub, err := _EigenPod.contract.FilterLogs(opts, "ValidatorCheckpointed", checkpointTimestampRule, validatorIndexRule) - if err != nil { - return nil, err - } - return &EigenPodValidatorCheckpointedIterator{contract: _EigenPod.contract, event: "ValidatorCheckpointed", logs: logs, sub: sub}, nil -} - -// WatchValidatorCheckpointed is a free log subscription operation binding the contract event 0xa91c59033c3423e18b54d0acecebb4972f9ea95aedf5f4cae3b677b02eaf3a3f. -// -// Solidity: event ValidatorCheckpointed(uint64 indexed checkpointTimestamp, uint40 indexed validatorIndex) -func (_EigenPod *EigenPodFilterer) WatchValidatorCheckpointed(opts *bind.WatchOpts, sink chan<- *EigenPodValidatorCheckpointed, checkpointTimestamp []uint64, validatorIndex []*big.Int) (event.Subscription, error) { - - var checkpointTimestampRule []interface{} - for _, checkpointTimestampItem := range checkpointTimestamp { - checkpointTimestampRule = append(checkpointTimestampRule, checkpointTimestampItem) - } - var validatorIndexRule []interface{} - for _, validatorIndexItem := range validatorIndex { - validatorIndexRule = append(validatorIndexRule, validatorIndexItem) - } - - logs, sub, err := _EigenPod.contract.WatchLogs(opts, "ValidatorCheckpointed", checkpointTimestampRule, validatorIndexRule) - if err != nil { - return nil, err - } - return event.NewSubscription(func(quit <-chan struct{}) error { - defer sub.Unsubscribe() - for { - select { - case log := <-logs: - // New log arrived, parse the event and forward to the user - event := new(EigenPodValidatorCheckpointed) - if err := _EigenPod.contract.UnpackLog(event, "ValidatorCheckpointed", log); err != nil { - return err - } - event.Raw = log - - select { - case sink <- event: - case err := <-sub.Err(): - return err - case <-quit: - return nil - } - case err := <-sub.Err(): - return err - case <-quit: - return nil - } - } - }), nil -} - -// ParseValidatorCheckpointed is a log parse operation binding the contract event 0xa91c59033c3423e18b54d0acecebb4972f9ea95aedf5f4cae3b677b02eaf3a3f. -// -// Solidity: event ValidatorCheckpointed(uint64 indexed checkpointTimestamp, uint40 indexed validatorIndex) -func (_EigenPod *EigenPodFilterer) ParseValidatorCheckpointed(log types.Log) (*EigenPodValidatorCheckpointed, error) { - event := new(EigenPodValidatorCheckpointed) - if err := _EigenPod.contract.UnpackLog(event, "ValidatorCheckpointed", log); err != nil { - return nil, err - } - event.Raw = log - return event, nil -} - -// EigenPodValidatorRestakedIterator is returned from FilterValidatorRestaked and is used to iterate over the raw logs and unpacked data for ValidatorRestaked events raised by the EigenPod contract. -type EigenPodValidatorRestakedIterator struct { - Event *EigenPodValidatorRestaked // Event containing the contract specifics and raw log - - contract *bind.BoundContract // Generic contract to use for unpacking event data - event string // Event name to use for unpacking event data - - logs chan types.Log // Log channel receiving the found contract events - sub ethereum.Subscription // Subscription for errors, completion and termination - done bool // Whether the subscription completed delivering logs - fail error // Occurred error to stop iteration -} - -// Next advances the iterator to the subsequent event, returning whether there -// are any more events found. In case of a retrieval or parsing error, false is -// returned and Error() can be queried for the exact failure. -func (it *EigenPodValidatorRestakedIterator) Next() bool { - // If the iterator failed, stop iterating - if it.fail != nil { - return false - } - // If the iterator completed, deliver directly whatever's available - if it.done { - select { - case log := <-it.logs: - it.Event = new(EigenPodValidatorRestaked) - if err := it.contract.UnpackLog(it.Event, it.event, log); err != nil { - it.fail = err - return false - } - it.Event.Raw = log - return true - - default: - return false - } - } - // Iterator still in progress, wait for either a data or an error event - select { - case log := <-it.logs: - it.Event = new(EigenPodValidatorRestaked) - if err := it.contract.UnpackLog(it.Event, it.event, log); err != nil { - it.fail = err - return false - } - it.Event.Raw = log - return true - - case err := <-it.sub.Err(): - it.done = true - it.fail = err - return it.Next() - } -} - -// Error returns any retrieval or parsing error occurred during filtering. -func (it *EigenPodValidatorRestakedIterator) Error() error { - return it.fail -} - -// Close terminates the iteration process, releasing any pending underlying -// resources. -func (it *EigenPodValidatorRestakedIterator) Close() error { - it.sub.Unsubscribe() - return nil -} - -// EigenPodValidatorRestaked represents a ValidatorRestaked event raised by the EigenPod contract. -type EigenPodValidatorRestaked struct { - ValidatorIndex *big.Int - Raw types.Log // Blockchain specific contextual infos -} - -// FilterValidatorRestaked is a free log retrieval operation binding the contract event 0x2d0800bbc377ea54a08c5db6a87aafff5e3e9c8fead0eda110e40e0c10441449. -// -// Solidity: event ValidatorRestaked(uint40 validatorIndex) -func (_EigenPod *EigenPodFilterer) FilterValidatorRestaked(opts *bind.FilterOpts) (*EigenPodValidatorRestakedIterator, error) { - - logs, sub, err := _EigenPod.contract.FilterLogs(opts, "ValidatorRestaked") - if err != nil { - return nil, err - } - return &EigenPodValidatorRestakedIterator{contract: _EigenPod.contract, event: "ValidatorRestaked", logs: logs, sub: sub}, nil -} - -// WatchValidatorRestaked is a free log subscription operation binding the contract event 0x2d0800bbc377ea54a08c5db6a87aafff5e3e9c8fead0eda110e40e0c10441449. -// -// Solidity: event ValidatorRestaked(uint40 validatorIndex) -func (_EigenPod *EigenPodFilterer) WatchValidatorRestaked(opts *bind.WatchOpts, sink chan<- *EigenPodValidatorRestaked) (event.Subscription, error) { - - logs, sub, err := _EigenPod.contract.WatchLogs(opts, "ValidatorRestaked") - if err != nil { - return nil, err - } - return event.NewSubscription(func(quit <-chan struct{}) error { - defer sub.Unsubscribe() - for { - select { - case log := <-logs: - // New log arrived, parse the event and forward to the user - event := new(EigenPodValidatorRestaked) - if err := _EigenPod.contract.UnpackLog(event, "ValidatorRestaked", log); err != nil { - return err - } - event.Raw = log - - select { - case sink <- event: - case err := <-sub.Err(): - return err - case <-quit: - return nil - } - case err := <-sub.Err(): - return err - case <-quit: - return nil - } - } - }), nil -} - -// ParseValidatorRestaked is a log parse operation binding the contract event 0x2d0800bbc377ea54a08c5db6a87aafff5e3e9c8fead0eda110e40e0c10441449. -// -// Solidity: event ValidatorRestaked(uint40 validatorIndex) -func (_EigenPod *EigenPodFilterer) ParseValidatorRestaked(log types.Log) (*EigenPodValidatorRestaked, error) { - event := new(EigenPodValidatorRestaked) - if err := _EigenPod.contract.UnpackLog(event, "ValidatorRestaked", log); err != nil { - return nil, err - } - event.Raw = log - return event, nil -} - -// EigenPodValidatorWithdrawnIterator is returned from FilterValidatorWithdrawn and is used to iterate over the raw logs and unpacked data for ValidatorWithdrawn events raised by the EigenPod contract. -type EigenPodValidatorWithdrawnIterator struct { - Event *EigenPodValidatorWithdrawn // Event containing the contract specifics and raw log - - contract *bind.BoundContract // Generic contract to use for unpacking event data - event string // Event name to use for unpacking event data - - logs chan types.Log // Log channel receiving the found contract events - sub ethereum.Subscription // Subscription for errors, completion and termination - done bool // Whether the subscription completed delivering logs - fail error // Occurred error to stop iteration -} - -// Next advances the iterator to the subsequent event, returning whether there -// are any more events found. In case of a retrieval or parsing error, false is -// returned and Error() can be queried for the exact failure. -func (it *EigenPodValidatorWithdrawnIterator) Next() bool { - // If the iterator failed, stop iterating - if it.fail != nil { - return false - } - // If the iterator completed, deliver directly whatever's available - if it.done { - select { - case log := <-it.logs: - it.Event = new(EigenPodValidatorWithdrawn) - if err := it.contract.UnpackLog(it.Event, it.event, log); err != nil { - it.fail = err - return false - } - it.Event.Raw = log - return true - - default: - return false - } - } - // Iterator still in progress, wait for either a data or an error event - select { - case log := <-it.logs: - it.Event = new(EigenPodValidatorWithdrawn) - if err := it.contract.UnpackLog(it.Event, it.event, log); err != nil { - it.fail = err - return false - } - it.Event.Raw = log - return true - - case err := <-it.sub.Err(): - it.done = true - it.fail = err - return it.Next() - } -} - -// Error returns any retrieval or parsing error occurred during filtering. -func (it *EigenPodValidatorWithdrawnIterator) Error() error { - return it.fail -} - -// Close terminates the iteration process, releasing any pending underlying -// resources. -func (it *EigenPodValidatorWithdrawnIterator) Close() error { - it.sub.Unsubscribe() - return nil -} - -// EigenPodValidatorWithdrawn represents a ValidatorWithdrawn event raised by the EigenPod contract. -type EigenPodValidatorWithdrawn struct { - CheckpointTimestamp uint64 - ValidatorIndex *big.Int - Raw types.Log // Blockchain specific contextual infos -} - -// FilterValidatorWithdrawn is a free log retrieval operation binding the contract event 0x2a02361ffa66cf2c2da4682c2355a6adcaa9f6c227b6e6563e68480f9587626a. -// -// Solidity: event ValidatorWithdrawn(uint64 indexed checkpointTimestamp, uint40 indexed validatorIndex) -func (_EigenPod *EigenPodFilterer) FilterValidatorWithdrawn(opts *bind.FilterOpts, checkpointTimestamp []uint64, validatorIndex []*big.Int) (*EigenPodValidatorWithdrawnIterator, error) { - - var checkpointTimestampRule []interface{} - for _, checkpointTimestampItem := range checkpointTimestamp { - checkpointTimestampRule = append(checkpointTimestampRule, checkpointTimestampItem) - } - var validatorIndexRule []interface{} - for _, validatorIndexItem := range validatorIndex { - validatorIndexRule = append(validatorIndexRule, validatorIndexItem) - } - - logs, sub, err := _EigenPod.contract.FilterLogs(opts, "ValidatorWithdrawn", checkpointTimestampRule, validatorIndexRule) - if err != nil { - return nil, err - } - return &EigenPodValidatorWithdrawnIterator{contract: _EigenPod.contract, event: "ValidatorWithdrawn", logs: logs, sub: sub}, nil -} - -// WatchValidatorWithdrawn is a free log subscription operation binding the contract event 0x2a02361ffa66cf2c2da4682c2355a6adcaa9f6c227b6e6563e68480f9587626a. -// -// Solidity: event ValidatorWithdrawn(uint64 indexed checkpointTimestamp, uint40 indexed validatorIndex) -func (_EigenPod *EigenPodFilterer) WatchValidatorWithdrawn(opts *bind.WatchOpts, sink chan<- *EigenPodValidatorWithdrawn, checkpointTimestamp []uint64, validatorIndex []*big.Int) (event.Subscription, error) { - - var checkpointTimestampRule []interface{} - for _, checkpointTimestampItem := range checkpointTimestamp { - checkpointTimestampRule = append(checkpointTimestampRule, checkpointTimestampItem) - } - var validatorIndexRule []interface{} - for _, validatorIndexItem := range validatorIndex { - validatorIndexRule = append(validatorIndexRule, validatorIndexItem) - } - - logs, sub, err := _EigenPod.contract.WatchLogs(opts, "ValidatorWithdrawn", checkpointTimestampRule, validatorIndexRule) - if err != nil { - return nil, err - } - return event.NewSubscription(func(quit <-chan struct{}) error { - defer sub.Unsubscribe() - for { - select { - case log := <-logs: - // New log arrived, parse the event and forward to the user - event := new(EigenPodValidatorWithdrawn) - if err := _EigenPod.contract.UnpackLog(event, "ValidatorWithdrawn", log); err != nil { - return err - } - event.Raw = log - - select { - case sink <- event: - case err := <-sub.Err(): - return err - case <-quit: - return nil - } - case err := <-sub.Err(): - return err - case <-quit: - return nil - } - } - }), nil -} - -// ParseValidatorWithdrawn is a log parse operation binding the contract event 0x2a02361ffa66cf2c2da4682c2355a6adcaa9f6c227b6e6563e68480f9587626a. -// -// Solidity: event ValidatorWithdrawn(uint64 indexed checkpointTimestamp, uint40 indexed validatorIndex) -func (_EigenPod *EigenPodFilterer) ParseValidatorWithdrawn(log types.Log) (*EigenPodValidatorWithdrawn, error) { - event := new(EigenPodValidatorWithdrawn) - if err := _EigenPod.contract.UnpackLog(event, "ValidatorWithdrawn", log); err != nil { - return nil, err - } - event.Raw = log - return event, nil -} diff --git a/cli/core/onchain/EigenPodManager.go b/cli/core/onchain/EigenPodManager.go deleted file mode 100644 index 8878bb32..00000000 --- a/cli/core/onchain/EigenPodManager.go +++ /dev/null @@ -1,2368 +0,0 @@ -// Code generated - DO NOT EDIT. -// This file is a generated binding and any manual changes will be lost. - -package onchain - -import ( - "errors" - "math/big" - "strings" - - ethereum "github.com/ethereum/go-ethereum" - "github.com/ethereum/go-ethereum/accounts/abi" - "github.com/ethereum/go-ethereum/accounts/abi/bind" - "github.com/ethereum/go-ethereum/common" - "github.com/ethereum/go-ethereum/core/types" - "github.com/ethereum/go-ethereum/event" -) - -// Reference imports to suppress errors if they are not otherwise used. -var ( - _ = errors.New - _ = big.NewInt - _ = strings.NewReader - _ = ethereum.NotFound - _ = bind.Bind - _ = common.Big1 - _ = types.BloomLookup - _ = event.NewSubscription - _ = abi.ConvertType -) - -// EigenPodManagerMetaData contains all meta data concerning the EigenPodManager contract. -var EigenPodManagerMetaData = &bind.MetaData{ - ABI: "[{\"type\":\"constructor\",\"inputs\":[{\"name\":\"_ethPOS\",\"type\":\"address\",\"internalType\":\"contractIETHPOSDeposit\"},{\"name\":\"_eigenPodBeacon\",\"type\":\"address\",\"internalType\":\"contractIBeacon\"},{\"name\":\"_strategyManager\",\"type\":\"address\",\"internalType\":\"contractIStrategyManager\"},{\"name\":\"_slasher\",\"type\":\"address\",\"internalType\":\"contractISlasher\"},{\"name\":\"_delegationManager\",\"type\":\"address\",\"internalType\":\"contractIDelegationManager\"}],\"stateMutability\":\"nonpayable\"},{\"type\":\"function\",\"name\":\"addShares\",\"inputs\":[{\"name\":\"podOwner\",\"type\":\"address\",\"internalType\":\"address\"},{\"name\":\"shares\",\"type\":\"uint256\",\"internalType\":\"uint256\"}],\"outputs\":[{\"name\":\"\",\"type\":\"uint256\",\"internalType\":\"uint256\"}],\"stateMutability\":\"nonpayable\"},{\"type\":\"function\",\"name\":\"beaconChainETHStrategy\",\"inputs\":[],\"outputs\":[{\"name\":\"\",\"type\":\"address\",\"internalType\":\"contractIStrategy\"}],\"stateMutability\":\"view\"},{\"type\":\"function\",\"name\":\"createPod\",\"inputs\":[],\"outputs\":[{\"name\":\"\",\"type\":\"address\",\"internalType\":\"address\"}],\"stateMutability\":\"nonpayable\"},{\"type\":\"function\",\"name\":\"delegationManager\",\"inputs\":[],\"outputs\":[{\"name\":\"\",\"type\":\"address\",\"internalType\":\"contractIDelegationManager\"}],\"stateMutability\":\"view\"},{\"type\":\"function\",\"name\":\"eigenPodBeacon\",\"inputs\":[],\"outputs\":[{\"name\":\"\",\"type\":\"address\",\"internalType\":\"contractIBeacon\"}],\"stateMutability\":\"view\"},{\"type\":\"function\",\"name\":\"ethPOS\",\"inputs\":[],\"outputs\":[{\"name\":\"\",\"type\":\"address\",\"internalType\":\"contractIETHPOSDeposit\"}],\"stateMutability\":\"view\"},{\"type\":\"function\",\"name\":\"getPod\",\"inputs\":[{\"name\":\"podOwner\",\"type\":\"address\",\"internalType\":\"address\"}],\"outputs\":[{\"name\":\"\",\"type\":\"address\",\"internalType\":\"contractIEigenPod\"}],\"stateMutability\":\"view\"},{\"type\":\"function\",\"name\":\"hasPod\",\"inputs\":[{\"name\":\"podOwner\",\"type\":\"address\",\"internalType\":\"address\"}],\"outputs\":[{\"name\":\"\",\"type\":\"bool\",\"internalType\":\"bool\"}],\"stateMutability\":\"view\"},{\"type\":\"function\",\"name\":\"initialize\",\"inputs\":[{\"name\":\"initialOwner\",\"type\":\"address\",\"internalType\":\"address\"},{\"name\":\"_pauserRegistry\",\"type\":\"address\",\"internalType\":\"contractIPauserRegistry\"},{\"name\":\"_initPausedStatus\",\"type\":\"uint256\",\"internalType\":\"uint256\"}],\"outputs\":[],\"stateMutability\":\"nonpayable\"},{\"type\":\"function\",\"name\":\"numPods\",\"inputs\":[],\"outputs\":[{\"name\":\"\",\"type\":\"uint256\",\"internalType\":\"uint256\"}],\"stateMutability\":\"view\"},{\"type\":\"function\",\"name\":\"owner\",\"inputs\":[],\"outputs\":[{\"name\":\"\",\"type\":\"address\",\"internalType\":\"address\"}],\"stateMutability\":\"view\"},{\"type\":\"function\",\"name\":\"ownerToPod\",\"inputs\":[{\"name\":\"\",\"type\":\"address\",\"internalType\":\"address\"}],\"outputs\":[{\"name\":\"\",\"type\":\"address\",\"internalType\":\"contractIEigenPod\"}],\"stateMutability\":\"view\"},{\"type\":\"function\",\"name\":\"pause\",\"inputs\":[{\"name\":\"newPausedStatus\",\"type\":\"uint256\",\"internalType\":\"uint256\"}],\"outputs\":[],\"stateMutability\":\"nonpayable\"},{\"type\":\"function\",\"name\":\"pauseAll\",\"inputs\":[],\"outputs\":[],\"stateMutability\":\"nonpayable\"},{\"type\":\"function\",\"name\":\"paused\",\"inputs\":[{\"name\":\"index\",\"type\":\"uint8\",\"internalType\":\"uint8\"}],\"outputs\":[{\"name\":\"\",\"type\":\"bool\",\"internalType\":\"bool\"}],\"stateMutability\":\"view\"},{\"type\":\"function\",\"name\":\"paused\",\"inputs\":[],\"outputs\":[{\"name\":\"\",\"type\":\"uint256\",\"internalType\":\"uint256\"}],\"stateMutability\":\"view\"},{\"type\":\"function\",\"name\":\"pauserRegistry\",\"inputs\":[],\"outputs\":[{\"name\":\"\",\"type\":\"address\",\"internalType\":\"contractIPauserRegistry\"}],\"stateMutability\":\"view\"},{\"type\":\"function\",\"name\":\"podOwnerShares\",\"inputs\":[{\"name\":\"\",\"type\":\"address\",\"internalType\":\"address\"}],\"outputs\":[{\"name\":\"\",\"type\":\"int256\",\"internalType\":\"int256\"}],\"stateMutability\":\"view\"},{\"type\":\"function\",\"name\":\"recordBeaconChainETHBalanceUpdate\",\"inputs\":[{\"name\":\"podOwner\",\"type\":\"address\",\"internalType\":\"address\"},{\"name\":\"sharesDelta\",\"type\":\"int256\",\"internalType\":\"int256\"}],\"outputs\":[],\"stateMutability\":\"nonpayable\"},{\"type\":\"function\",\"name\":\"removeShares\",\"inputs\":[{\"name\":\"podOwner\",\"type\":\"address\",\"internalType\":\"address\"},{\"name\":\"shares\",\"type\":\"uint256\",\"internalType\":\"uint256\"}],\"outputs\":[],\"stateMutability\":\"nonpayable\"},{\"type\":\"function\",\"name\":\"renounceOwnership\",\"inputs\":[],\"outputs\":[],\"stateMutability\":\"nonpayable\"},{\"type\":\"function\",\"name\":\"setPauserRegistry\",\"inputs\":[{\"name\":\"newPauserRegistry\",\"type\":\"address\",\"internalType\":\"contractIPauserRegistry\"}],\"outputs\":[],\"stateMutability\":\"nonpayable\"},{\"type\":\"function\",\"name\":\"slasher\",\"inputs\":[],\"outputs\":[{\"name\":\"\",\"type\":\"address\",\"internalType\":\"contractISlasher\"}],\"stateMutability\":\"view\"},{\"type\":\"function\",\"name\":\"stake\",\"inputs\":[{\"name\":\"pubkey\",\"type\":\"bytes\",\"internalType\":\"bytes\"},{\"name\":\"signature\",\"type\":\"bytes\",\"internalType\":\"bytes\"},{\"name\":\"depositDataRoot\",\"type\":\"bytes32\",\"internalType\":\"bytes32\"}],\"outputs\":[],\"stateMutability\":\"payable\"},{\"type\":\"function\",\"name\":\"strategyManager\",\"inputs\":[],\"outputs\":[{\"name\":\"\",\"type\":\"address\",\"internalType\":\"contractIStrategyManager\"}],\"stateMutability\":\"view\"},{\"type\":\"function\",\"name\":\"transferOwnership\",\"inputs\":[{\"name\":\"newOwner\",\"type\":\"address\",\"internalType\":\"address\"}],\"outputs\":[],\"stateMutability\":\"nonpayable\"},{\"type\":\"function\",\"name\":\"unpause\",\"inputs\":[{\"name\":\"newPausedStatus\",\"type\":\"uint256\",\"internalType\":\"uint256\"}],\"outputs\":[],\"stateMutability\":\"nonpayable\"},{\"type\":\"function\",\"name\":\"withdrawSharesAsTokens\",\"inputs\":[{\"name\":\"podOwner\",\"type\":\"address\",\"internalType\":\"address\"},{\"name\":\"destination\",\"type\":\"address\",\"internalType\":\"address\"},{\"name\":\"shares\",\"type\":\"uint256\",\"internalType\":\"uint256\"}],\"outputs\":[],\"stateMutability\":\"nonpayable\"},{\"type\":\"event\",\"name\":\"BeaconChainETHDeposited\",\"inputs\":[{\"name\":\"podOwner\",\"type\":\"address\",\"indexed\":true,\"internalType\":\"address\"},{\"name\":\"amount\",\"type\":\"uint256\",\"indexed\":false,\"internalType\":\"uint256\"}],\"anonymous\":false},{\"type\":\"event\",\"name\":\"BeaconChainETHWithdrawalCompleted\",\"inputs\":[{\"name\":\"podOwner\",\"type\":\"address\",\"indexed\":true,\"internalType\":\"address\"},{\"name\":\"shares\",\"type\":\"uint256\",\"indexed\":false,\"internalType\":\"uint256\"},{\"name\":\"nonce\",\"type\":\"uint96\",\"indexed\":false,\"internalType\":\"uint96\"},{\"name\":\"delegatedAddress\",\"type\":\"address\",\"indexed\":false,\"internalType\":\"address\"},{\"name\":\"withdrawer\",\"type\":\"address\",\"indexed\":false,\"internalType\":\"address\"},{\"name\":\"withdrawalRoot\",\"type\":\"bytes32\",\"indexed\":false,\"internalType\":\"bytes32\"}],\"anonymous\":false},{\"type\":\"event\",\"name\":\"Initialized\",\"inputs\":[{\"name\":\"version\",\"type\":\"uint8\",\"indexed\":false,\"internalType\":\"uint8\"}],\"anonymous\":false},{\"type\":\"event\",\"name\":\"NewTotalShares\",\"inputs\":[{\"name\":\"podOwner\",\"type\":\"address\",\"indexed\":true,\"internalType\":\"address\"},{\"name\":\"newTotalShares\",\"type\":\"int256\",\"indexed\":false,\"internalType\":\"int256\"}],\"anonymous\":false},{\"type\":\"event\",\"name\":\"OwnershipTransferred\",\"inputs\":[{\"name\":\"previousOwner\",\"type\":\"address\",\"indexed\":true,\"internalType\":\"address\"},{\"name\":\"newOwner\",\"type\":\"address\",\"indexed\":true,\"internalType\":\"address\"}],\"anonymous\":false},{\"type\":\"event\",\"name\":\"Paused\",\"inputs\":[{\"name\":\"account\",\"type\":\"address\",\"indexed\":true,\"internalType\":\"address\"},{\"name\":\"newPausedStatus\",\"type\":\"uint256\",\"indexed\":false,\"internalType\":\"uint256\"}],\"anonymous\":false},{\"type\":\"event\",\"name\":\"PauserRegistrySet\",\"inputs\":[{\"name\":\"pauserRegistry\",\"type\":\"address\",\"indexed\":false,\"internalType\":\"contractIPauserRegistry\"},{\"name\":\"newPauserRegistry\",\"type\":\"address\",\"indexed\":false,\"internalType\":\"contractIPauserRegistry\"}],\"anonymous\":false},{\"type\":\"event\",\"name\":\"PodDeployed\",\"inputs\":[{\"name\":\"eigenPod\",\"type\":\"address\",\"indexed\":true,\"internalType\":\"address\"},{\"name\":\"podOwner\",\"type\":\"address\",\"indexed\":true,\"internalType\":\"address\"}],\"anonymous\":false},{\"type\":\"event\",\"name\":\"PodSharesUpdated\",\"inputs\":[{\"name\":\"podOwner\",\"type\":\"address\",\"indexed\":true,\"internalType\":\"address\"},{\"name\":\"sharesDelta\",\"type\":\"int256\",\"indexed\":false,\"internalType\":\"int256\"}],\"anonymous\":false},{\"type\":\"event\",\"name\":\"Unpaused\",\"inputs\":[{\"name\":\"account\",\"type\":\"address\",\"indexed\":true,\"internalType\":\"address\"},{\"name\":\"newPausedStatus\",\"type\":\"uint256\",\"indexed\":false,\"internalType\":\"uint256\"}],\"anonymous\":false}]", -} - -// EigenPodManagerABI is the input ABI used to generate the binding from. -// Deprecated: Use EigenPodManagerMetaData.ABI instead. -var EigenPodManagerABI = EigenPodManagerMetaData.ABI - -// EigenPodManager is an auto generated Go binding around an Ethereum contract. -type EigenPodManager struct { - EigenPodManagerCaller // Read-only binding to the contract - EigenPodManagerTransactor // Write-only binding to the contract - EigenPodManagerFilterer // Log filterer for contract events -} - -// EigenPodManagerCaller is an auto generated read-only Go binding around an Ethereum contract. -type EigenPodManagerCaller struct { - contract *bind.BoundContract // Generic contract wrapper for the low level calls -} - -// EigenPodManagerTransactor is an auto generated write-only Go binding around an Ethereum contract. -type EigenPodManagerTransactor struct { - contract *bind.BoundContract // Generic contract wrapper for the low level calls -} - -// EigenPodManagerFilterer is an auto generated log filtering Go binding around an Ethereum contract events. -type EigenPodManagerFilterer struct { - contract *bind.BoundContract // Generic contract wrapper for the low level calls -} - -// EigenPodManagerSession is an auto generated Go binding around an Ethereum contract, -// with pre-set call and transact options. -type EigenPodManagerSession struct { - Contract *EigenPodManager // Generic contract binding to set the session for - CallOpts bind.CallOpts // Call options to use throughout this session - TransactOpts bind.TransactOpts // Transaction auth options to use throughout this session -} - -// EigenPodManagerCallerSession is an auto generated read-only Go binding around an Ethereum contract, -// with pre-set call options. -type EigenPodManagerCallerSession struct { - Contract *EigenPodManagerCaller // Generic contract caller binding to set the session for - CallOpts bind.CallOpts // Call options to use throughout this session -} - -// EigenPodManagerTransactorSession is an auto generated write-only Go binding around an Ethereum contract, -// with pre-set transact options. -type EigenPodManagerTransactorSession struct { - Contract *EigenPodManagerTransactor // Generic contract transactor binding to set the session for - TransactOpts bind.TransactOpts // Transaction auth options to use throughout this session -} - -// EigenPodManagerRaw is an auto generated low-level Go binding around an Ethereum contract. -type EigenPodManagerRaw struct { - Contract *EigenPodManager // Generic contract binding to access the raw methods on -} - -// EigenPodManagerCallerRaw is an auto generated low-level read-only Go binding around an Ethereum contract. -type EigenPodManagerCallerRaw struct { - Contract *EigenPodManagerCaller // Generic read-only contract binding to access the raw methods on -} - -// EigenPodManagerTransactorRaw is an auto generated low-level write-only Go binding around an Ethereum contract. -type EigenPodManagerTransactorRaw struct { - Contract *EigenPodManagerTransactor // Generic write-only contract binding to access the raw methods on -} - -// NewEigenPodManager creates a new instance of EigenPodManager, bound to a specific deployed contract. -func NewEigenPodManager(address common.Address, backend bind.ContractBackend) (*EigenPodManager, error) { - contract, err := bindEigenPodManager(address, backend, backend, backend) - if err != nil { - return nil, err - } - return &EigenPodManager{EigenPodManagerCaller: EigenPodManagerCaller{contract: contract}, EigenPodManagerTransactor: EigenPodManagerTransactor{contract: contract}, EigenPodManagerFilterer: EigenPodManagerFilterer{contract: contract}}, nil -} - -// NewEigenPodManagerCaller creates a new read-only instance of EigenPodManager, bound to a specific deployed contract. -func NewEigenPodManagerCaller(address common.Address, caller bind.ContractCaller) (*EigenPodManagerCaller, error) { - contract, err := bindEigenPodManager(address, caller, nil, nil) - if err != nil { - return nil, err - } - return &EigenPodManagerCaller{contract: contract}, nil -} - -// NewEigenPodManagerTransactor creates a new write-only instance of EigenPodManager, bound to a specific deployed contract. -func NewEigenPodManagerTransactor(address common.Address, transactor bind.ContractTransactor) (*EigenPodManagerTransactor, error) { - contract, err := bindEigenPodManager(address, nil, transactor, nil) - if err != nil { - return nil, err - } - return &EigenPodManagerTransactor{contract: contract}, nil -} - -// NewEigenPodManagerFilterer creates a new log filterer instance of EigenPodManager, bound to a specific deployed contract. -func NewEigenPodManagerFilterer(address common.Address, filterer bind.ContractFilterer) (*EigenPodManagerFilterer, error) { - contract, err := bindEigenPodManager(address, nil, nil, filterer) - if err != nil { - return nil, err - } - return &EigenPodManagerFilterer{contract: contract}, nil -} - -// bindEigenPodManager binds a generic wrapper to an already deployed contract. -func bindEigenPodManager(address common.Address, caller bind.ContractCaller, transactor bind.ContractTransactor, filterer bind.ContractFilterer) (*bind.BoundContract, error) { - parsed, err := EigenPodManagerMetaData.GetAbi() - if err != nil { - return nil, err - } - return bind.NewBoundContract(address, *parsed, caller, transactor, filterer), nil -} - -// Call invokes the (constant) contract method with params as input values and -// sets the output to result. The result type might be a single field for simple -// returns, a slice of interfaces for anonymous returns and a struct for named -// returns. -func (_EigenPodManager *EigenPodManagerRaw) Call(opts *bind.CallOpts, result *[]interface{}, method string, params ...interface{}) error { - return _EigenPodManager.Contract.EigenPodManagerCaller.contract.Call(opts, result, method, params...) -} - -// Transfer initiates a plain transaction to move funds to the contract, calling -// its default method if one is available. -func (_EigenPodManager *EigenPodManagerRaw) Transfer(opts *bind.TransactOpts) (*types.Transaction, error) { - return _EigenPodManager.Contract.EigenPodManagerTransactor.contract.Transfer(opts) -} - -// Transact invokes the (paid) contract method with params as input values. -func (_EigenPodManager *EigenPodManagerRaw) Transact(opts *bind.TransactOpts, method string, params ...interface{}) (*types.Transaction, error) { - return _EigenPodManager.Contract.EigenPodManagerTransactor.contract.Transact(opts, method, params...) -} - -// Call invokes the (constant) contract method with params as input values and -// sets the output to result. The result type might be a single field for simple -// returns, a slice of interfaces for anonymous returns and a struct for named -// returns. -func (_EigenPodManager *EigenPodManagerCallerRaw) Call(opts *bind.CallOpts, result *[]interface{}, method string, params ...interface{}) error { - return _EigenPodManager.Contract.contract.Call(opts, result, method, params...) -} - -// Transfer initiates a plain transaction to move funds to the contract, calling -// its default method if one is available. -func (_EigenPodManager *EigenPodManagerTransactorRaw) Transfer(opts *bind.TransactOpts) (*types.Transaction, error) { - return _EigenPodManager.Contract.contract.Transfer(opts) -} - -// Transact invokes the (paid) contract method with params as input values. -func (_EigenPodManager *EigenPodManagerTransactorRaw) Transact(opts *bind.TransactOpts, method string, params ...interface{}) (*types.Transaction, error) { - return _EigenPodManager.Contract.contract.Transact(opts, method, params...) -} - -// BeaconChainETHStrategy is a free data retrieval call binding the contract method 0x9104c319. -// -// Solidity: function beaconChainETHStrategy() view returns(address) -func (_EigenPodManager *EigenPodManagerCaller) BeaconChainETHStrategy(opts *bind.CallOpts) (common.Address, error) { - var out []interface{} - err := _EigenPodManager.contract.Call(opts, &out, "beaconChainETHStrategy") - - if err != nil { - return *new(common.Address), err - } - - out0 := *abi.ConvertType(out[0], new(common.Address)).(*common.Address) - - return out0, err - -} - -// BeaconChainETHStrategy is a free data retrieval call binding the contract method 0x9104c319. -// -// Solidity: function beaconChainETHStrategy() view returns(address) -func (_EigenPodManager *EigenPodManagerSession) BeaconChainETHStrategy() (common.Address, error) { - return _EigenPodManager.Contract.BeaconChainETHStrategy(&_EigenPodManager.CallOpts) -} - -// BeaconChainETHStrategy is a free data retrieval call binding the contract method 0x9104c319. -// -// Solidity: function beaconChainETHStrategy() view returns(address) -func (_EigenPodManager *EigenPodManagerCallerSession) BeaconChainETHStrategy() (common.Address, error) { - return _EigenPodManager.Contract.BeaconChainETHStrategy(&_EigenPodManager.CallOpts) -} - -// DelegationManager is a free data retrieval call binding the contract method 0xea4d3c9b. -// -// Solidity: function delegationManager() view returns(address) -func (_EigenPodManager *EigenPodManagerCaller) DelegationManager(opts *bind.CallOpts) (common.Address, error) { - var out []interface{} - err := _EigenPodManager.contract.Call(opts, &out, "delegationManager") - - if err != nil { - return *new(common.Address), err - } - - out0 := *abi.ConvertType(out[0], new(common.Address)).(*common.Address) - - return out0, err - -} - -// DelegationManager is a free data retrieval call binding the contract method 0xea4d3c9b. -// -// Solidity: function delegationManager() view returns(address) -func (_EigenPodManager *EigenPodManagerSession) DelegationManager() (common.Address, error) { - return _EigenPodManager.Contract.DelegationManager(&_EigenPodManager.CallOpts) -} - -// DelegationManager is a free data retrieval call binding the contract method 0xea4d3c9b. -// -// Solidity: function delegationManager() view returns(address) -func (_EigenPodManager *EigenPodManagerCallerSession) DelegationManager() (common.Address, error) { - return _EigenPodManager.Contract.DelegationManager(&_EigenPodManager.CallOpts) -} - -// EigenPodBeacon is a free data retrieval call binding the contract method 0x292b7b2b. -// -// Solidity: function eigenPodBeacon() view returns(address) -func (_EigenPodManager *EigenPodManagerCaller) EigenPodBeacon(opts *bind.CallOpts) (common.Address, error) { - var out []interface{} - err := _EigenPodManager.contract.Call(opts, &out, "eigenPodBeacon") - - if err != nil { - return *new(common.Address), err - } - - out0 := *abi.ConvertType(out[0], new(common.Address)).(*common.Address) - - return out0, err - -} - -// EigenPodBeacon is a free data retrieval call binding the contract method 0x292b7b2b. -// -// Solidity: function eigenPodBeacon() view returns(address) -func (_EigenPodManager *EigenPodManagerSession) EigenPodBeacon() (common.Address, error) { - return _EigenPodManager.Contract.EigenPodBeacon(&_EigenPodManager.CallOpts) -} - -// EigenPodBeacon is a free data retrieval call binding the contract method 0x292b7b2b. -// -// Solidity: function eigenPodBeacon() view returns(address) -func (_EigenPodManager *EigenPodManagerCallerSession) EigenPodBeacon() (common.Address, error) { - return _EigenPodManager.Contract.EigenPodBeacon(&_EigenPodManager.CallOpts) -} - -// EthPOS is a free data retrieval call binding the contract method 0x74cdd798. -// -// Solidity: function ethPOS() view returns(address) -func (_EigenPodManager *EigenPodManagerCaller) EthPOS(opts *bind.CallOpts) (common.Address, error) { - var out []interface{} - err := _EigenPodManager.contract.Call(opts, &out, "ethPOS") - - if err != nil { - return *new(common.Address), err - } - - out0 := *abi.ConvertType(out[0], new(common.Address)).(*common.Address) - - return out0, err - -} - -// EthPOS is a free data retrieval call binding the contract method 0x74cdd798. -// -// Solidity: function ethPOS() view returns(address) -func (_EigenPodManager *EigenPodManagerSession) EthPOS() (common.Address, error) { - return _EigenPodManager.Contract.EthPOS(&_EigenPodManager.CallOpts) -} - -// EthPOS is a free data retrieval call binding the contract method 0x74cdd798. -// -// Solidity: function ethPOS() view returns(address) -func (_EigenPodManager *EigenPodManagerCallerSession) EthPOS() (common.Address, error) { - return _EigenPodManager.Contract.EthPOS(&_EigenPodManager.CallOpts) -} - -// GetPod is a free data retrieval call binding the contract method 0xa38406a3. -// -// Solidity: function getPod(address podOwner) view returns(address) -func (_EigenPodManager *EigenPodManagerCaller) GetPod(opts *bind.CallOpts, podOwner common.Address) (common.Address, error) { - var out []interface{} - err := _EigenPodManager.contract.Call(opts, &out, "getPod", podOwner) - - if err != nil { - return *new(common.Address), err - } - - out0 := *abi.ConvertType(out[0], new(common.Address)).(*common.Address) - - return out0, err - -} - -// GetPod is a free data retrieval call binding the contract method 0xa38406a3. -// -// Solidity: function getPod(address podOwner) view returns(address) -func (_EigenPodManager *EigenPodManagerSession) GetPod(podOwner common.Address) (common.Address, error) { - return _EigenPodManager.Contract.GetPod(&_EigenPodManager.CallOpts, podOwner) -} - -// GetPod is a free data retrieval call binding the contract method 0xa38406a3. -// -// Solidity: function getPod(address podOwner) view returns(address) -func (_EigenPodManager *EigenPodManagerCallerSession) GetPod(podOwner common.Address) (common.Address, error) { - return _EigenPodManager.Contract.GetPod(&_EigenPodManager.CallOpts, podOwner) -} - -// HasPod is a free data retrieval call binding the contract method 0xf6848d24. -// -// Solidity: function hasPod(address podOwner) view returns(bool) -func (_EigenPodManager *EigenPodManagerCaller) HasPod(opts *bind.CallOpts, podOwner common.Address) (bool, error) { - var out []interface{} - err := _EigenPodManager.contract.Call(opts, &out, "hasPod", podOwner) - - if err != nil { - return *new(bool), err - } - - out0 := *abi.ConvertType(out[0], new(bool)).(*bool) - - return out0, err - -} - -// HasPod is a free data retrieval call binding the contract method 0xf6848d24. -// -// Solidity: function hasPod(address podOwner) view returns(bool) -func (_EigenPodManager *EigenPodManagerSession) HasPod(podOwner common.Address) (bool, error) { - return _EigenPodManager.Contract.HasPod(&_EigenPodManager.CallOpts, podOwner) -} - -// HasPod is a free data retrieval call binding the contract method 0xf6848d24. -// -// Solidity: function hasPod(address podOwner) view returns(bool) -func (_EigenPodManager *EigenPodManagerCallerSession) HasPod(podOwner common.Address) (bool, error) { - return _EigenPodManager.Contract.HasPod(&_EigenPodManager.CallOpts, podOwner) -} - -// NumPods is a free data retrieval call binding the contract method 0xa6a509be. -// -// Solidity: function numPods() view returns(uint256) -func (_EigenPodManager *EigenPodManagerCaller) NumPods(opts *bind.CallOpts) (*big.Int, error) { - var out []interface{} - err := _EigenPodManager.contract.Call(opts, &out, "numPods") - - if err != nil { - return *new(*big.Int), err - } - - out0 := *abi.ConvertType(out[0], new(*big.Int)).(**big.Int) - - return out0, err - -} - -// NumPods is a free data retrieval call binding the contract method 0xa6a509be. -// -// Solidity: function numPods() view returns(uint256) -func (_EigenPodManager *EigenPodManagerSession) NumPods() (*big.Int, error) { - return _EigenPodManager.Contract.NumPods(&_EigenPodManager.CallOpts) -} - -// NumPods is a free data retrieval call binding the contract method 0xa6a509be. -// -// Solidity: function numPods() view returns(uint256) -func (_EigenPodManager *EigenPodManagerCallerSession) NumPods() (*big.Int, error) { - return _EigenPodManager.Contract.NumPods(&_EigenPodManager.CallOpts) -} - -// Owner is a free data retrieval call binding the contract method 0x8da5cb5b. -// -// Solidity: function owner() view returns(address) -func (_EigenPodManager *EigenPodManagerCaller) Owner(opts *bind.CallOpts) (common.Address, error) { - var out []interface{} - err := _EigenPodManager.contract.Call(opts, &out, "owner") - - if err != nil { - return *new(common.Address), err - } - - out0 := *abi.ConvertType(out[0], new(common.Address)).(*common.Address) - - return out0, err - -} - -// Owner is a free data retrieval call binding the contract method 0x8da5cb5b. -// -// Solidity: function owner() view returns(address) -func (_EigenPodManager *EigenPodManagerSession) Owner() (common.Address, error) { - return _EigenPodManager.Contract.Owner(&_EigenPodManager.CallOpts) -} - -// Owner is a free data retrieval call binding the contract method 0x8da5cb5b. -// -// Solidity: function owner() view returns(address) -func (_EigenPodManager *EigenPodManagerCallerSession) Owner() (common.Address, error) { - return _EigenPodManager.Contract.Owner(&_EigenPodManager.CallOpts) -} - -// OwnerToPod is a free data retrieval call binding the contract method 0x9ba06275. -// -// Solidity: function ownerToPod(address ) view returns(address) -func (_EigenPodManager *EigenPodManagerCaller) OwnerToPod(opts *bind.CallOpts, arg0 common.Address) (common.Address, error) { - var out []interface{} - err := _EigenPodManager.contract.Call(opts, &out, "ownerToPod", arg0) - - if err != nil { - return *new(common.Address), err - } - - out0 := *abi.ConvertType(out[0], new(common.Address)).(*common.Address) - - return out0, err - -} - -// OwnerToPod is a free data retrieval call binding the contract method 0x9ba06275. -// -// Solidity: function ownerToPod(address ) view returns(address) -func (_EigenPodManager *EigenPodManagerSession) OwnerToPod(arg0 common.Address) (common.Address, error) { - return _EigenPodManager.Contract.OwnerToPod(&_EigenPodManager.CallOpts, arg0) -} - -// OwnerToPod is a free data retrieval call binding the contract method 0x9ba06275. -// -// Solidity: function ownerToPod(address ) view returns(address) -func (_EigenPodManager *EigenPodManagerCallerSession) OwnerToPod(arg0 common.Address) (common.Address, error) { - return _EigenPodManager.Contract.OwnerToPod(&_EigenPodManager.CallOpts, arg0) -} - -// Paused is a free data retrieval call binding the contract method 0x5ac86ab7. -// -// Solidity: function paused(uint8 index) view returns(bool) -func (_EigenPodManager *EigenPodManagerCaller) Paused(opts *bind.CallOpts, index uint8) (bool, error) { - var out []interface{} - err := _EigenPodManager.contract.Call(opts, &out, "paused", index) - - if err != nil { - return *new(bool), err - } - - out0 := *abi.ConvertType(out[0], new(bool)).(*bool) - - return out0, err - -} - -// Paused is a free data retrieval call binding the contract method 0x5ac86ab7. -// -// Solidity: function paused(uint8 index) view returns(bool) -func (_EigenPodManager *EigenPodManagerSession) Paused(index uint8) (bool, error) { - return _EigenPodManager.Contract.Paused(&_EigenPodManager.CallOpts, index) -} - -// Paused is a free data retrieval call binding the contract method 0x5ac86ab7. -// -// Solidity: function paused(uint8 index) view returns(bool) -func (_EigenPodManager *EigenPodManagerCallerSession) Paused(index uint8) (bool, error) { - return _EigenPodManager.Contract.Paused(&_EigenPodManager.CallOpts, index) -} - -// Paused0 is a free data retrieval call binding the contract method 0x5c975abb. -// -// Solidity: function paused() view returns(uint256) -func (_EigenPodManager *EigenPodManagerCaller) Paused0(opts *bind.CallOpts) (*big.Int, error) { - var out []interface{} - err := _EigenPodManager.contract.Call(opts, &out, "paused0") - - if err != nil { - return *new(*big.Int), err - } - - out0 := *abi.ConvertType(out[0], new(*big.Int)).(**big.Int) - - return out0, err - -} - -// Paused0 is a free data retrieval call binding the contract method 0x5c975abb. -// -// Solidity: function paused() view returns(uint256) -func (_EigenPodManager *EigenPodManagerSession) Paused0() (*big.Int, error) { - return _EigenPodManager.Contract.Paused0(&_EigenPodManager.CallOpts) -} - -// Paused0 is a free data retrieval call binding the contract method 0x5c975abb. -// -// Solidity: function paused() view returns(uint256) -func (_EigenPodManager *EigenPodManagerCallerSession) Paused0() (*big.Int, error) { - return _EigenPodManager.Contract.Paused0(&_EigenPodManager.CallOpts) -} - -// PauserRegistry is a free data retrieval call binding the contract method 0x886f1195. -// -// Solidity: function pauserRegistry() view returns(address) -func (_EigenPodManager *EigenPodManagerCaller) PauserRegistry(opts *bind.CallOpts) (common.Address, error) { - var out []interface{} - err := _EigenPodManager.contract.Call(opts, &out, "pauserRegistry") - - if err != nil { - return *new(common.Address), err - } - - out0 := *abi.ConvertType(out[0], new(common.Address)).(*common.Address) - - return out0, err - -} - -// PauserRegistry is a free data retrieval call binding the contract method 0x886f1195. -// -// Solidity: function pauserRegistry() view returns(address) -func (_EigenPodManager *EigenPodManagerSession) PauserRegistry() (common.Address, error) { - return _EigenPodManager.Contract.PauserRegistry(&_EigenPodManager.CallOpts) -} - -// PauserRegistry is a free data retrieval call binding the contract method 0x886f1195. -// -// Solidity: function pauserRegistry() view returns(address) -func (_EigenPodManager *EigenPodManagerCallerSession) PauserRegistry() (common.Address, error) { - return _EigenPodManager.Contract.PauserRegistry(&_EigenPodManager.CallOpts) -} - -// PodOwnerShares is a free data retrieval call binding the contract method 0x60f4062b. -// -// Solidity: function podOwnerShares(address ) view returns(int256) -func (_EigenPodManager *EigenPodManagerCaller) PodOwnerShares(opts *bind.CallOpts, arg0 common.Address) (*big.Int, error) { - var out []interface{} - err := _EigenPodManager.contract.Call(opts, &out, "podOwnerShares", arg0) - - if err != nil { - return *new(*big.Int), err - } - - out0 := *abi.ConvertType(out[0], new(*big.Int)).(**big.Int) - - return out0, err - -} - -// PodOwnerShares is a free data retrieval call binding the contract method 0x60f4062b. -// -// Solidity: function podOwnerShares(address ) view returns(int256) -func (_EigenPodManager *EigenPodManagerSession) PodOwnerShares(arg0 common.Address) (*big.Int, error) { - return _EigenPodManager.Contract.PodOwnerShares(&_EigenPodManager.CallOpts, arg0) -} - -// PodOwnerShares is a free data retrieval call binding the contract method 0x60f4062b. -// -// Solidity: function podOwnerShares(address ) view returns(int256) -func (_EigenPodManager *EigenPodManagerCallerSession) PodOwnerShares(arg0 common.Address) (*big.Int, error) { - return _EigenPodManager.Contract.PodOwnerShares(&_EigenPodManager.CallOpts, arg0) -} - -// Slasher is a free data retrieval call binding the contract method 0xb1344271. -// -// Solidity: function slasher() view returns(address) -func (_EigenPodManager *EigenPodManagerCaller) Slasher(opts *bind.CallOpts) (common.Address, error) { - var out []interface{} - err := _EigenPodManager.contract.Call(opts, &out, "slasher") - - if err != nil { - return *new(common.Address), err - } - - out0 := *abi.ConvertType(out[0], new(common.Address)).(*common.Address) - - return out0, err - -} - -// Slasher is a free data retrieval call binding the contract method 0xb1344271. -// -// Solidity: function slasher() view returns(address) -func (_EigenPodManager *EigenPodManagerSession) Slasher() (common.Address, error) { - return _EigenPodManager.Contract.Slasher(&_EigenPodManager.CallOpts) -} - -// Slasher is a free data retrieval call binding the contract method 0xb1344271. -// -// Solidity: function slasher() view returns(address) -func (_EigenPodManager *EigenPodManagerCallerSession) Slasher() (common.Address, error) { - return _EigenPodManager.Contract.Slasher(&_EigenPodManager.CallOpts) -} - -// StrategyManager is a free data retrieval call binding the contract method 0x39b70e38. -// -// Solidity: function strategyManager() view returns(address) -func (_EigenPodManager *EigenPodManagerCaller) StrategyManager(opts *bind.CallOpts) (common.Address, error) { - var out []interface{} - err := _EigenPodManager.contract.Call(opts, &out, "strategyManager") - - if err != nil { - return *new(common.Address), err - } - - out0 := *abi.ConvertType(out[0], new(common.Address)).(*common.Address) - - return out0, err - -} - -// StrategyManager is a free data retrieval call binding the contract method 0x39b70e38. -// -// Solidity: function strategyManager() view returns(address) -func (_EigenPodManager *EigenPodManagerSession) StrategyManager() (common.Address, error) { - return _EigenPodManager.Contract.StrategyManager(&_EigenPodManager.CallOpts) -} - -// StrategyManager is a free data retrieval call binding the contract method 0x39b70e38. -// -// Solidity: function strategyManager() view returns(address) -func (_EigenPodManager *EigenPodManagerCallerSession) StrategyManager() (common.Address, error) { - return _EigenPodManager.Contract.StrategyManager(&_EigenPodManager.CallOpts) -} - -// AddShares is a paid mutator transaction binding the contract method 0x0e81073c. -// -// Solidity: function addShares(address podOwner, uint256 shares) returns(uint256) -func (_EigenPodManager *EigenPodManagerTransactor) AddShares(opts *bind.TransactOpts, podOwner common.Address, shares *big.Int) (*types.Transaction, error) { - return _EigenPodManager.contract.Transact(opts, "addShares", podOwner, shares) -} - -// AddShares is a paid mutator transaction binding the contract method 0x0e81073c. -// -// Solidity: function addShares(address podOwner, uint256 shares) returns(uint256) -func (_EigenPodManager *EigenPodManagerSession) AddShares(podOwner common.Address, shares *big.Int) (*types.Transaction, error) { - return _EigenPodManager.Contract.AddShares(&_EigenPodManager.TransactOpts, podOwner, shares) -} - -// AddShares is a paid mutator transaction binding the contract method 0x0e81073c. -// -// Solidity: function addShares(address podOwner, uint256 shares) returns(uint256) -func (_EigenPodManager *EigenPodManagerTransactorSession) AddShares(podOwner common.Address, shares *big.Int) (*types.Transaction, error) { - return _EigenPodManager.Contract.AddShares(&_EigenPodManager.TransactOpts, podOwner, shares) -} - -// CreatePod is a paid mutator transaction binding the contract method 0x84d81062. -// -// Solidity: function createPod() returns(address) -func (_EigenPodManager *EigenPodManagerTransactor) CreatePod(opts *bind.TransactOpts) (*types.Transaction, error) { - return _EigenPodManager.contract.Transact(opts, "createPod") -} - -// CreatePod is a paid mutator transaction binding the contract method 0x84d81062. -// -// Solidity: function createPod() returns(address) -func (_EigenPodManager *EigenPodManagerSession) CreatePod() (*types.Transaction, error) { - return _EigenPodManager.Contract.CreatePod(&_EigenPodManager.TransactOpts) -} - -// CreatePod is a paid mutator transaction binding the contract method 0x84d81062. -// -// Solidity: function createPod() returns(address) -func (_EigenPodManager *EigenPodManagerTransactorSession) CreatePod() (*types.Transaction, error) { - return _EigenPodManager.Contract.CreatePod(&_EigenPodManager.TransactOpts) -} - -// Initialize is a paid mutator transaction binding the contract method 0x1794bb3c. -// -// Solidity: function initialize(address initialOwner, address _pauserRegistry, uint256 _initPausedStatus) returns() -func (_EigenPodManager *EigenPodManagerTransactor) Initialize(opts *bind.TransactOpts, initialOwner common.Address, _pauserRegistry common.Address, _initPausedStatus *big.Int) (*types.Transaction, error) { - return _EigenPodManager.contract.Transact(opts, "initialize", initialOwner, _pauserRegistry, _initPausedStatus) -} - -// Initialize is a paid mutator transaction binding the contract method 0x1794bb3c. -// -// Solidity: function initialize(address initialOwner, address _pauserRegistry, uint256 _initPausedStatus) returns() -func (_EigenPodManager *EigenPodManagerSession) Initialize(initialOwner common.Address, _pauserRegistry common.Address, _initPausedStatus *big.Int) (*types.Transaction, error) { - return _EigenPodManager.Contract.Initialize(&_EigenPodManager.TransactOpts, initialOwner, _pauserRegistry, _initPausedStatus) -} - -// Initialize is a paid mutator transaction binding the contract method 0x1794bb3c. -// -// Solidity: function initialize(address initialOwner, address _pauserRegistry, uint256 _initPausedStatus) returns() -func (_EigenPodManager *EigenPodManagerTransactorSession) Initialize(initialOwner common.Address, _pauserRegistry common.Address, _initPausedStatus *big.Int) (*types.Transaction, error) { - return _EigenPodManager.Contract.Initialize(&_EigenPodManager.TransactOpts, initialOwner, _pauserRegistry, _initPausedStatus) -} - -// Pause is a paid mutator transaction binding the contract method 0x136439dd. -// -// Solidity: function pause(uint256 newPausedStatus) returns() -func (_EigenPodManager *EigenPodManagerTransactor) Pause(opts *bind.TransactOpts, newPausedStatus *big.Int) (*types.Transaction, error) { - return _EigenPodManager.contract.Transact(opts, "pause", newPausedStatus) -} - -// Pause is a paid mutator transaction binding the contract method 0x136439dd. -// -// Solidity: function pause(uint256 newPausedStatus) returns() -func (_EigenPodManager *EigenPodManagerSession) Pause(newPausedStatus *big.Int) (*types.Transaction, error) { - return _EigenPodManager.Contract.Pause(&_EigenPodManager.TransactOpts, newPausedStatus) -} - -// Pause is a paid mutator transaction binding the contract method 0x136439dd. -// -// Solidity: function pause(uint256 newPausedStatus) returns() -func (_EigenPodManager *EigenPodManagerTransactorSession) Pause(newPausedStatus *big.Int) (*types.Transaction, error) { - return _EigenPodManager.Contract.Pause(&_EigenPodManager.TransactOpts, newPausedStatus) -} - -// PauseAll is a paid mutator transaction binding the contract method 0x595c6a67. -// -// Solidity: function pauseAll() returns() -func (_EigenPodManager *EigenPodManagerTransactor) PauseAll(opts *bind.TransactOpts) (*types.Transaction, error) { - return _EigenPodManager.contract.Transact(opts, "pauseAll") -} - -// PauseAll is a paid mutator transaction binding the contract method 0x595c6a67. -// -// Solidity: function pauseAll() returns() -func (_EigenPodManager *EigenPodManagerSession) PauseAll() (*types.Transaction, error) { - return _EigenPodManager.Contract.PauseAll(&_EigenPodManager.TransactOpts) -} - -// PauseAll is a paid mutator transaction binding the contract method 0x595c6a67. -// -// Solidity: function pauseAll() returns() -func (_EigenPodManager *EigenPodManagerTransactorSession) PauseAll() (*types.Transaction, error) { - return _EigenPodManager.Contract.PauseAll(&_EigenPodManager.TransactOpts) -} - -// RecordBeaconChainETHBalanceUpdate is a paid mutator transaction binding the contract method 0xc2c51c40. -// -// Solidity: function recordBeaconChainETHBalanceUpdate(address podOwner, int256 sharesDelta) returns() -func (_EigenPodManager *EigenPodManagerTransactor) RecordBeaconChainETHBalanceUpdate(opts *bind.TransactOpts, podOwner common.Address, sharesDelta *big.Int) (*types.Transaction, error) { - return _EigenPodManager.contract.Transact(opts, "recordBeaconChainETHBalanceUpdate", podOwner, sharesDelta) -} - -// RecordBeaconChainETHBalanceUpdate is a paid mutator transaction binding the contract method 0xc2c51c40. -// -// Solidity: function recordBeaconChainETHBalanceUpdate(address podOwner, int256 sharesDelta) returns() -func (_EigenPodManager *EigenPodManagerSession) RecordBeaconChainETHBalanceUpdate(podOwner common.Address, sharesDelta *big.Int) (*types.Transaction, error) { - return _EigenPodManager.Contract.RecordBeaconChainETHBalanceUpdate(&_EigenPodManager.TransactOpts, podOwner, sharesDelta) -} - -// RecordBeaconChainETHBalanceUpdate is a paid mutator transaction binding the contract method 0xc2c51c40. -// -// Solidity: function recordBeaconChainETHBalanceUpdate(address podOwner, int256 sharesDelta) returns() -func (_EigenPodManager *EigenPodManagerTransactorSession) RecordBeaconChainETHBalanceUpdate(podOwner common.Address, sharesDelta *big.Int) (*types.Transaction, error) { - return _EigenPodManager.Contract.RecordBeaconChainETHBalanceUpdate(&_EigenPodManager.TransactOpts, podOwner, sharesDelta) -} - -// RemoveShares is a paid mutator transaction binding the contract method 0xbeffbb89. -// -// Solidity: function removeShares(address podOwner, uint256 shares) returns() -func (_EigenPodManager *EigenPodManagerTransactor) RemoveShares(opts *bind.TransactOpts, podOwner common.Address, shares *big.Int) (*types.Transaction, error) { - return _EigenPodManager.contract.Transact(opts, "removeShares", podOwner, shares) -} - -// RemoveShares is a paid mutator transaction binding the contract method 0xbeffbb89. -// -// Solidity: function removeShares(address podOwner, uint256 shares) returns() -func (_EigenPodManager *EigenPodManagerSession) RemoveShares(podOwner common.Address, shares *big.Int) (*types.Transaction, error) { - return _EigenPodManager.Contract.RemoveShares(&_EigenPodManager.TransactOpts, podOwner, shares) -} - -// RemoveShares is a paid mutator transaction binding the contract method 0xbeffbb89. -// -// Solidity: function removeShares(address podOwner, uint256 shares) returns() -func (_EigenPodManager *EigenPodManagerTransactorSession) RemoveShares(podOwner common.Address, shares *big.Int) (*types.Transaction, error) { - return _EigenPodManager.Contract.RemoveShares(&_EigenPodManager.TransactOpts, podOwner, shares) -} - -// RenounceOwnership is a paid mutator transaction binding the contract method 0x715018a6. -// -// Solidity: function renounceOwnership() returns() -func (_EigenPodManager *EigenPodManagerTransactor) RenounceOwnership(opts *bind.TransactOpts) (*types.Transaction, error) { - return _EigenPodManager.contract.Transact(opts, "renounceOwnership") -} - -// RenounceOwnership is a paid mutator transaction binding the contract method 0x715018a6. -// -// Solidity: function renounceOwnership() returns() -func (_EigenPodManager *EigenPodManagerSession) RenounceOwnership() (*types.Transaction, error) { - return _EigenPodManager.Contract.RenounceOwnership(&_EigenPodManager.TransactOpts) -} - -// RenounceOwnership is a paid mutator transaction binding the contract method 0x715018a6. -// -// Solidity: function renounceOwnership() returns() -func (_EigenPodManager *EigenPodManagerTransactorSession) RenounceOwnership() (*types.Transaction, error) { - return _EigenPodManager.Contract.RenounceOwnership(&_EigenPodManager.TransactOpts) -} - -// SetPauserRegistry is a paid mutator transaction binding the contract method 0x10d67a2f. -// -// Solidity: function setPauserRegistry(address newPauserRegistry) returns() -func (_EigenPodManager *EigenPodManagerTransactor) SetPauserRegistry(opts *bind.TransactOpts, newPauserRegistry common.Address) (*types.Transaction, error) { - return _EigenPodManager.contract.Transact(opts, "setPauserRegistry", newPauserRegistry) -} - -// SetPauserRegistry is a paid mutator transaction binding the contract method 0x10d67a2f. -// -// Solidity: function setPauserRegistry(address newPauserRegistry) returns() -func (_EigenPodManager *EigenPodManagerSession) SetPauserRegistry(newPauserRegistry common.Address) (*types.Transaction, error) { - return _EigenPodManager.Contract.SetPauserRegistry(&_EigenPodManager.TransactOpts, newPauserRegistry) -} - -// SetPauserRegistry is a paid mutator transaction binding the contract method 0x10d67a2f. -// -// Solidity: function setPauserRegistry(address newPauserRegistry) returns() -func (_EigenPodManager *EigenPodManagerTransactorSession) SetPauserRegistry(newPauserRegistry common.Address) (*types.Transaction, error) { - return _EigenPodManager.Contract.SetPauserRegistry(&_EigenPodManager.TransactOpts, newPauserRegistry) -} - -// Stake is a paid mutator transaction binding the contract method 0x9b4e4634. -// -// Solidity: function stake(bytes pubkey, bytes signature, bytes32 depositDataRoot) payable returns() -func (_EigenPodManager *EigenPodManagerTransactor) Stake(opts *bind.TransactOpts, pubkey []byte, signature []byte, depositDataRoot [32]byte) (*types.Transaction, error) { - return _EigenPodManager.contract.Transact(opts, "stake", pubkey, signature, depositDataRoot) -} - -// Stake is a paid mutator transaction binding the contract method 0x9b4e4634. -// -// Solidity: function stake(bytes pubkey, bytes signature, bytes32 depositDataRoot) payable returns() -func (_EigenPodManager *EigenPodManagerSession) Stake(pubkey []byte, signature []byte, depositDataRoot [32]byte) (*types.Transaction, error) { - return _EigenPodManager.Contract.Stake(&_EigenPodManager.TransactOpts, pubkey, signature, depositDataRoot) -} - -// Stake is a paid mutator transaction binding the contract method 0x9b4e4634. -// -// Solidity: function stake(bytes pubkey, bytes signature, bytes32 depositDataRoot) payable returns() -func (_EigenPodManager *EigenPodManagerTransactorSession) Stake(pubkey []byte, signature []byte, depositDataRoot [32]byte) (*types.Transaction, error) { - return _EigenPodManager.Contract.Stake(&_EigenPodManager.TransactOpts, pubkey, signature, depositDataRoot) -} - -// TransferOwnership is a paid mutator transaction binding the contract method 0xf2fde38b. -// -// Solidity: function transferOwnership(address newOwner) returns() -func (_EigenPodManager *EigenPodManagerTransactor) TransferOwnership(opts *bind.TransactOpts, newOwner common.Address) (*types.Transaction, error) { - return _EigenPodManager.contract.Transact(opts, "transferOwnership", newOwner) -} - -// TransferOwnership is a paid mutator transaction binding the contract method 0xf2fde38b. -// -// Solidity: function transferOwnership(address newOwner) returns() -func (_EigenPodManager *EigenPodManagerSession) TransferOwnership(newOwner common.Address) (*types.Transaction, error) { - return _EigenPodManager.Contract.TransferOwnership(&_EigenPodManager.TransactOpts, newOwner) -} - -// TransferOwnership is a paid mutator transaction binding the contract method 0xf2fde38b. -// -// Solidity: function transferOwnership(address newOwner) returns() -func (_EigenPodManager *EigenPodManagerTransactorSession) TransferOwnership(newOwner common.Address) (*types.Transaction, error) { - return _EigenPodManager.Contract.TransferOwnership(&_EigenPodManager.TransactOpts, newOwner) -} - -// Unpause is a paid mutator transaction binding the contract method 0xfabc1cbc. -// -// Solidity: function unpause(uint256 newPausedStatus) returns() -func (_EigenPodManager *EigenPodManagerTransactor) Unpause(opts *bind.TransactOpts, newPausedStatus *big.Int) (*types.Transaction, error) { - return _EigenPodManager.contract.Transact(opts, "unpause", newPausedStatus) -} - -// Unpause is a paid mutator transaction binding the contract method 0xfabc1cbc. -// -// Solidity: function unpause(uint256 newPausedStatus) returns() -func (_EigenPodManager *EigenPodManagerSession) Unpause(newPausedStatus *big.Int) (*types.Transaction, error) { - return _EigenPodManager.Contract.Unpause(&_EigenPodManager.TransactOpts, newPausedStatus) -} - -// Unpause is a paid mutator transaction binding the contract method 0xfabc1cbc. -// -// Solidity: function unpause(uint256 newPausedStatus) returns() -func (_EigenPodManager *EigenPodManagerTransactorSession) Unpause(newPausedStatus *big.Int) (*types.Transaction, error) { - return _EigenPodManager.Contract.Unpause(&_EigenPodManager.TransactOpts, newPausedStatus) -} - -// WithdrawSharesAsTokens is a paid mutator transaction binding the contract method 0x387b1300. -// -// Solidity: function withdrawSharesAsTokens(address podOwner, address destination, uint256 shares) returns() -func (_EigenPodManager *EigenPodManagerTransactor) WithdrawSharesAsTokens(opts *bind.TransactOpts, podOwner common.Address, destination common.Address, shares *big.Int) (*types.Transaction, error) { - return _EigenPodManager.contract.Transact(opts, "withdrawSharesAsTokens", podOwner, destination, shares) -} - -// WithdrawSharesAsTokens is a paid mutator transaction binding the contract method 0x387b1300. -// -// Solidity: function withdrawSharesAsTokens(address podOwner, address destination, uint256 shares) returns() -func (_EigenPodManager *EigenPodManagerSession) WithdrawSharesAsTokens(podOwner common.Address, destination common.Address, shares *big.Int) (*types.Transaction, error) { - return _EigenPodManager.Contract.WithdrawSharesAsTokens(&_EigenPodManager.TransactOpts, podOwner, destination, shares) -} - -// WithdrawSharesAsTokens is a paid mutator transaction binding the contract method 0x387b1300. -// -// Solidity: function withdrawSharesAsTokens(address podOwner, address destination, uint256 shares) returns() -func (_EigenPodManager *EigenPodManagerTransactorSession) WithdrawSharesAsTokens(podOwner common.Address, destination common.Address, shares *big.Int) (*types.Transaction, error) { - return _EigenPodManager.Contract.WithdrawSharesAsTokens(&_EigenPodManager.TransactOpts, podOwner, destination, shares) -} - -// EigenPodManagerBeaconChainETHDepositedIterator is returned from FilterBeaconChainETHDeposited and is used to iterate over the raw logs and unpacked data for BeaconChainETHDeposited events raised by the EigenPodManager contract. -type EigenPodManagerBeaconChainETHDepositedIterator struct { - Event *EigenPodManagerBeaconChainETHDeposited // Event containing the contract specifics and raw log - - contract *bind.BoundContract // Generic contract to use for unpacking event data - event string // Event name to use for unpacking event data - - logs chan types.Log // Log channel receiving the found contract events - sub ethereum.Subscription // Subscription for errors, completion and termination - done bool // Whether the subscription completed delivering logs - fail error // Occurred error to stop iteration -} - -// Next advances the iterator to the subsequent event, returning whether there -// are any more events found. In case of a retrieval or parsing error, false is -// returned and Error() can be queried for the exact failure. -func (it *EigenPodManagerBeaconChainETHDepositedIterator) Next() bool { - // If the iterator failed, stop iterating - if it.fail != nil { - return false - } - // If the iterator completed, deliver directly whatever's available - if it.done { - select { - case log := <-it.logs: - it.Event = new(EigenPodManagerBeaconChainETHDeposited) - if err := it.contract.UnpackLog(it.Event, it.event, log); err != nil { - it.fail = err - return false - } - it.Event.Raw = log - return true - - default: - return false - } - } - // Iterator still in progress, wait for either a data or an error event - select { - case log := <-it.logs: - it.Event = new(EigenPodManagerBeaconChainETHDeposited) - if err := it.contract.UnpackLog(it.Event, it.event, log); err != nil { - it.fail = err - return false - } - it.Event.Raw = log - return true - - case err := <-it.sub.Err(): - it.done = true - it.fail = err - return it.Next() - } -} - -// Error returns any retrieval or parsing error occurred during filtering. -func (it *EigenPodManagerBeaconChainETHDepositedIterator) Error() error { - return it.fail -} - -// Close terminates the iteration process, releasing any pending underlying -// resources. -func (it *EigenPodManagerBeaconChainETHDepositedIterator) Close() error { - it.sub.Unsubscribe() - return nil -} - -// EigenPodManagerBeaconChainETHDeposited represents a BeaconChainETHDeposited event raised by the EigenPodManager contract. -type EigenPodManagerBeaconChainETHDeposited struct { - PodOwner common.Address - Amount *big.Int - Raw types.Log // Blockchain specific contextual infos -} - -// FilterBeaconChainETHDeposited is a free log retrieval operation binding the contract event 0x35a85cabc603f48abb2b71d9fbd8adea7c449d7f0be900ae7a2986ea369c3d0d. -// -// Solidity: event BeaconChainETHDeposited(address indexed podOwner, uint256 amount) -func (_EigenPodManager *EigenPodManagerFilterer) FilterBeaconChainETHDeposited(opts *bind.FilterOpts, podOwner []common.Address) (*EigenPodManagerBeaconChainETHDepositedIterator, error) { - - var podOwnerRule []interface{} - for _, podOwnerItem := range podOwner { - podOwnerRule = append(podOwnerRule, podOwnerItem) - } - - logs, sub, err := _EigenPodManager.contract.FilterLogs(opts, "BeaconChainETHDeposited", podOwnerRule) - if err != nil { - return nil, err - } - return &EigenPodManagerBeaconChainETHDepositedIterator{contract: _EigenPodManager.contract, event: "BeaconChainETHDeposited", logs: logs, sub: sub}, nil -} - -// WatchBeaconChainETHDeposited is a free log subscription operation binding the contract event 0x35a85cabc603f48abb2b71d9fbd8adea7c449d7f0be900ae7a2986ea369c3d0d. -// -// Solidity: event BeaconChainETHDeposited(address indexed podOwner, uint256 amount) -func (_EigenPodManager *EigenPodManagerFilterer) WatchBeaconChainETHDeposited(opts *bind.WatchOpts, sink chan<- *EigenPodManagerBeaconChainETHDeposited, podOwner []common.Address) (event.Subscription, error) { - - var podOwnerRule []interface{} - for _, podOwnerItem := range podOwner { - podOwnerRule = append(podOwnerRule, podOwnerItem) - } - - logs, sub, err := _EigenPodManager.contract.WatchLogs(opts, "BeaconChainETHDeposited", podOwnerRule) - if err != nil { - return nil, err - } - return event.NewSubscription(func(quit <-chan struct{}) error { - defer sub.Unsubscribe() - for { - select { - case log := <-logs: - // New log arrived, parse the event and forward to the user - event := new(EigenPodManagerBeaconChainETHDeposited) - if err := _EigenPodManager.contract.UnpackLog(event, "BeaconChainETHDeposited", log); err != nil { - return err - } - event.Raw = log - - select { - case sink <- event: - case err := <-sub.Err(): - return err - case <-quit: - return nil - } - case err := <-sub.Err(): - return err - case <-quit: - return nil - } - } - }), nil -} - -// ParseBeaconChainETHDeposited is a log parse operation binding the contract event 0x35a85cabc603f48abb2b71d9fbd8adea7c449d7f0be900ae7a2986ea369c3d0d. -// -// Solidity: event BeaconChainETHDeposited(address indexed podOwner, uint256 amount) -func (_EigenPodManager *EigenPodManagerFilterer) ParseBeaconChainETHDeposited(log types.Log) (*EigenPodManagerBeaconChainETHDeposited, error) { - event := new(EigenPodManagerBeaconChainETHDeposited) - if err := _EigenPodManager.contract.UnpackLog(event, "BeaconChainETHDeposited", log); err != nil { - return nil, err - } - event.Raw = log - return event, nil -} - -// EigenPodManagerBeaconChainETHWithdrawalCompletedIterator is returned from FilterBeaconChainETHWithdrawalCompleted and is used to iterate over the raw logs and unpacked data for BeaconChainETHWithdrawalCompleted events raised by the EigenPodManager contract. -type EigenPodManagerBeaconChainETHWithdrawalCompletedIterator struct { - Event *EigenPodManagerBeaconChainETHWithdrawalCompleted // Event containing the contract specifics and raw log - - contract *bind.BoundContract // Generic contract to use for unpacking event data - event string // Event name to use for unpacking event data - - logs chan types.Log // Log channel receiving the found contract events - sub ethereum.Subscription // Subscription for errors, completion and termination - done bool // Whether the subscription completed delivering logs - fail error // Occurred error to stop iteration -} - -// Next advances the iterator to the subsequent event, returning whether there -// are any more events found. In case of a retrieval or parsing error, false is -// returned and Error() can be queried for the exact failure. -func (it *EigenPodManagerBeaconChainETHWithdrawalCompletedIterator) Next() bool { - // If the iterator failed, stop iterating - if it.fail != nil { - return false - } - // If the iterator completed, deliver directly whatever's available - if it.done { - select { - case log := <-it.logs: - it.Event = new(EigenPodManagerBeaconChainETHWithdrawalCompleted) - if err := it.contract.UnpackLog(it.Event, it.event, log); err != nil { - it.fail = err - return false - } - it.Event.Raw = log - return true - - default: - return false - } - } - // Iterator still in progress, wait for either a data or an error event - select { - case log := <-it.logs: - it.Event = new(EigenPodManagerBeaconChainETHWithdrawalCompleted) - if err := it.contract.UnpackLog(it.Event, it.event, log); err != nil { - it.fail = err - return false - } - it.Event.Raw = log - return true - - case err := <-it.sub.Err(): - it.done = true - it.fail = err - return it.Next() - } -} - -// Error returns any retrieval or parsing error occurred during filtering. -func (it *EigenPodManagerBeaconChainETHWithdrawalCompletedIterator) Error() error { - return it.fail -} - -// Close terminates the iteration process, releasing any pending underlying -// resources. -func (it *EigenPodManagerBeaconChainETHWithdrawalCompletedIterator) Close() error { - it.sub.Unsubscribe() - return nil -} - -// EigenPodManagerBeaconChainETHWithdrawalCompleted represents a BeaconChainETHWithdrawalCompleted event raised by the EigenPodManager contract. -type EigenPodManagerBeaconChainETHWithdrawalCompleted struct { - PodOwner common.Address - Shares *big.Int - Nonce *big.Int - DelegatedAddress common.Address - Withdrawer common.Address - WithdrawalRoot [32]byte - Raw types.Log // Blockchain specific contextual infos -} - -// FilterBeaconChainETHWithdrawalCompleted is a free log retrieval operation binding the contract event 0xa6bab1d55a361fcea2eee2bc9491e4f01e6cf333df03c9c4f2c144466429f7d6. -// -// Solidity: event BeaconChainETHWithdrawalCompleted(address indexed podOwner, uint256 shares, uint96 nonce, address delegatedAddress, address withdrawer, bytes32 withdrawalRoot) -func (_EigenPodManager *EigenPodManagerFilterer) FilterBeaconChainETHWithdrawalCompleted(opts *bind.FilterOpts, podOwner []common.Address) (*EigenPodManagerBeaconChainETHWithdrawalCompletedIterator, error) { - - var podOwnerRule []interface{} - for _, podOwnerItem := range podOwner { - podOwnerRule = append(podOwnerRule, podOwnerItem) - } - - logs, sub, err := _EigenPodManager.contract.FilterLogs(opts, "BeaconChainETHWithdrawalCompleted", podOwnerRule) - if err != nil { - return nil, err - } - return &EigenPodManagerBeaconChainETHWithdrawalCompletedIterator{contract: _EigenPodManager.contract, event: "BeaconChainETHWithdrawalCompleted", logs: logs, sub: sub}, nil -} - -// WatchBeaconChainETHWithdrawalCompleted is a free log subscription operation binding the contract event 0xa6bab1d55a361fcea2eee2bc9491e4f01e6cf333df03c9c4f2c144466429f7d6. -// -// Solidity: event BeaconChainETHWithdrawalCompleted(address indexed podOwner, uint256 shares, uint96 nonce, address delegatedAddress, address withdrawer, bytes32 withdrawalRoot) -func (_EigenPodManager *EigenPodManagerFilterer) WatchBeaconChainETHWithdrawalCompleted(opts *bind.WatchOpts, sink chan<- *EigenPodManagerBeaconChainETHWithdrawalCompleted, podOwner []common.Address) (event.Subscription, error) { - - var podOwnerRule []interface{} - for _, podOwnerItem := range podOwner { - podOwnerRule = append(podOwnerRule, podOwnerItem) - } - - logs, sub, err := _EigenPodManager.contract.WatchLogs(opts, "BeaconChainETHWithdrawalCompleted", podOwnerRule) - if err != nil { - return nil, err - } - return event.NewSubscription(func(quit <-chan struct{}) error { - defer sub.Unsubscribe() - for { - select { - case log := <-logs: - // New log arrived, parse the event and forward to the user - event := new(EigenPodManagerBeaconChainETHWithdrawalCompleted) - if err := _EigenPodManager.contract.UnpackLog(event, "BeaconChainETHWithdrawalCompleted", log); err != nil { - return err - } - event.Raw = log - - select { - case sink <- event: - case err := <-sub.Err(): - return err - case <-quit: - return nil - } - case err := <-sub.Err(): - return err - case <-quit: - return nil - } - } - }), nil -} - -// ParseBeaconChainETHWithdrawalCompleted is a log parse operation binding the contract event 0xa6bab1d55a361fcea2eee2bc9491e4f01e6cf333df03c9c4f2c144466429f7d6. -// -// Solidity: event BeaconChainETHWithdrawalCompleted(address indexed podOwner, uint256 shares, uint96 nonce, address delegatedAddress, address withdrawer, bytes32 withdrawalRoot) -func (_EigenPodManager *EigenPodManagerFilterer) ParseBeaconChainETHWithdrawalCompleted(log types.Log) (*EigenPodManagerBeaconChainETHWithdrawalCompleted, error) { - event := new(EigenPodManagerBeaconChainETHWithdrawalCompleted) - if err := _EigenPodManager.contract.UnpackLog(event, "BeaconChainETHWithdrawalCompleted", log); err != nil { - return nil, err - } - event.Raw = log - return event, nil -} - -// EigenPodManagerInitializedIterator is returned from FilterInitialized and is used to iterate over the raw logs and unpacked data for Initialized events raised by the EigenPodManager contract. -type EigenPodManagerInitializedIterator struct { - Event *EigenPodManagerInitialized // Event containing the contract specifics and raw log - - contract *bind.BoundContract // Generic contract to use for unpacking event data - event string // Event name to use for unpacking event data - - logs chan types.Log // Log channel receiving the found contract events - sub ethereum.Subscription // Subscription for errors, completion and termination - done bool // Whether the subscription completed delivering logs - fail error // Occurred error to stop iteration -} - -// Next advances the iterator to the subsequent event, returning whether there -// are any more events found. In case of a retrieval or parsing error, false is -// returned and Error() can be queried for the exact failure. -func (it *EigenPodManagerInitializedIterator) Next() bool { - // If the iterator failed, stop iterating - if it.fail != nil { - return false - } - // If the iterator completed, deliver directly whatever's available - if it.done { - select { - case log := <-it.logs: - it.Event = new(EigenPodManagerInitialized) - if err := it.contract.UnpackLog(it.Event, it.event, log); err != nil { - it.fail = err - return false - } - it.Event.Raw = log - return true - - default: - return false - } - } - // Iterator still in progress, wait for either a data or an error event - select { - case log := <-it.logs: - it.Event = new(EigenPodManagerInitialized) - if err := it.contract.UnpackLog(it.Event, it.event, log); err != nil { - it.fail = err - return false - } - it.Event.Raw = log - return true - - case err := <-it.sub.Err(): - it.done = true - it.fail = err - return it.Next() - } -} - -// Error returns any retrieval or parsing error occurred during filtering. -func (it *EigenPodManagerInitializedIterator) Error() error { - return it.fail -} - -// Close terminates the iteration process, releasing any pending underlying -// resources. -func (it *EigenPodManagerInitializedIterator) Close() error { - it.sub.Unsubscribe() - return nil -} - -// EigenPodManagerInitialized represents a Initialized event raised by the EigenPodManager contract. -type EigenPodManagerInitialized struct { - Version uint8 - Raw types.Log // Blockchain specific contextual infos -} - -// FilterInitialized is a free log retrieval operation binding the contract event 0x7f26b83ff96e1f2b6a682f133852f6798a09c465da95921460cefb3847402498. -// -// Solidity: event Initialized(uint8 version) -func (_EigenPodManager *EigenPodManagerFilterer) FilterInitialized(opts *bind.FilterOpts) (*EigenPodManagerInitializedIterator, error) { - - logs, sub, err := _EigenPodManager.contract.FilterLogs(opts, "Initialized") - if err != nil { - return nil, err - } - return &EigenPodManagerInitializedIterator{contract: _EigenPodManager.contract, event: "Initialized", logs: logs, sub: sub}, nil -} - -// WatchInitialized is a free log subscription operation binding the contract event 0x7f26b83ff96e1f2b6a682f133852f6798a09c465da95921460cefb3847402498. -// -// Solidity: event Initialized(uint8 version) -func (_EigenPodManager *EigenPodManagerFilterer) WatchInitialized(opts *bind.WatchOpts, sink chan<- *EigenPodManagerInitialized) (event.Subscription, error) { - - logs, sub, err := _EigenPodManager.contract.WatchLogs(opts, "Initialized") - if err != nil { - return nil, err - } - return event.NewSubscription(func(quit <-chan struct{}) error { - defer sub.Unsubscribe() - for { - select { - case log := <-logs: - // New log arrived, parse the event and forward to the user - event := new(EigenPodManagerInitialized) - if err := _EigenPodManager.contract.UnpackLog(event, "Initialized", log); err != nil { - return err - } - event.Raw = log - - select { - case sink <- event: - case err := <-sub.Err(): - return err - case <-quit: - return nil - } - case err := <-sub.Err(): - return err - case <-quit: - return nil - } - } - }), nil -} - -// ParseInitialized is a log parse operation binding the contract event 0x7f26b83ff96e1f2b6a682f133852f6798a09c465da95921460cefb3847402498. -// -// Solidity: event Initialized(uint8 version) -func (_EigenPodManager *EigenPodManagerFilterer) ParseInitialized(log types.Log) (*EigenPodManagerInitialized, error) { - event := new(EigenPodManagerInitialized) - if err := _EigenPodManager.contract.UnpackLog(event, "Initialized", log); err != nil { - return nil, err - } - event.Raw = log - return event, nil -} - -// EigenPodManagerNewTotalSharesIterator is returned from FilterNewTotalShares and is used to iterate over the raw logs and unpacked data for NewTotalShares events raised by the EigenPodManager contract. -type EigenPodManagerNewTotalSharesIterator struct { - Event *EigenPodManagerNewTotalShares // Event containing the contract specifics and raw log - - contract *bind.BoundContract // Generic contract to use for unpacking event data - event string // Event name to use for unpacking event data - - logs chan types.Log // Log channel receiving the found contract events - sub ethereum.Subscription // Subscription for errors, completion and termination - done bool // Whether the subscription completed delivering logs - fail error // Occurred error to stop iteration -} - -// Next advances the iterator to the subsequent event, returning whether there -// are any more events found. In case of a retrieval or parsing error, false is -// returned and Error() can be queried for the exact failure. -func (it *EigenPodManagerNewTotalSharesIterator) Next() bool { - // If the iterator failed, stop iterating - if it.fail != nil { - return false - } - // If the iterator completed, deliver directly whatever's available - if it.done { - select { - case log := <-it.logs: - it.Event = new(EigenPodManagerNewTotalShares) - if err := it.contract.UnpackLog(it.Event, it.event, log); err != nil { - it.fail = err - return false - } - it.Event.Raw = log - return true - - default: - return false - } - } - // Iterator still in progress, wait for either a data or an error event - select { - case log := <-it.logs: - it.Event = new(EigenPodManagerNewTotalShares) - if err := it.contract.UnpackLog(it.Event, it.event, log); err != nil { - it.fail = err - return false - } - it.Event.Raw = log - return true - - case err := <-it.sub.Err(): - it.done = true - it.fail = err - return it.Next() - } -} - -// Error returns any retrieval or parsing error occurred during filtering. -func (it *EigenPodManagerNewTotalSharesIterator) Error() error { - return it.fail -} - -// Close terminates the iteration process, releasing any pending underlying -// resources. -func (it *EigenPodManagerNewTotalSharesIterator) Close() error { - it.sub.Unsubscribe() - return nil -} - -// EigenPodManagerNewTotalShares represents a NewTotalShares event raised by the EigenPodManager contract. -type EigenPodManagerNewTotalShares struct { - PodOwner common.Address - NewTotalShares *big.Int - Raw types.Log // Blockchain specific contextual infos -} - -// FilterNewTotalShares is a free log retrieval operation binding the contract event 0xd4def76d6d2bed6f14d5cd9af73cc2913d618d00edde42432e81c09bfe077098. -// -// Solidity: event NewTotalShares(address indexed podOwner, int256 newTotalShares) -func (_EigenPodManager *EigenPodManagerFilterer) FilterNewTotalShares(opts *bind.FilterOpts, podOwner []common.Address) (*EigenPodManagerNewTotalSharesIterator, error) { - - var podOwnerRule []interface{} - for _, podOwnerItem := range podOwner { - podOwnerRule = append(podOwnerRule, podOwnerItem) - } - - logs, sub, err := _EigenPodManager.contract.FilterLogs(opts, "NewTotalShares", podOwnerRule) - if err != nil { - return nil, err - } - return &EigenPodManagerNewTotalSharesIterator{contract: _EigenPodManager.contract, event: "NewTotalShares", logs: logs, sub: sub}, nil -} - -// WatchNewTotalShares is a free log subscription operation binding the contract event 0xd4def76d6d2bed6f14d5cd9af73cc2913d618d00edde42432e81c09bfe077098. -// -// Solidity: event NewTotalShares(address indexed podOwner, int256 newTotalShares) -func (_EigenPodManager *EigenPodManagerFilterer) WatchNewTotalShares(opts *bind.WatchOpts, sink chan<- *EigenPodManagerNewTotalShares, podOwner []common.Address) (event.Subscription, error) { - - var podOwnerRule []interface{} - for _, podOwnerItem := range podOwner { - podOwnerRule = append(podOwnerRule, podOwnerItem) - } - - logs, sub, err := _EigenPodManager.contract.WatchLogs(opts, "NewTotalShares", podOwnerRule) - if err != nil { - return nil, err - } - return event.NewSubscription(func(quit <-chan struct{}) error { - defer sub.Unsubscribe() - for { - select { - case log := <-logs: - // New log arrived, parse the event and forward to the user - event := new(EigenPodManagerNewTotalShares) - if err := _EigenPodManager.contract.UnpackLog(event, "NewTotalShares", log); err != nil { - return err - } - event.Raw = log - - select { - case sink <- event: - case err := <-sub.Err(): - return err - case <-quit: - return nil - } - case err := <-sub.Err(): - return err - case <-quit: - return nil - } - } - }), nil -} - -// ParseNewTotalShares is a log parse operation binding the contract event 0xd4def76d6d2bed6f14d5cd9af73cc2913d618d00edde42432e81c09bfe077098. -// -// Solidity: event NewTotalShares(address indexed podOwner, int256 newTotalShares) -func (_EigenPodManager *EigenPodManagerFilterer) ParseNewTotalShares(log types.Log) (*EigenPodManagerNewTotalShares, error) { - event := new(EigenPodManagerNewTotalShares) - if err := _EigenPodManager.contract.UnpackLog(event, "NewTotalShares", log); err != nil { - return nil, err - } - event.Raw = log - return event, nil -} - -// EigenPodManagerOwnershipTransferredIterator is returned from FilterOwnershipTransferred and is used to iterate over the raw logs and unpacked data for OwnershipTransferred events raised by the EigenPodManager contract. -type EigenPodManagerOwnershipTransferredIterator struct { - Event *EigenPodManagerOwnershipTransferred // Event containing the contract specifics and raw log - - contract *bind.BoundContract // Generic contract to use for unpacking event data - event string // Event name to use for unpacking event data - - logs chan types.Log // Log channel receiving the found contract events - sub ethereum.Subscription // Subscription for errors, completion and termination - done bool // Whether the subscription completed delivering logs - fail error // Occurred error to stop iteration -} - -// Next advances the iterator to the subsequent event, returning whether there -// are any more events found. In case of a retrieval or parsing error, false is -// returned and Error() can be queried for the exact failure. -func (it *EigenPodManagerOwnershipTransferredIterator) Next() bool { - // If the iterator failed, stop iterating - if it.fail != nil { - return false - } - // If the iterator completed, deliver directly whatever's available - if it.done { - select { - case log := <-it.logs: - it.Event = new(EigenPodManagerOwnershipTransferred) - if err := it.contract.UnpackLog(it.Event, it.event, log); err != nil { - it.fail = err - return false - } - it.Event.Raw = log - return true - - default: - return false - } - } - // Iterator still in progress, wait for either a data or an error event - select { - case log := <-it.logs: - it.Event = new(EigenPodManagerOwnershipTransferred) - if err := it.contract.UnpackLog(it.Event, it.event, log); err != nil { - it.fail = err - return false - } - it.Event.Raw = log - return true - - case err := <-it.sub.Err(): - it.done = true - it.fail = err - return it.Next() - } -} - -// Error returns any retrieval or parsing error occurred during filtering. -func (it *EigenPodManagerOwnershipTransferredIterator) Error() error { - return it.fail -} - -// Close terminates the iteration process, releasing any pending underlying -// resources. -func (it *EigenPodManagerOwnershipTransferredIterator) Close() error { - it.sub.Unsubscribe() - return nil -} - -// EigenPodManagerOwnershipTransferred represents a OwnershipTransferred event raised by the EigenPodManager contract. -type EigenPodManagerOwnershipTransferred struct { - PreviousOwner common.Address - NewOwner common.Address - Raw types.Log // Blockchain specific contextual infos -} - -// FilterOwnershipTransferred is a free log retrieval operation binding the contract event 0x8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e0. -// -// Solidity: event OwnershipTransferred(address indexed previousOwner, address indexed newOwner) -func (_EigenPodManager *EigenPodManagerFilterer) FilterOwnershipTransferred(opts *bind.FilterOpts, previousOwner []common.Address, newOwner []common.Address) (*EigenPodManagerOwnershipTransferredIterator, error) { - - var previousOwnerRule []interface{} - for _, previousOwnerItem := range previousOwner { - previousOwnerRule = append(previousOwnerRule, previousOwnerItem) - } - var newOwnerRule []interface{} - for _, newOwnerItem := range newOwner { - newOwnerRule = append(newOwnerRule, newOwnerItem) - } - - logs, sub, err := _EigenPodManager.contract.FilterLogs(opts, "OwnershipTransferred", previousOwnerRule, newOwnerRule) - if err != nil { - return nil, err - } - return &EigenPodManagerOwnershipTransferredIterator{contract: _EigenPodManager.contract, event: "OwnershipTransferred", logs: logs, sub: sub}, nil -} - -// WatchOwnershipTransferred is a free log subscription operation binding the contract event 0x8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e0. -// -// Solidity: event OwnershipTransferred(address indexed previousOwner, address indexed newOwner) -func (_EigenPodManager *EigenPodManagerFilterer) WatchOwnershipTransferred(opts *bind.WatchOpts, sink chan<- *EigenPodManagerOwnershipTransferred, previousOwner []common.Address, newOwner []common.Address) (event.Subscription, error) { - - var previousOwnerRule []interface{} - for _, previousOwnerItem := range previousOwner { - previousOwnerRule = append(previousOwnerRule, previousOwnerItem) - } - var newOwnerRule []interface{} - for _, newOwnerItem := range newOwner { - newOwnerRule = append(newOwnerRule, newOwnerItem) - } - - logs, sub, err := _EigenPodManager.contract.WatchLogs(opts, "OwnershipTransferred", previousOwnerRule, newOwnerRule) - if err != nil { - return nil, err - } - return event.NewSubscription(func(quit <-chan struct{}) error { - defer sub.Unsubscribe() - for { - select { - case log := <-logs: - // New log arrived, parse the event and forward to the user - event := new(EigenPodManagerOwnershipTransferred) - if err := _EigenPodManager.contract.UnpackLog(event, "OwnershipTransferred", log); err != nil { - return err - } - event.Raw = log - - select { - case sink <- event: - case err := <-sub.Err(): - return err - case <-quit: - return nil - } - case err := <-sub.Err(): - return err - case <-quit: - return nil - } - } - }), nil -} - -// ParseOwnershipTransferred is a log parse operation binding the contract event 0x8be0079c531659141344cd1fd0a4f28419497f9722a3daafe3b4186f6b6457e0. -// -// Solidity: event OwnershipTransferred(address indexed previousOwner, address indexed newOwner) -func (_EigenPodManager *EigenPodManagerFilterer) ParseOwnershipTransferred(log types.Log) (*EigenPodManagerOwnershipTransferred, error) { - event := new(EigenPodManagerOwnershipTransferred) - if err := _EigenPodManager.contract.UnpackLog(event, "OwnershipTransferred", log); err != nil { - return nil, err - } - event.Raw = log - return event, nil -} - -// EigenPodManagerPausedIterator is returned from FilterPaused and is used to iterate over the raw logs and unpacked data for Paused events raised by the EigenPodManager contract. -type EigenPodManagerPausedIterator struct { - Event *EigenPodManagerPaused // Event containing the contract specifics and raw log - - contract *bind.BoundContract // Generic contract to use for unpacking event data - event string // Event name to use for unpacking event data - - logs chan types.Log // Log channel receiving the found contract events - sub ethereum.Subscription // Subscription for errors, completion and termination - done bool // Whether the subscription completed delivering logs - fail error // Occurred error to stop iteration -} - -// Next advances the iterator to the subsequent event, returning whether there -// are any more events found. In case of a retrieval or parsing error, false is -// returned and Error() can be queried for the exact failure. -func (it *EigenPodManagerPausedIterator) Next() bool { - // If the iterator failed, stop iterating - if it.fail != nil { - return false - } - // If the iterator completed, deliver directly whatever's available - if it.done { - select { - case log := <-it.logs: - it.Event = new(EigenPodManagerPaused) - if err := it.contract.UnpackLog(it.Event, it.event, log); err != nil { - it.fail = err - return false - } - it.Event.Raw = log - return true - - default: - return false - } - } - // Iterator still in progress, wait for either a data or an error event - select { - case log := <-it.logs: - it.Event = new(EigenPodManagerPaused) - if err := it.contract.UnpackLog(it.Event, it.event, log); err != nil { - it.fail = err - return false - } - it.Event.Raw = log - return true - - case err := <-it.sub.Err(): - it.done = true - it.fail = err - return it.Next() - } -} - -// Error returns any retrieval or parsing error occurred during filtering. -func (it *EigenPodManagerPausedIterator) Error() error { - return it.fail -} - -// Close terminates the iteration process, releasing any pending underlying -// resources. -func (it *EigenPodManagerPausedIterator) Close() error { - it.sub.Unsubscribe() - return nil -} - -// EigenPodManagerPaused represents a Paused event raised by the EigenPodManager contract. -type EigenPodManagerPaused struct { - Account common.Address - NewPausedStatus *big.Int - Raw types.Log // Blockchain specific contextual infos -} - -// FilterPaused is a free log retrieval operation binding the contract event 0xab40a374bc51de372200a8bc981af8c9ecdc08dfdaef0bb6e09f88f3c616ef3d. -// -// Solidity: event Paused(address indexed account, uint256 newPausedStatus) -func (_EigenPodManager *EigenPodManagerFilterer) FilterPaused(opts *bind.FilterOpts, account []common.Address) (*EigenPodManagerPausedIterator, error) { - - var accountRule []interface{} - for _, accountItem := range account { - accountRule = append(accountRule, accountItem) - } - - logs, sub, err := _EigenPodManager.contract.FilterLogs(opts, "Paused", accountRule) - if err != nil { - return nil, err - } - return &EigenPodManagerPausedIterator{contract: _EigenPodManager.contract, event: "Paused", logs: logs, sub: sub}, nil -} - -// WatchPaused is a free log subscription operation binding the contract event 0xab40a374bc51de372200a8bc981af8c9ecdc08dfdaef0bb6e09f88f3c616ef3d. -// -// Solidity: event Paused(address indexed account, uint256 newPausedStatus) -func (_EigenPodManager *EigenPodManagerFilterer) WatchPaused(opts *bind.WatchOpts, sink chan<- *EigenPodManagerPaused, account []common.Address) (event.Subscription, error) { - - var accountRule []interface{} - for _, accountItem := range account { - accountRule = append(accountRule, accountItem) - } - - logs, sub, err := _EigenPodManager.contract.WatchLogs(opts, "Paused", accountRule) - if err != nil { - return nil, err - } - return event.NewSubscription(func(quit <-chan struct{}) error { - defer sub.Unsubscribe() - for { - select { - case log := <-logs: - // New log arrived, parse the event and forward to the user - event := new(EigenPodManagerPaused) - if err := _EigenPodManager.contract.UnpackLog(event, "Paused", log); err != nil { - return err - } - event.Raw = log - - select { - case sink <- event: - case err := <-sub.Err(): - return err - case <-quit: - return nil - } - case err := <-sub.Err(): - return err - case <-quit: - return nil - } - } - }), nil -} - -// ParsePaused is a log parse operation binding the contract event 0xab40a374bc51de372200a8bc981af8c9ecdc08dfdaef0bb6e09f88f3c616ef3d. -// -// Solidity: event Paused(address indexed account, uint256 newPausedStatus) -func (_EigenPodManager *EigenPodManagerFilterer) ParsePaused(log types.Log) (*EigenPodManagerPaused, error) { - event := new(EigenPodManagerPaused) - if err := _EigenPodManager.contract.UnpackLog(event, "Paused", log); err != nil { - return nil, err - } - event.Raw = log - return event, nil -} - -// EigenPodManagerPauserRegistrySetIterator is returned from FilterPauserRegistrySet and is used to iterate over the raw logs and unpacked data for PauserRegistrySet events raised by the EigenPodManager contract. -type EigenPodManagerPauserRegistrySetIterator struct { - Event *EigenPodManagerPauserRegistrySet // Event containing the contract specifics and raw log - - contract *bind.BoundContract // Generic contract to use for unpacking event data - event string // Event name to use for unpacking event data - - logs chan types.Log // Log channel receiving the found contract events - sub ethereum.Subscription // Subscription for errors, completion and termination - done bool // Whether the subscription completed delivering logs - fail error // Occurred error to stop iteration -} - -// Next advances the iterator to the subsequent event, returning whether there -// are any more events found. In case of a retrieval or parsing error, false is -// returned and Error() can be queried for the exact failure. -func (it *EigenPodManagerPauserRegistrySetIterator) Next() bool { - // If the iterator failed, stop iterating - if it.fail != nil { - return false - } - // If the iterator completed, deliver directly whatever's available - if it.done { - select { - case log := <-it.logs: - it.Event = new(EigenPodManagerPauserRegistrySet) - if err := it.contract.UnpackLog(it.Event, it.event, log); err != nil { - it.fail = err - return false - } - it.Event.Raw = log - return true - - default: - return false - } - } - // Iterator still in progress, wait for either a data or an error event - select { - case log := <-it.logs: - it.Event = new(EigenPodManagerPauserRegistrySet) - if err := it.contract.UnpackLog(it.Event, it.event, log); err != nil { - it.fail = err - return false - } - it.Event.Raw = log - return true - - case err := <-it.sub.Err(): - it.done = true - it.fail = err - return it.Next() - } -} - -// Error returns any retrieval or parsing error occurred during filtering. -func (it *EigenPodManagerPauserRegistrySetIterator) Error() error { - return it.fail -} - -// Close terminates the iteration process, releasing any pending underlying -// resources. -func (it *EigenPodManagerPauserRegistrySetIterator) Close() error { - it.sub.Unsubscribe() - return nil -} - -// EigenPodManagerPauserRegistrySet represents a PauserRegistrySet event raised by the EigenPodManager contract. -type EigenPodManagerPauserRegistrySet struct { - PauserRegistry common.Address - NewPauserRegistry common.Address - Raw types.Log // Blockchain specific contextual infos -} - -// FilterPauserRegistrySet is a free log retrieval operation binding the contract event 0x6e9fcd539896fca60e8b0f01dd580233e48a6b0f7df013b89ba7f565869acdb6. -// -// Solidity: event PauserRegistrySet(address pauserRegistry, address newPauserRegistry) -func (_EigenPodManager *EigenPodManagerFilterer) FilterPauserRegistrySet(opts *bind.FilterOpts) (*EigenPodManagerPauserRegistrySetIterator, error) { - - logs, sub, err := _EigenPodManager.contract.FilterLogs(opts, "PauserRegistrySet") - if err != nil { - return nil, err - } - return &EigenPodManagerPauserRegistrySetIterator{contract: _EigenPodManager.contract, event: "PauserRegistrySet", logs: logs, sub: sub}, nil -} - -// WatchPauserRegistrySet is a free log subscription operation binding the contract event 0x6e9fcd539896fca60e8b0f01dd580233e48a6b0f7df013b89ba7f565869acdb6. -// -// Solidity: event PauserRegistrySet(address pauserRegistry, address newPauserRegistry) -func (_EigenPodManager *EigenPodManagerFilterer) WatchPauserRegistrySet(opts *bind.WatchOpts, sink chan<- *EigenPodManagerPauserRegistrySet) (event.Subscription, error) { - - logs, sub, err := _EigenPodManager.contract.WatchLogs(opts, "PauserRegistrySet") - if err != nil { - return nil, err - } - return event.NewSubscription(func(quit <-chan struct{}) error { - defer sub.Unsubscribe() - for { - select { - case log := <-logs: - // New log arrived, parse the event and forward to the user - event := new(EigenPodManagerPauserRegistrySet) - if err := _EigenPodManager.contract.UnpackLog(event, "PauserRegistrySet", log); err != nil { - return err - } - event.Raw = log - - select { - case sink <- event: - case err := <-sub.Err(): - return err - case <-quit: - return nil - } - case err := <-sub.Err(): - return err - case <-quit: - return nil - } - } - }), nil -} - -// ParsePauserRegistrySet is a log parse operation binding the contract event 0x6e9fcd539896fca60e8b0f01dd580233e48a6b0f7df013b89ba7f565869acdb6. -// -// Solidity: event PauserRegistrySet(address pauserRegistry, address newPauserRegistry) -func (_EigenPodManager *EigenPodManagerFilterer) ParsePauserRegistrySet(log types.Log) (*EigenPodManagerPauserRegistrySet, error) { - event := new(EigenPodManagerPauserRegistrySet) - if err := _EigenPodManager.contract.UnpackLog(event, "PauserRegistrySet", log); err != nil { - return nil, err - } - event.Raw = log - return event, nil -} - -// EigenPodManagerPodDeployedIterator is returned from FilterPodDeployed and is used to iterate over the raw logs and unpacked data for PodDeployed events raised by the EigenPodManager contract. -type EigenPodManagerPodDeployedIterator struct { - Event *EigenPodManagerPodDeployed // Event containing the contract specifics and raw log - - contract *bind.BoundContract // Generic contract to use for unpacking event data - event string // Event name to use for unpacking event data - - logs chan types.Log // Log channel receiving the found contract events - sub ethereum.Subscription // Subscription for errors, completion and termination - done bool // Whether the subscription completed delivering logs - fail error // Occurred error to stop iteration -} - -// Next advances the iterator to the subsequent event, returning whether there -// are any more events found. In case of a retrieval or parsing error, false is -// returned and Error() can be queried for the exact failure. -func (it *EigenPodManagerPodDeployedIterator) Next() bool { - // If the iterator failed, stop iterating - if it.fail != nil { - return false - } - // If the iterator completed, deliver directly whatever's available - if it.done { - select { - case log := <-it.logs: - it.Event = new(EigenPodManagerPodDeployed) - if err := it.contract.UnpackLog(it.Event, it.event, log); err != nil { - it.fail = err - return false - } - it.Event.Raw = log - return true - - default: - return false - } - } - // Iterator still in progress, wait for either a data or an error event - select { - case log := <-it.logs: - it.Event = new(EigenPodManagerPodDeployed) - if err := it.contract.UnpackLog(it.Event, it.event, log); err != nil { - it.fail = err - return false - } - it.Event.Raw = log - return true - - case err := <-it.sub.Err(): - it.done = true - it.fail = err - return it.Next() - } -} - -// Error returns any retrieval or parsing error occurred during filtering. -func (it *EigenPodManagerPodDeployedIterator) Error() error { - return it.fail -} - -// Close terminates the iteration process, releasing any pending underlying -// resources. -func (it *EigenPodManagerPodDeployedIterator) Close() error { - it.sub.Unsubscribe() - return nil -} - -// EigenPodManagerPodDeployed represents a PodDeployed event raised by the EigenPodManager contract. -type EigenPodManagerPodDeployed struct { - EigenPod common.Address - PodOwner common.Address - Raw types.Log // Blockchain specific contextual infos -} - -// FilterPodDeployed is a free log retrieval operation binding the contract event 0x21c99d0db02213c32fff5b05cf0a718ab5f858802b91498f80d82270289d856a. -// -// Solidity: event PodDeployed(address indexed eigenPod, address indexed podOwner) -func (_EigenPodManager *EigenPodManagerFilterer) FilterPodDeployed(opts *bind.FilterOpts, eigenPod []common.Address, podOwner []common.Address) (*EigenPodManagerPodDeployedIterator, error) { - - var eigenPodRule []interface{} - for _, eigenPodItem := range eigenPod { - eigenPodRule = append(eigenPodRule, eigenPodItem) - } - var podOwnerRule []interface{} - for _, podOwnerItem := range podOwner { - podOwnerRule = append(podOwnerRule, podOwnerItem) - } - - logs, sub, err := _EigenPodManager.contract.FilterLogs(opts, "PodDeployed", eigenPodRule, podOwnerRule) - if err != nil { - return nil, err - } - return &EigenPodManagerPodDeployedIterator{contract: _EigenPodManager.contract, event: "PodDeployed", logs: logs, sub: sub}, nil -} - -// WatchPodDeployed is a free log subscription operation binding the contract event 0x21c99d0db02213c32fff5b05cf0a718ab5f858802b91498f80d82270289d856a. -// -// Solidity: event PodDeployed(address indexed eigenPod, address indexed podOwner) -func (_EigenPodManager *EigenPodManagerFilterer) WatchPodDeployed(opts *bind.WatchOpts, sink chan<- *EigenPodManagerPodDeployed, eigenPod []common.Address, podOwner []common.Address) (event.Subscription, error) { - - var eigenPodRule []interface{} - for _, eigenPodItem := range eigenPod { - eigenPodRule = append(eigenPodRule, eigenPodItem) - } - var podOwnerRule []interface{} - for _, podOwnerItem := range podOwner { - podOwnerRule = append(podOwnerRule, podOwnerItem) - } - - logs, sub, err := _EigenPodManager.contract.WatchLogs(opts, "PodDeployed", eigenPodRule, podOwnerRule) - if err != nil { - return nil, err - } - return event.NewSubscription(func(quit <-chan struct{}) error { - defer sub.Unsubscribe() - for { - select { - case log := <-logs: - // New log arrived, parse the event and forward to the user - event := new(EigenPodManagerPodDeployed) - if err := _EigenPodManager.contract.UnpackLog(event, "PodDeployed", log); err != nil { - return err - } - event.Raw = log - - select { - case sink <- event: - case err := <-sub.Err(): - return err - case <-quit: - return nil - } - case err := <-sub.Err(): - return err - case <-quit: - return nil - } - } - }), nil -} - -// ParsePodDeployed is a log parse operation binding the contract event 0x21c99d0db02213c32fff5b05cf0a718ab5f858802b91498f80d82270289d856a. -// -// Solidity: event PodDeployed(address indexed eigenPod, address indexed podOwner) -func (_EigenPodManager *EigenPodManagerFilterer) ParsePodDeployed(log types.Log) (*EigenPodManagerPodDeployed, error) { - event := new(EigenPodManagerPodDeployed) - if err := _EigenPodManager.contract.UnpackLog(event, "PodDeployed", log); err != nil { - return nil, err - } - event.Raw = log - return event, nil -} - -// EigenPodManagerPodSharesUpdatedIterator is returned from FilterPodSharesUpdated and is used to iterate over the raw logs and unpacked data for PodSharesUpdated events raised by the EigenPodManager contract. -type EigenPodManagerPodSharesUpdatedIterator struct { - Event *EigenPodManagerPodSharesUpdated // Event containing the contract specifics and raw log - - contract *bind.BoundContract // Generic contract to use for unpacking event data - event string // Event name to use for unpacking event data - - logs chan types.Log // Log channel receiving the found contract events - sub ethereum.Subscription // Subscription for errors, completion and termination - done bool // Whether the subscription completed delivering logs - fail error // Occurred error to stop iteration -} - -// Next advances the iterator to the subsequent event, returning whether there -// are any more events found. In case of a retrieval or parsing error, false is -// returned and Error() can be queried for the exact failure. -func (it *EigenPodManagerPodSharesUpdatedIterator) Next() bool { - // If the iterator failed, stop iterating - if it.fail != nil { - return false - } - // If the iterator completed, deliver directly whatever's available - if it.done { - select { - case log := <-it.logs: - it.Event = new(EigenPodManagerPodSharesUpdated) - if err := it.contract.UnpackLog(it.Event, it.event, log); err != nil { - it.fail = err - return false - } - it.Event.Raw = log - return true - - default: - return false - } - } - // Iterator still in progress, wait for either a data or an error event - select { - case log := <-it.logs: - it.Event = new(EigenPodManagerPodSharesUpdated) - if err := it.contract.UnpackLog(it.Event, it.event, log); err != nil { - it.fail = err - return false - } - it.Event.Raw = log - return true - - case err := <-it.sub.Err(): - it.done = true - it.fail = err - return it.Next() - } -} - -// Error returns any retrieval or parsing error occurred during filtering. -func (it *EigenPodManagerPodSharesUpdatedIterator) Error() error { - return it.fail -} - -// Close terminates the iteration process, releasing any pending underlying -// resources. -func (it *EigenPodManagerPodSharesUpdatedIterator) Close() error { - it.sub.Unsubscribe() - return nil -} - -// EigenPodManagerPodSharesUpdated represents a PodSharesUpdated event raised by the EigenPodManager contract. -type EigenPodManagerPodSharesUpdated struct { - PodOwner common.Address - SharesDelta *big.Int - Raw types.Log // Blockchain specific contextual infos -} - -// FilterPodSharesUpdated is a free log retrieval operation binding the contract event 0x4e2b791dedccd9fb30141b088cabf5c14a8912b52f59375c95c010700b8c6193. -// -// Solidity: event PodSharesUpdated(address indexed podOwner, int256 sharesDelta) -func (_EigenPodManager *EigenPodManagerFilterer) FilterPodSharesUpdated(opts *bind.FilterOpts, podOwner []common.Address) (*EigenPodManagerPodSharesUpdatedIterator, error) { - - var podOwnerRule []interface{} - for _, podOwnerItem := range podOwner { - podOwnerRule = append(podOwnerRule, podOwnerItem) - } - - logs, sub, err := _EigenPodManager.contract.FilterLogs(opts, "PodSharesUpdated", podOwnerRule) - if err != nil { - return nil, err - } - return &EigenPodManagerPodSharesUpdatedIterator{contract: _EigenPodManager.contract, event: "PodSharesUpdated", logs: logs, sub: sub}, nil -} - -// WatchPodSharesUpdated is a free log subscription operation binding the contract event 0x4e2b791dedccd9fb30141b088cabf5c14a8912b52f59375c95c010700b8c6193. -// -// Solidity: event PodSharesUpdated(address indexed podOwner, int256 sharesDelta) -func (_EigenPodManager *EigenPodManagerFilterer) WatchPodSharesUpdated(opts *bind.WatchOpts, sink chan<- *EigenPodManagerPodSharesUpdated, podOwner []common.Address) (event.Subscription, error) { - - var podOwnerRule []interface{} - for _, podOwnerItem := range podOwner { - podOwnerRule = append(podOwnerRule, podOwnerItem) - } - - logs, sub, err := _EigenPodManager.contract.WatchLogs(opts, "PodSharesUpdated", podOwnerRule) - if err != nil { - return nil, err - } - return event.NewSubscription(func(quit <-chan struct{}) error { - defer sub.Unsubscribe() - for { - select { - case log := <-logs: - // New log arrived, parse the event and forward to the user - event := new(EigenPodManagerPodSharesUpdated) - if err := _EigenPodManager.contract.UnpackLog(event, "PodSharesUpdated", log); err != nil { - return err - } - event.Raw = log - - select { - case sink <- event: - case err := <-sub.Err(): - return err - case <-quit: - return nil - } - case err := <-sub.Err(): - return err - case <-quit: - return nil - } - } - }), nil -} - -// ParsePodSharesUpdated is a log parse operation binding the contract event 0x4e2b791dedccd9fb30141b088cabf5c14a8912b52f59375c95c010700b8c6193. -// -// Solidity: event PodSharesUpdated(address indexed podOwner, int256 sharesDelta) -func (_EigenPodManager *EigenPodManagerFilterer) ParsePodSharesUpdated(log types.Log) (*EigenPodManagerPodSharesUpdated, error) { - event := new(EigenPodManagerPodSharesUpdated) - if err := _EigenPodManager.contract.UnpackLog(event, "PodSharesUpdated", log); err != nil { - return nil, err - } - event.Raw = log - return event, nil -} - -// EigenPodManagerUnpausedIterator is returned from FilterUnpaused and is used to iterate over the raw logs and unpacked data for Unpaused events raised by the EigenPodManager contract. -type EigenPodManagerUnpausedIterator struct { - Event *EigenPodManagerUnpaused // Event containing the contract specifics and raw log - - contract *bind.BoundContract // Generic contract to use for unpacking event data - event string // Event name to use for unpacking event data - - logs chan types.Log // Log channel receiving the found contract events - sub ethereum.Subscription // Subscription for errors, completion and termination - done bool // Whether the subscription completed delivering logs - fail error // Occurred error to stop iteration -} - -// Next advances the iterator to the subsequent event, returning whether there -// are any more events found. In case of a retrieval or parsing error, false is -// returned and Error() can be queried for the exact failure. -func (it *EigenPodManagerUnpausedIterator) Next() bool { - // If the iterator failed, stop iterating - if it.fail != nil { - return false - } - // If the iterator completed, deliver directly whatever's available - if it.done { - select { - case log := <-it.logs: - it.Event = new(EigenPodManagerUnpaused) - if err := it.contract.UnpackLog(it.Event, it.event, log); err != nil { - it.fail = err - return false - } - it.Event.Raw = log - return true - - default: - return false - } - } - // Iterator still in progress, wait for either a data or an error event - select { - case log := <-it.logs: - it.Event = new(EigenPodManagerUnpaused) - if err := it.contract.UnpackLog(it.Event, it.event, log); err != nil { - it.fail = err - return false - } - it.Event.Raw = log - return true - - case err := <-it.sub.Err(): - it.done = true - it.fail = err - return it.Next() - } -} - -// Error returns any retrieval or parsing error occurred during filtering. -func (it *EigenPodManagerUnpausedIterator) Error() error { - return it.fail -} - -// Close terminates the iteration process, releasing any pending underlying -// resources. -func (it *EigenPodManagerUnpausedIterator) Close() error { - it.sub.Unsubscribe() - return nil -} - -// EigenPodManagerUnpaused represents a Unpaused event raised by the EigenPodManager contract. -type EigenPodManagerUnpaused struct { - Account common.Address - NewPausedStatus *big.Int - Raw types.Log // Blockchain specific contextual infos -} - -// FilterUnpaused is a free log retrieval operation binding the contract event 0x3582d1828e26bf56bd801502bc021ac0bc8afb57c826e4986b45593c8fad389c. -// -// Solidity: event Unpaused(address indexed account, uint256 newPausedStatus) -func (_EigenPodManager *EigenPodManagerFilterer) FilterUnpaused(opts *bind.FilterOpts, account []common.Address) (*EigenPodManagerUnpausedIterator, error) { - - var accountRule []interface{} - for _, accountItem := range account { - accountRule = append(accountRule, accountItem) - } - - logs, sub, err := _EigenPodManager.contract.FilterLogs(opts, "Unpaused", accountRule) - if err != nil { - return nil, err - } - return &EigenPodManagerUnpausedIterator{contract: _EigenPodManager.contract, event: "Unpaused", logs: logs, sub: sub}, nil -} - -// WatchUnpaused is a free log subscription operation binding the contract event 0x3582d1828e26bf56bd801502bc021ac0bc8afb57c826e4986b45593c8fad389c. -// -// Solidity: event Unpaused(address indexed account, uint256 newPausedStatus) -func (_EigenPodManager *EigenPodManagerFilterer) WatchUnpaused(opts *bind.WatchOpts, sink chan<- *EigenPodManagerUnpaused, account []common.Address) (event.Subscription, error) { - - var accountRule []interface{} - for _, accountItem := range account { - accountRule = append(accountRule, accountItem) - } - - logs, sub, err := _EigenPodManager.contract.WatchLogs(opts, "Unpaused", accountRule) - if err != nil { - return nil, err - } - return event.NewSubscription(func(quit <-chan struct{}) error { - defer sub.Unsubscribe() - for { - select { - case log := <-logs: - // New log arrived, parse the event and forward to the user - event := new(EigenPodManagerUnpaused) - if err := _EigenPodManager.contract.UnpackLog(event, "Unpaused", log); err != nil { - return err - } - event.Raw = log - - select { - case sink <- event: - case err := <-sub.Err(): - return err - case <-quit: - return nil - } - case err := <-sub.Err(): - return err - case <-quit: - return nil - } - } - }), nil -} - -// ParseUnpaused is a log parse operation binding the contract event 0x3582d1828e26bf56bd801502bc021ac0bc8afb57c826e4986b45593c8fad389c. -// -// Solidity: event Unpaused(address indexed account, uint256 newPausedStatus) -func (_EigenPodManager *EigenPodManagerFilterer) ParseUnpaused(log types.Log) (*EigenPodManagerUnpaused, error) { - event := new(EigenPodManagerUnpaused) - if err := _EigenPodManager.contract.UnpackLog(event, "Unpaused", log); err != nil { - return nil, err - } - event.Raw = log - return event, nil -} diff --git a/cli/core/status.go b/cli/core/status.go index bffd1937..5a848e9c 100644 --- a/cli/core/status.go +++ b/cli/core/status.go @@ -5,9 +5,12 @@ import ( "fmt" "math/big" - "github.com/Layr-Labs/eigenpod-proofs-generation/cli/core/onchain" + "github.com/Layr-Labs/eigenlayer-contracts/pkg/bindings/DelegationManager" + "github.com/Layr-Labs/eigenlayer-contracts/pkg/bindings/EigenPod" + "github.com/Layr-Labs/eigenlayer-contracts/pkg/bindings/EigenPodManager" "github.com/attestantio/go-eth2-client/spec" "github.com/attestantio/go-eth2-client/spec/phase0" + "github.com/ethereum/go-ethereum/common" gethCommon "github.com/ethereum/go-ethereum/common" "github.com/ethereum/go-ethereum/ethclient" ) @@ -28,6 +31,8 @@ type Validator struct { CurrentBalance uint64 } +const NATIVE_ETH_STRATEGY = "0xbeaC0eeEeeeeEEeEeEEEEeeEEeEeeeEeeEEBEaC0" + type EigenpodStatus struct { Validators map[string]Validator @@ -89,7 +94,7 @@ func GetStatus(ctx context.Context, eigenpodAddress string, eth *ethclient.Clien validators := map[string]Validator{} var activeCheckpoint *Checkpoint = nil - eigenPod, err := onchain.NewEigenPod(gethCommon.HexToAddress(eigenpodAddress), eth) + eigenPod, err := EigenPod.NewEigenPod(gethCommon.HexToAddress(eigenpodAddress), eth) PanicOnError("failed to reach eigenpod", err) checkpoint, err := eigenPod.CurrentCheckpoint(nil) @@ -135,7 +140,7 @@ func GetStatus(ctx context.Context, eigenpodAddress string, eth *ethclient.Clien eigenpodManagerContractAddress, err := eigenPod.EigenPodManager(nil) PanicOnError("failed to get manager address", err) - eigenPodManager, err := onchain.NewEigenPodManager(eigenpodManagerContractAddress, eth) + eigenPodManager, err := EigenPodManager.NewEigenPodManager(eigenpodManagerContractAddress, eth) PanicOnError("failed to get manager instance", err) eigenPodOwner, err := eigenPod.PodOwner(nil) @@ -144,11 +149,19 @@ func GetStatus(ctx context.Context, eigenpodAddress string, eth *ethclient.Clien proofSubmitter, err := eigenPod.ProofSubmitter(nil) PanicOnError("failed to get eigenpod proof submitter", err) - currentOwnerShares, err := eigenPodManager.PodOwnerShares(nil, eigenPodOwner) - // currentOwnerShares = big.NewInt(0) - PanicOnError("failed to load pod owner shares", err) - currentOwnerSharesETH := IweiToEther(currentOwnerShares) - currentOwnerSharesWei := currentOwnerShares + delegationManagerAddress, err := eigenPodManager.DelegationManager(nil) + PanicOnError("failed to read delegationManager", err) + + delegationManager, err := DelegationManager.NewDelegationManager(delegationManagerAddress, eth) + PanicOnError("failed to reach delegationManager", err) + + shares, err := delegationManager.GetWithdrawableShares(nil, eigenPodOwner, []common.Address{ + common.HexToAddress(NATIVE_ETH_STRATEGY), + }) + PanicOnError("failed to load owner shares", err) + + currentOwnerSharesETH := IweiToEther(shares.WithdrawableShares[0]) + currentOwnerSharesWei := shares.WithdrawableShares[0] withdrawableRestakedExecutionLayerGwei, err := eigenPod.WithdrawableRestakedExecutionLayerGwei(nil) PanicOnError("failed to fetch withdrawableRestakedExecutionLayerGwei", err) @@ -168,7 +181,7 @@ func GetStatus(ctx context.Context, eigenpodAddress string, eth *ethclient.Clien // Remove already-computed delta from an in-progress checkpoint sumRestakedBalancesWei = new(big.Int).Sub( sumRestakedBalancesWei, - IGweiToWei(checkpoint.BalanceDeltasGwei), + IGweiToWei(big.NewInt(checkpoint.BalanceDeltasGwei)), ) activeCheckpoint = &Checkpoint{ diff --git a/cli/core/utils.go b/cli/core/utils.go index d1ce0200..0cf0cc63 100644 --- a/cli/core/utils.go +++ b/cli/core/utils.go @@ -15,9 +15,8 @@ import ( "strconv" "strings" + "github.com/Layr-Labs/eigenlayer-contracts/pkg/bindings/EigenPod" eigenpodproofs "github.com/Layr-Labs/eigenpod-proofs-generation" - "github.com/Layr-Labs/eigenpod-proofs-generation/cli/core/multicall" - "github.com/Layr-Labs/eigenpod-proofs-generation/cli/core/onchain" "github.com/Layr-Labs/eigenpod-proofs-generation/cli/utils" "github.com/attestantio/go-eth2-client/spec" "github.com/attestantio/go-eth2-client/spec/phase0" @@ -29,6 +28,7 @@ import ( "github.com/ethereum/go-ethereum/ethclient" "github.com/ethereum/go-ethereum/params" "github.com/fatih/color" + "github.com/jbrower95/multicall-go" ) const ( @@ -105,7 +105,13 @@ type ValidatorWithIndex = struct { } type ValidatorWithOnchainInfo = struct { - Info onchain.IEigenPodValidatorInfo + Info EigenPod.IEigenPodTypesValidatorInfo + Validator *phase0.Validator + Index uint64 +} + +type ValidatorWithMaybeOnchainInfo = struct { + Info *EigenPod.IEigenPodTypesValidatorInfo Validator *phase0.Validator Index uint64 } @@ -123,7 +129,7 @@ func StartCheckpoint(ctx context.Context, eigenpodAddress string, ownerPrivateKe return nil, fmt.Errorf("failed to parse private key: %w", err) } - eigenPod, err := onchain.NewEigenPod(common.HexToAddress(eigenpodAddress), eth) + eigenPod, err := EigenPod.NewEigenPod(common.HexToAddress(eigenpodAddress), eth) if err != nil { return nil, fmt.Errorf("failed to reach eigenpod: %w", err) } @@ -148,7 +154,7 @@ func GetBeaconClient(beaconUri string, verbose bool) (BeaconClient, error) { } func GetCurrentCheckpoint(eigenpodAddress string, client *ethclient.Client) (uint64, error) { - eigenPod, err := onchain.NewEigenPod(common.HexToAddress(eigenpodAddress), client) + eigenPod, err := EigenPod.NewEigenPod(common.HexToAddress(eigenpodAddress), client) if err != nil { return 0, fmt.Errorf("failed to locate eigenpod. is your address correct?: %w", err) } @@ -287,14 +293,14 @@ func FindAllValidatorsForEigenpod(eigenpodAddress string, beaconState *spec.Vers var zeroes = [16]byte{0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00} -func FetchMultipleOnchainValidatorInfoMulticalls(eigenpodAddress string, allValidators []*phase0.Validator) ([]*multicall.MultiCallMetaData[*onchain.IEigenPodValidatorInfo], error) { - eigenpodAbi, err := abi.JSON(strings.NewReader(onchain.EigenPodABI)) +func FetchMultipleOnchainValidatorInfoMulticalls(eigenpodAddress string, allValidators []*phase0.Validator) ([]*multicall.MultiCallMetaData[EigenPod.IEigenPodTypesValidatorInfo], error) { + eigenpodAbi, err := abi.JSON(strings.NewReader(EigenPod.EigenPodABI)) if err != nil { return nil, fmt.Errorf("failed to load eigenpod abi: %s", err) } type MulticallAndError struct { - Multicall *multicall.MultiCallMetaData[*onchain.IEigenPodValidatorInfo] + Multicall *multicall.MultiCallMetaData[EigenPod.IEigenPodTypesValidatorInfo] Error error } @@ -306,13 +312,11 @@ func FetchMultipleOnchainValidatorInfoMulticalls(eigenpodAddress string, allVali ), ) - mc, err := multicall.MultiCall(common.HexToAddress(eigenpodAddress), eigenpodAbi, func(data []byte) (*onchain.IEigenPodValidatorInfo, error) { - res, err := eigenpodAbi.Unpack("validatorPubkeyHashToInfo", data) - if err != nil { - return nil, err - } - return abi.ConvertType(res[0], new(onchain.IEigenPodValidatorInfo)).(*onchain.IEigenPodValidatorInfo), nil - }, "validatorPubkeyHashToInfo", pubKeyHash) + mc, err := multicall.Describe[EigenPod.IEigenPodTypesValidatorInfo]( + common.HexToAddress(eigenpodAddress), + eigenpodAbi, + "validatorPubkeyHashToInfo", + pubKeyHash) return MulticallAndError{ Multicall: mc, @@ -331,7 +335,7 @@ func FetchMultipleOnchainValidatorInfoMulticalls(eigenpodAddress string, allVali return nil, fmt.Errorf("failed to form request for validator info: %s", errors.Join(errs...)) } - allMulticalls := utils.Map(requests, func(mc MulticallAndError, _ uint64) *multicall.MultiCallMetaData[*onchain.IEigenPodValidatorInfo] { + allMulticalls := utils.Map(requests, func(mc MulticallAndError, _ uint64) *multicall.MultiCallMetaData[EigenPod.IEigenPodTypesValidatorInfo] { return mc.Multicall }) return allMulticalls, nil @@ -343,15 +347,14 @@ func FetchMultipleOnchainValidatorInfo(ctx context.Context, client *ethclient.Cl return nil, fmt.Errorf("failed to form multicalls: %s", err.Error()) } - // make the multicall requests - multicallInstance, err := multicall.NewMulticallClient(ctx, client, &multicall.TMulticallClientOptions{ + mc, err := multicall.NewMulticallClient(ctx, client, &multicall.TMulticallClientOptions{ MaxBatchSizeBytes: 4096, }) if err != nil { return nil, fmt.Errorf("failed to contact multicall: %s", err.Error()) } - results, err := multicall.DoMultiCallMany(*multicallInstance, allMulticalls...) + results, err := multicall.DoMany(mc, allMulticalls...) if err != nil { return nil, fmt.Errorf("failed to fetch validator info: %s", err.Error()) } @@ -360,7 +363,7 @@ func FetchMultipleOnchainValidatorInfo(ctx context.Context, client *ethclient.Cl return nil, errors.New("no results returned fetching validator info") } - return utils.Map(*results, func(info *onchain.IEigenPodValidatorInfo, i uint64) ValidatorWithOnchainInfo { + return utils.Map(*results, func(info *EigenPod.IEigenPodTypesValidatorInfo, i uint64) ValidatorWithOnchainInfo { return ValidatorWithOnchainInfo{ Info: *info, Validator: allValidators[i].Validator, @@ -369,8 +372,39 @@ func FetchMultipleOnchainValidatorInfo(ctx context.Context, client *ethclient.Cl }), nil } +func FetchMultipleOnchainValidatorInfoWithFailures(ctx context.Context, client *ethclient.Client, eigenpodAddress string, allValidators []ValidatorWithIndex) ([]ValidatorWithMaybeOnchainInfo, error) { + allMulticalls, err := FetchMultipleOnchainValidatorInfoMulticalls(eigenpodAddress, utils.Map(allValidators, func(validator ValidatorWithIndex, i uint64) *phase0.Validator { return validator.Validator })) + if err != nil { + return nil, fmt.Errorf("failed to form multicalls: %s", err.Error()) + } + + mc, err := multicall.NewMulticallClient(ctx, client, &multicall.TMulticallClientOptions{ + MaxBatchSizeBytes: 4096, + }) + if err != nil { + return nil, fmt.Errorf("failed to contact multicall: %s", err.Error()) + } + + results, err := multicall.DoManyAllowFailures(mc, allMulticalls...) + if err != nil { + return nil, fmt.Errorf("failed to fetch validator info: %s", err.Error()) + } + + if results == nil { + return nil, errors.New("no results returned fetching validator info") + } + + return utils.Map(*results, func(info multicall.TypedMulticall3Result[*EigenPod.IEigenPodTypesValidatorInfo], i uint64) ValidatorWithMaybeOnchainInfo { + return ValidatorWithMaybeOnchainInfo{ + Info: info.Value, + Validator: allValidators[i].Validator, + Index: allValidators[i].Index, + } + }), nil +} + func GetCurrentCheckpointBlockRoot(eigenpodAddress string, eth *ethclient.Client) (*[32]byte, error) { - eigenPod, err := onchain.NewEigenPod(common.HexToAddress(eigenpodAddress), eth) + eigenPod, err := EigenPod.NewEigenPod(common.HexToAddress(eigenpodAddress), eth) if err != nil { return nil, fmt.Errorf("failed to locate Eigenpod. Is your address correct?: %w", err) } @@ -383,7 +417,7 @@ func GetCurrentCheckpointBlockRoot(eigenpodAddress string, eth *ethclient.Client return &checkpoint.BeaconBlockRoot, nil } -func IsAwaitingWithdrawalCredentialProof(validatorInfo onchain.IEigenPodValidatorInfo, validator *phase0.Validator) bool { +func IsAwaitingWithdrawalCredentialProof(validatorInfo EigenPod.IEigenPodTypesValidatorInfo, validator *phase0.Validator) bool { return (validatorInfo.Status == ValidatorStatusInactive) && validator.ExitEpoch == FAR_FUTURE_EPOCH && validator.ActivationEpoch != FAR_FUTURE_EPOCH } @@ -426,12 +460,12 @@ func GetClients(ctx context.Context, node, beaconNodeUri string, enableLogs bool return eth, beaconClient, chainId, nil } -func CastBalanceProofs(proofs []*eigenpodproofs.BalanceProof) []onchain.BeaconChainProofsBalanceProof { - out := []onchain.BeaconChainProofsBalanceProof{} +func CastBalanceProofs(proofs []*eigenpodproofs.BalanceProof) []EigenPod.BeaconChainProofsBalanceProof { + out := []EigenPod.BeaconChainProofsBalanceProof{} for i := 0; i < len(proofs); i++ { proof := proofs[i] - out = append(out, onchain.BeaconChainProofsBalanceProof{ + out = append(out, EigenPod.BeaconChainProofsBalanceProof{ PubkeyHash: proof.PubkeyHash, BalanceRoot: proof.BalanceRoot, Proof: proof.Proof.ToByteSlice(), diff --git a/cli/core/validator.go b/cli/core/validator.go index 3ffc5b28..0de9abd8 100644 --- a/cli/core/validator.go +++ b/cli/core/validator.go @@ -8,8 +8,8 @@ import ( "os" "strconv" + "github.com/Layr-Labs/eigenlayer-contracts/pkg/bindings/EigenPod" eigenpodproofs "github.com/Layr-Labs/eigenpod-proofs-generation" - "github.com/Layr-Labs/eigenpod-proofs-generation/cli/core/onchain" "github.com/Layr-Labs/eigenpod-proofs-generation/cli/utils" v1 "github.com/attestantio/go-eth2-client/api/v1" "github.com/attestantio/go-eth2-client/spec" @@ -46,7 +46,7 @@ func SubmitValidatorProof(ctx context.Context, owner, eigenpodAddress string, ch } PanicOnError("failed to parse private key", err) - eigenPod, err := onchain.NewEigenPod(common.HexToAddress(eigenpodAddress), eth) + eigenPod, err := EigenPod.NewEigenPod(common.HexToAddress(eigenpodAddress), eth) if err != nil { return nil, [][]*big.Int{}, err } @@ -98,14 +98,14 @@ func SubmitValidatorProof(ctx context.Context, owner, eigenpodAddress string, ch return transactions, validatorIndicesChunks, err } -func SubmitValidatorProofChunk(ctx context.Context, ownerAccount *Owner, eigenPod *onchain.EigenPod, chainId *big.Int, eth *ethclient.Client, indices []*big.Int, validatorFields [][][32]byte, stateRootProofs *eigenpodproofs.StateRootProof, validatorFieldsProofs [][]byte, oracleBeaconTimesetamp uint64, verbose bool) (*types.Transaction, error) { +func SubmitValidatorProofChunk(ctx context.Context, ownerAccount *Owner, eigenPod *EigenPod.EigenPod, chainId *big.Int, eth *ethclient.Client, indices []*big.Int, validatorFields [][][32]byte, stateRootProofs *eigenpodproofs.StateRootProof, validatorFieldsProofs [][]byte, oracleBeaconTimesetamp uint64, verbose bool) (*types.Transaction, error) { if verbose { - color.Green("submitting onchain...") + color.Green("submitting...") } txn, err := eigenPod.VerifyWithdrawalCredentials( ownerAccount.TransactionOptions, oracleBeaconTimesetamp, - onchain.BeaconChainProofsStateRootProof{ + EigenPod.BeaconChainProofsStateRootProof{ Proof: stateRootProofs.Proof.ToByteSlice(), BeaconStateRoot: stateRootProofs.BeaconStateRoot, }, @@ -127,7 +127,7 @@ func GenerateValidatorProof(ctx context.Context, eigenpodAddress string, eth *et return nil, 0, fmt.Errorf("failed to load latest block: %w", err) } - eigenPod, err := onchain.NewEigenPod(common.HexToAddress(eigenpodAddress), eth) + eigenPod, err := EigenPod.NewEigenPod(common.HexToAddress(eigenpodAddress), eth) if err != nil { return nil, 0, fmt.Errorf("failed to reach eigenpod: %w", err) } diff --git a/cli/main.go b/cli/main.go index c88cfb16..99fed8b2 100644 --- a/cli/main.go +++ b/cli/main.go @@ -33,21 +33,6 @@ func main() { EnableBashCompletion: true, UseShortOptionHandling: true, Commands: []*cli.Command{ - { - Name: "total-checkpointable-value", - Args: true, - Usage: "Computes the sum of all shares that would be minted if every EigenPod on the network ran a checkpoint right now.", - Flags: []cli.Flag{ - ExecNodeFlag, - BeaconNodeFlag, - }, - Action: func(_ *cli.Context) error { - return commands.ComputeCheckpointableValueCommand(commands.TComputeCheckpointableValueCommandArgs{ - Node: node, - BeaconNode: beacon, - }) - }, - }, { Name: "find-stale-pods", Args: true, diff --git a/cli/utils/utils.go b/cli/utils/utils.go index fc0abf92..ecbc4539 100644 --- a/cli/utils/utils.go +++ b/cli/utils/utils.go @@ -64,6 +64,15 @@ func Reduce[A any, B any](coll []A, processor func(accum B, next A) B, initialSt return val } +func Unique[A comparable](coll []A) []A { + values := map[A]bool{} + return Filter(coll, func(item A) bool { + isSet := values[item] + values[item] = true + return !isSet + }) +} + func Flatten[A any](coll [][]A) []A { out := []A{} for _, arr := range coll { diff --git a/go.mod b/go.mod index 6880404a..e737d3e5 100644 --- a/go.mod +++ b/go.mod @@ -1,15 +1,17 @@ module github.com/Layr-Labs/eigenpod-proofs-generation -go 1.21 +go 1.22.0 -toolchain go1.21.7 +toolchain go1.22.4 require ( + github.com/Layr-Labs/eigenlayer-contracts v0.4.3-mainnet-rewards-foundation-incentives.0.20241216232148-75428be65f85 github.com/attestantio/go-eth2-client v0.19.9 - github.com/ethereum/go-ethereum v1.13.14 + github.com/ethereum/go-ethereum v1.14.9 github.com/fatih/color v1.16.0 github.com/ferranbt/fastssz v0.1.3 github.com/hashicorp/golang-lru/v2 v2.0.7 + github.com/jbrower95/multicall-go v0.0.0-20241012224745-7e9c19976cb5 github.com/minio/sha256-simd v1.0.1 github.com/pkg/errors v0.9.1 github.com/rs/zerolog v1.29.1 @@ -18,30 +20,30 @@ require ( ) require ( - github.com/Microsoft/go-winio v0.6.1 // indirect - github.com/StackExchange/wmi v1.2.1 // indirect + github.com/Microsoft/go-winio v0.6.2 // indirect github.com/beorn7/perks v1.0.1 // indirect - github.com/bits-and-blooms/bitset v1.10.0 // indirect - github.com/btcsuite/btcd/btcec/v2 v2.2.0 // indirect - github.com/cespare/xxhash/v2 v2.2.0 // indirect - github.com/consensys/bavard v0.1.13 // indirect - github.com/consensys/gnark-crypto v0.12.1 // indirect + github.com/bits-and-blooms/bitset v1.14.3 // indirect + github.com/btcsuite/btcd/btcec/v2 v2.3.4 // indirect + github.com/cespare/xxhash/v2 v2.3.0 // indirect + github.com/consensys/bavard v0.1.16 // indirect + github.com/consensys/gnark-crypto v0.14.0 // indirect github.com/cpuguy83/go-md2man/v2 v2.0.2 // indirect - github.com/crate-crypto/go-kzg-4844 v0.7.0 // indirect + github.com/crate-crypto/go-ipa v0.0.0-20240724233137-53bbb0ceb27a // indirect + github.com/crate-crypto/go-kzg-4844 v1.1.0 // indirect github.com/davecgh/go-spew v1.1.1 // indirect - github.com/deckarep/golang-set/v2 v2.1.0 // indirect - github.com/decred/dcrd/dcrec/secp256k1/v4 v4.0.1 // indirect - github.com/ethereum/c-kzg-4844 v0.4.0 // indirect - github.com/fsnotify/fsnotify v1.6.0 // indirect + github.com/deckarep/golang-set/v2 v2.6.0 // indirect + github.com/decred/dcrd/dcrec/secp256k1/v4 v4.3.0 // indirect + github.com/ethereum/c-kzg-4844 v1.0.3 // indirect + github.com/ethereum/go-verkle v0.1.1-0.20240829091221-dffa7562dbe9 // indirect + github.com/fsnotify/fsnotify v1.7.0 // indirect github.com/go-logr/logr v1.2.4 // indirect github.com/go-logr/stdr v1.2.2 // indirect github.com/go-ole/go-ole v1.3.0 // indirect github.com/goccy/go-yaml v1.9.2 // indirect github.com/google/uuid v1.6.0 // indirect - github.com/gorilla/websocket v1.4.2 // indirect - github.com/holiman/uint256 v1.2.4 // indirect + github.com/gorilla/websocket v1.5.3 // indirect + github.com/holiman/uint256 v1.3.1 // indirect github.com/huandu/go-clone v1.6.0 // indirect - github.com/klauspost/compress v1.16.0 // indirect github.com/klauspost/cpuid/v2 v2.2.6 // indirect github.com/mattn/go-colorable v0.1.13 // indirect github.com/mattn/go-isatty v0.0.20 // indirect @@ -55,23 +57,22 @@ require ( github.com/prysmaticlabs/go-bitfield v0.0.0-20210809151128-385d8c5e3fb7 // indirect github.com/r3labs/sse/v2 v2.10.0 // indirect github.com/russross/blackfriday/v2 v2.1.0 // indirect - github.com/shirou/gopsutil v3.21.4-0.20210419000835-c7a38de76ee5+incompatible // indirect - github.com/supranational/blst v0.3.11 // indirect - github.com/tklauser/go-sysconf v0.3.12 // indirect - github.com/tklauser/numcpus v0.6.1 // indirect + github.com/shirou/gopsutil v3.21.11+incompatible // indirect + github.com/supranational/blst v0.3.13 // indirect + github.com/tklauser/go-sysconf v0.3.14 // indirect + github.com/tklauser/numcpus v0.8.0 // indirect github.com/xrash/smetrics v0.0.0-20201216005158-039620a65673 // indirect + github.com/yusufpapurcu/wmi v1.2.4 // indirect go.opentelemetry.io/otel v1.16.0 // indirect go.opentelemetry.io/otel/metric v1.16.0 // indirect go.opentelemetry.io/otel/trace v1.16.0 // indirect - golang.org/x/crypto v0.18.0 // indirect - golang.org/x/exp v0.0.0-20231110203233-9a3e6036ecaa // indirect - golang.org/x/mod v0.16.0 // indirect - golang.org/x/net v0.20.0 // indirect - golang.org/x/sync v0.5.0 // indirect - golang.org/x/sys v0.16.0 // indirect - golang.org/x/tools v0.15.0 // indirect + golang.org/x/crypto v0.27.0 // indirect + golang.org/x/exp v0.0.0-20240909161429-701f63a606c0 // indirect + golang.org/x/net v0.29.0 // indirect + golang.org/x/sync v0.8.0 // indirect + golang.org/x/sys v0.25.0 // indirect golang.org/x/xerrors v0.0.0-20231012003039-104605ab7028 // indirect - google.golang.org/protobuf v1.32.0 // indirect + google.golang.org/protobuf v1.34.2 // indirect gopkg.in/cenkalti/backoff.v1 v1.1.0 // indirect gopkg.in/yaml.v2 v2.4.0 // indirect gopkg.in/yaml.v3 v3.0.1 // indirect diff --git a/go.sum b/go.sum index 955c3d18..941725d2 100644 --- a/go.sum +++ b/go.sum @@ -1,80 +1,80 @@ github.com/DataDog/zstd v1.4.5 h1:EndNeuB0l9syBZhut0wns3gV1hL8zX8LIu6ZiVHWLIQ= github.com/DataDog/zstd v1.4.5/go.mod h1:1jcaCB/ufaK+sKp1NBhlGmpz41jOoPQ35bpF36t7BBo= -github.com/Microsoft/go-winio v0.6.1 h1:9/kr64B9VUZrLm5YYwbGtUJnMgqWVOdUAXu6Migciow= -github.com/Microsoft/go-winio v0.6.1/go.mod h1:LRdKpFKfdobln8UmuiYcKPot9D2v6svN5+sAH+4kjUM= -github.com/StackExchange/wmi v1.2.1 h1:VIkavFPXSjcnS+O8yTq7NI32k0R5Aj+v39y29VYDOSA= -github.com/StackExchange/wmi v1.2.1/go.mod h1:rcmrprowKIVzvc+NUiLncP2uuArMWLCbu9SBzvHz7e8= -github.com/VictoriaMetrics/fastcache v1.12.1 h1:i0mICQuojGDL3KblA7wUNlY5lOK6a4bwt3uRKnkZU40= -github.com/VictoriaMetrics/fastcache v1.12.1/go.mod h1:tX04vaqcNoQeGLD+ra5pU5sWkuxnzWhEzLwhP9w653o= +github.com/Layr-Labs/eigenlayer-contracts v0.4.3-mainnet-rewards-foundation-incentives.0.20241216232148-75428be65f85 h1:nyMTaafrT29KlAKFisfhVVCRU+MZucnnIgO3M8M6qe0= +github.com/Layr-Labs/eigenlayer-contracts v0.4.3-mainnet-rewards-foundation-incentives.0.20241216232148-75428be65f85/go.mod h1:Ie8YE3EQkTHqG6/tnUS0He7/UPMkXPo/3OFXwSy0iRo= +github.com/Microsoft/go-winio v0.6.2 h1:F2VQgta7ecxGYO8k3ZZz3RS8fVIXVxONVUPlNERoyfY= +github.com/Microsoft/go-winio v0.6.2/go.mod h1:yd8OoFMLzJbo9gZq8j5qaps8bJ9aShtEA8Ipt1oGCvU= +github.com/VictoriaMetrics/fastcache v1.12.2 h1:N0y9ASrJ0F6h0QaC3o6uJb3NIZ9VKLjCM7NQbSmF7WI= +github.com/VictoriaMetrics/fastcache v1.12.2/go.mod h1:AmC+Nzz1+3G2eCPapF6UcsnkThDcMsQicp4xDukwJYI= github.com/attestantio/go-eth2-client v0.19.9 h1:g5LLX3X7cLC0KS0oai/MtxBOZz3U3QPIX5qryYMxgVE= github.com/attestantio/go-eth2-client v0.19.9/go.mod h1:TTz7YF6w4z6ahvxKiHuGPn6DbQn7gH6HPuWm/DEQeGE= github.com/beorn7/perks v1.0.1 h1:VlbKKnNfV8bJzeqoa4cOKqO6bYr3WgKZxO8Z16+hsOM= github.com/beorn7/perks v1.0.1/go.mod h1:G2ZrVWU2WbWT9wwq4/hrbKbnv/1ERSJQ0ibhJ6rlkpw= -github.com/bits-and-blooms/bitset v1.10.0 h1:ePXTeiPEazB5+opbv5fr8umg2R/1NlzgDsyepwsSr88= -github.com/bits-and-blooms/bitset v1.10.0/go.mod h1:7hO7Gc7Pp1vODcmWvKMRA9BNmbv6a/7QIWpPxHddWR8= -github.com/btcsuite/btcd/btcec/v2 v2.2.0 h1:fzn1qaOt32TuLjFlkzYSsBC35Q3KUjT1SwPxiMSCF5k= -github.com/btcsuite/btcd/btcec/v2 v2.2.0/go.mod h1:U7MHm051Al6XmscBQ0BoNydpOTsFAn707034b5nY8zU= +github.com/bits-and-blooms/bitset v1.14.3 h1:Gd2c8lSNf9pKXom5JtD7AaKO8o7fGQ2LtFj1436qilA= +github.com/bits-and-blooms/bitset v1.14.3/go.mod h1:7hO7Gc7Pp1vODcmWvKMRA9BNmbv6a/7QIWpPxHddWR8= +github.com/btcsuite/btcd/btcec/v2 v2.3.4 h1:3EJjcN70HCu/mwqlUsGK8GcNVyLVxFDlWurTXGPFfiQ= +github.com/btcsuite/btcd/btcec/v2 v2.3.4/go.mod h1:zYzJ8etWJQIv1Ogk7OzpWjowwOdXY1W/17j2MW85J04= github.com/btcsuite/btcd/chaincfg/chainhash v1.0.1 h1:q0rUy8C/TYNBQS1+CGKw68tLOFYSNEs0TFnxxnS9+4U= github.com/btcsuite/btcd/chaincfg/chainhash v1.0.1/go.mod h1:7SFka0XMvUgj3hfZtydOrQY2mwhPclbT2snogU7SQQc= github.com/cespare/cp v0.1.0 h1:SE+dxFebS7Iik5LK0tsi1k9ZCxEaFX4AjQmoyA+1dJk= github.com/cespare/cp v0.1.0/go.mod h1:SOGHArjBr4JWaSDEVpWpo/hNg6RoKrls6Oh40hiwW+s= -github.com/cespare/xxhash/v2 v2.2.0 h1:DC2CZ1Ep5Y4k3ZQ899DldepgrayRUGE6BBZ/cd9Cj44= -github.com/cespare/xxhash/v2 v2.2.0/go.mod h1:VGX0DQ3Q6kWi7AoAeZDth3/j3BFtOZR5XLFGgcrjCOs= -github.com/cockroachdb/errors v1.8.1 h1:A5+txlVZfOqFBDa4mGz2bUWSp0aHElvHX2bKkdbQu+Y= -github.com/cockroachdb/errors v1.8.1/go.mod h1:qGwQn6JmZ+oMjuLwjWzUNqblqk0xl4CVV3SQbGwK7Ac= -github.com/cockroachdb/logtags v0.0.0-20190617123548-eb05cc24525f h1:o/kfcElHqOiXqcou5a3rIlMc7oJbMQkeLk0VQJ7zgqY= -github.com/cockroachdb/logtags v0.0.0-20190617123548-eb05cc24525f/go.mod h1:i/u985jwjWRlyHXQbwatDASoW0RMlZ/3i9yJHE2xLkI= -github.com/cockroachdb/pebble v0.0.0-20230928194634-aa077af62593 h1:aPEJyR4rPBvDmeyi+l/FS/VtA00IWvjeFvjen1m1l1A= -github.com/cockroachdb/pebble v0.0.0-20230928194634-aa077af62593/go.mod h1:6hk1eMY/u5t+Cf18q5lFMUA1Rc+Sm5I6Ra1QuPyxXCo= -github.com/cockroachdb/redact v1.0.8 h1:8QG/764wK+vmEYoOlfobpe12EQcS81ukx/a4hdVMxNw= -github.com/cockroachdb/redact v1.0.8/go.mod h1:BVNblN9mBWFyMyqK1k3AAiSxhvhfK2oOZZ2lK+dpvRg= -github.com/cockroachdb/sentry-go v0.6.1-cockroachdb.2 h1:IKgmqgMQlVJIZj19CdocBeSfSaiCbEBZGKODaixqtHM= -github.com/cockroachdb/sentry-go v0.6.1-cockroachdb.2/go.mod h1:8BT+cPK6xvFOcRlk0R8eg+OTkcqI6baNH4xAkpiYVvQ= +github.com/cespare/xxhash/v2 v2.3.0 h1:UL815xU9SqsFlibzuggzjXhog7bL6oX9BbNZnL2UFvs= +github.com/cespare/xxhash/v2 v2.3.0/go.mod h1:VGX0DQ3Q6kWi7AoAeZDth3/j3BFtOZR5XLFGgcrjCOs= +github.com/cockroachdb/errors v1.11.3 h1:5bA+k2Y6r+oz/6Z/RFlNeVCesGARKuC6YymtcDrbC/I= +github.com/cockroachdb/errors v1.11.3/go.mod h1:m4UIW4CDjx+R5cybPsNrRbreomiFqt8o1h1wUVazSd8= +github.com/cockroachdb/fifo v0.0.0-20240606204812-0bbfbd93a7ce h1:giXvy4KSc/6g/esnpM7Geqxka4WSqI1SZc7sMJFd3y4= +github.com/cockroachdb/fifo v0.0.0-20240606204812-0bbfbd93a7ce/go.mod h1:9/y3cnZ5GKakj/H4y9r9GTjCvAFta7KLgSHPJJYc52M= +github.com/cockroachdb/logtags v0.0.0-20230118201751-21c54148d20b h1:r6VH0faHjZeQy818SGhaone5OnYfxFR/+AzdY3sf5aE= +github.com/cockroachdb/logtags v0.0.0-20230118201751-21c54148d20b/go.mod h1:Vz9DsVWQQhf3vs21MhPMZpMGSht7O/2vFW2xusFUVOs= +github.com/cockroachdb/pebble v1.1.2 h1:CUh2IPtR4swHlEj48Rhfzw6l/d0qA31fItcIszQVIsA= +github.com/cockroachdb/pebble v1.1.2/go.mod h1:4exszw1r40423ZsmkG/09AFEG83I0uDgfujJdbL6kYU= +github.com/cockroachdb/redact v1.1.5 h1:u1PMllDkdFfPWaNGMyLD1+so+aq3uUItthCFqzwPJ30= +github.com/cockroachdb/redact v1.1.5/go.mod h1:BVNblN9mBWFyMyqK1k3AAiSxhvhfK2oOZZ2lK+dpvRg= github.com/cockroachdb/tokenbucket v0.0.0-20230807174530-cc333fc44b06 h1:zuQyyAKVxetITBuuhv3BI9cMrmStnpT18zmgmTxunpo= github.com/cockroachdb/tokenbucket v0.0.0-20230807174530-cc333fc44b06/go.mod h1:7nc4anLGjupUW/PeY5qiNYsdNXj7zopG+eqsS7To5IQ= -github.com/consensys/bavard v0.1.13 h1:oLhMLOFGTLdlda/kma4VOJazblc7IM5y5QPd2A/YjhQ= -github.com/consensys/bavard v0.1.13/go.mod h1:9ItSMtA/dXMAiL7BG6bqW2m3NdSEObYWoH223nGHukI= -github.com/consensys/gnark-crypto v0.12.1 h1:lHH39WuuFgVHONRl3J0LRBtuYdQTumFSDtJF7HpyG8M= -github.com/consensys/gnark-crypto v0.12.1/go.mod h1:v2Gy7L/4ZRosZ7Ivs+9SfUDr0f5UlG+EM5t7MPHiLuY= +github.com/consensys/bavard v0.1.16 h1:3+nT0BqzKg84VtCY9eNN2Glkf1X7dbS5yhh5849syJ8= +github.com/consensys/bavard v0.1.16/go.mod h1:9ItSMtA/dXMAiL7BG6bqW2m3NdSEObYWoH223nGHukI= +github.com/consensys/gnark-crypto v0.14.0 h1:DDBdl4HaBtdQsq/wfMwJvZNE80sHidrK3Nfrefatm0E= +github.com/consensys/gnark-crypto v0.14.0/go.mod h1:CU4UijNPsHawiVGNxe9co07FkzCeWHHrb1li/n1XoU0= github.com/coreos/go-systemd/v22 v22.5.0/go.mod h1:Y58oyj3AT4RCenI/lSvhwexgC+NSVTIJ3seZv2GcEnc= github.com/cpuguy83/go-md2man/v2 v2.0.2 h1:p1EgwI/C7NhT0JmVkwCD2ZBK8j4aeHQX2pMHHBfMQ6w= github.com/cpuguy83/go-md2man/v2 v2.0.2/go.mod h1:tgQtvFlXSQOSOSIRvRPT7W67SCa46tRHOmNcaadrF8o= -github.com/crate-crypto/go-ipa v0.0.0-20231025140028-3c0104f4b233 h1:d28BXYi+wUpz1KBmiF9bWrjEMacUEREV6MBi2ODnrfQ= -github.com/crate-crypto/go-ipa v0.0.0-20231025140028-3c0104f4b233/go.mod h1:geZJZH3SzKCqnz5VT0q/DyIG/tvu/dZk+VIfXicupJs= -github.com/crate-crypto/go-kzg-4844 v0.7.0 h1:C0vgZRk4q4EZ/JgPfzuSoxdCq3C3mOZMBShovmncxvA= -github.com/crate-crypto/go-kzg-4844 v0.7.0/go.mod h1:1kMhvPgI0Ky3yIa+9lFySEBUBXkYxeOi8ZF1sYioxhc= +github.com/crate-crypto/go-ipa v0.0.0-20240724233137-53bbb0ceb27a h1:W8mUrRp6NOVl3J+MYp5kPMoUZPp7aOYHtaua31lwRHg= +github.com/crate-crypto/go-ipa v0.0.0-20240724233137-53bbb0ceb27a/go.mod h1:sTwzHBvIzm2RfVCGNEBZgRyjwK40bVoun3ZnGOCafNM= +github.com/crate-crypto/go-kzg-4844 v1.1.0 h1:EN/u9k2TF6OWSHrCCDBBU6GLNMq88OspHHlMnHfoyU4= +github.com/crate-crypto/go-kzg-4844 v1.1.0/go.mod h1:JolLjpSff1tCCJKaJx4psrlEdlXuJEC996PL3tTAFks= github.com/davecgh/go-spew v1.1.0/go.mod h1:J7Y8YcW2NihsgmVo/mv3lAwl/skON4iLHjSsI+c5H38= github.com/davecgh/go-spew v1.1.1 h1:vj9j/u1bqnvCEfJOwUhtlOARqs3+rkHYY13jYWTU97c= github.com/davecgh/go-spew v1.1.1/go.mod h1:J7Y8YcW2NihsgmVo/mv3lAwl/skON4iLHjSsI+c5H38= -github.com/deckarep/golang-set/v2 v2.1.0 h1:g47V4Or+DUdzbs8FxCCmgb6VYd+ptPAngjM6dtGktsI= -github.com/deckarep/golang-set/v2 v2.1.0/go.mod h1:VAky9rY/yGXJOLEDv3OMci+7wtDpOF4IN+y82NBOac4= -github.com/decred/dcrd/crypto/blake256 v1.0.0 h1:/8DMNYp9SGi5f0w7uCm6d6M4OU2rGFK09Y2A4Xv7EE0= -github.com/decred/dcrd/crypto/blake256 v1.0.0/go.mod h1:sQl2p6Y26YV+ZOcSTP6thNdn47hh8kt6rqSlvmrXFAc= -github.com/decred/dcrd/dcrec/secp256k1/v4 v4.0.1 h1:YLtO71vCjJRCBcrPMtQ9nqBsqpA1m5sE92cU+pd5Mcc= -github.com/decred/dcrd/dcrec/secp256k1/v4 v4.0.1/go.mod h1:hyedUtir6IdtD/7lIxGeCxkaw7y45JueMRL4DIyJDKs= -github.com/ethereum/c-kzg-4844 v0.4.0 h1:3MS1s4JtA868KpJxroZoepdV0ZKBp3u/O5HcZ7R3nlY= -github.com/ethereum/c-kzg-4844 v0.4.0/go.mod h1:VewdlzQmpT5QSrVhbBuGoCdFJkpaJlO1aQputP83wc0= -github.com/ethereum/go-ethereum v1.13.14 h1:EwiY3FZP94derMCIam1iW4HFVrSgIcpsu0HwTQtm6CQ= -github.com/ethereum/go-ethereum v1.13.14/go.mod h1:TN8ZiHrdJwSe8Cb6x+p0hs5CxhJZPbqB7hHkaUXcmIU= +github.com/deckarep/golang-set/v2 v2.6.0 h1:XfcQbWM1LlMB8BsJ8N9vW5ehnnPVIw0je80NsVHagjM= +github.com/deckarep/golang-set/v2 v2.6.0/go.mod h1:VAky9rY/yGXJOLEDv3OMci+7wtDpOF4IN+y82NBOac4= +github.com/decred/dcrd/crypto/blake256 v1.0.1 h1:7PltbUIQB7u/FfZ39+DGa/ShuMyJ5ilcvdfma9wOH6Y= +github.com/decred/dcrd/crypto/blake256 v1.0.1/go.mod h1:2OfgNZ5wDpcsFmHmCK5gZTPcCXqlm2ArzUIkw9czNJo= +github.com/decred/dcrd/dcrec/secp256k1/v4 v4.3.0 h1:rpfIENRNNilwHwZeG5+P150SMrnNEcHYvcCuK6dPZSg= +github.com/decred/dcrd/dcrec/secp256k1/v4 v4.3.0/go.mod h1:v57UDF4pDQJcEfFUCRop3lJL149eHGSe9Jvczhzjo/0= +github.com/ethereum/c-kzg-4844 v1.0.3 h1:IEnbOHwjixW2cTvKRUlAAUOeleV7nNM/umJR+qy4WDs= +github.com/ethereum/c-kzg-4844 v1.0.3/go.mod h1:VewdlzQmpT5QSrVhbBuGoCdFJkpaJlO1aQputP83wc0= +github.com/ethereum/go-ethereum v1.14.9 h1:J7iwXDrtUyE9FUjUYbd4c9tyzwMh6dTJsKzo9i6SrwA= +github.com/ethereum/go-ethereum v1.14.9/go.mod h1:QeW+MtTpRdBEm2pUFoonByee8zfHv7kGp0wK0odvU1I= +github.com/ethereum/go-verkle v0.1.1-0.20240829091221-dffa7562dbe9 h1:8NfxH2iXvJ60YRB8ChToFTUzl8awsc3cJ8CbLjGIl/A= +github.com/ethereum/go-verkle v0.1.1-0.20240829091221-dffa7562dbe9/go.mod h1:M3b90YRnzqKyyzBEWJGqj8Qff4IDeXnzFw0P9bFw3uk= github.com/fatih/color v1.10.0/go.mod h1:ELkj/draVOlAH/xkhN6mQ50Qd0MPOk5AAr3maGEBuJM= github.com/fatih/color v1.16.0 h1:zmkK9Ngbjj+K0yRhTVONQh1p/HknKYSlNT+vZCzyokM= github.com/fatih/color v1.16.0/go.mod h1:fL2Sau1YI5c0pdGEVCbKQbLXB6edEj1ZgiY4NijnWvE= github.com/ferranbt/fastssz v0.1.3 h1:ZI+z3JH05h4kgmFXdHuR1aWYsgrg7o+Fw7/NCzM16Mo= github.com/ferranbt/fastssz v0.1.3/go.mod h1:0Y9TEd/9XuFlh7mskMPfXiI2Dkw4Ddg9EyXt1W7MRvE= -github.com/fjl/memsize v0.0.2 h1:27txuSD9or+NZlnOWdKUxeBzTAUkWCVh+4Gf2dWFOzA= -github.com/fjl/memsize v0.0.2/go.mod h1:VvhXpOYNQvB+uIk2RvXzuaQtkQJzzIx6lSBe1xv7hi0= -github.com/fsnotify/fsnotify v1.6.0 h1:n+5WquG0fcWoWp6xPWfHdbskMCQaFnG6PfBrh1Ky4HY= -github.com/fsnotify/fsnotify v1.6.0/go.mod h1:sl3t1tCWJFWoRz9R8WJCbQihKKwmorjAbSClcnxKAGw= +github.com/fsnotify/fsnotify v1.7.0 h1:8JEhPFa5W2WU7YfeZzPNqzMP6Lwt7L2715Ggo0nosvA= +github.com/fsnotify/fsnotify v1.7.0/go.mod h1:40Bi/Hjc2AVfZrqy+aj+yEI+/bRxZnMJyTJwOpGvigM= github.com/gballet/go-libpcsclite v0.0.0-20190607065134-2772fd86a8ff h1:tY80oXqGNY4FhTFhk+o9oFHGINQ/+vhlm8HFzi6znCI= github.com/gballet/go-libpcsclite v0.0.0-20190607065134-2772fd86a8ff/go.mod h1:x7DCsMOv1taUwEWCzT4cmDeAkigA5/QCwUodaVOe8Ww= -github.com/gballet/go-verkle v0.1.1-0.20231031103413-a67434b50f46 h1:BAIP2GihuqhwdILrV+7GJel5lyPV3u1+PgzrWLc0TkE= -github.com/gballet/go-verkle v0.1.1-0.20231031103413-a67434b50f46/go.mod h1:QNpY22eby74jVhqH4WhDLDwxc/vqsern6pW+u2kbkpc= +github.com/getsentry/sentry-go v0.27.0 h1:Pv98CIbtB3LkMWmXi4Joa5OOcwbmnX88sF5qbK3r3Ps= +github.com/getsentry/sentry-go v0.27.0/go.mod h1:lc76E2QywIyW8WuBnwl8Lc4bkmQH4+w1gwTf25trprY= github.com/go-logr/logr v1.2.2/go.mod h1:jdQByPbusPIv2/zmleS9BjJVeZ6kBagPoEUsqbVz/1A= github.com/go-logr/logr v1.2.4 h1:g01GSCwiDw2xSZfjJ2/T9M+S6pFdcNtFYsp+Y43HYDQ= github.com/go-logr/logr v1.2.4/go.mod h1:jdQByPbusPIv2/zmleS9BjJVeZ6kBagPoEUsqbVz/1A= github.com/go-logr/stdr v1.2.2 h1:hSWxHoqTgW2S2qGc0LTAI563KZ5YKYRhT3MFKZMbjag= github.com/go-logr/stdr v1.2.2/go.mod h1:mMo/vtBO5dYbehREoey6XUKy/eSumjCCveDpRre4VKE= -github.com/go-ole/go-ole v1.2.5/go.mod h1:pprOEPIfldk/42T2oK7lQ4v4JSDwmV0As9GaiUsvbm0= +github.com/go-ole/go-ole v1.2.6/go.mod h1:pprOEPIfldk/42T2oK7lQ4v4JSDwmV0As9GaiUsvbm0= github.com/go-ole/go-ole v1.3.0 h1:Dt6ye7+vXGIKZ7Xtk4s6/xVdGDQynvom7xCFEdWr6uE= github.com/go-ole/go-ole v1.3.0/go.mod h1:5LS6F96DhAwUc7C+1HLexzMXY1xGRSryjyPPKW6zv78= github.com/go-playground/assert/v2 v2.0.1/go.mod h1:VDjEfimB/XKnb+ZQfWdccd7VUvScMdVu0Titje2rxJ4= @@ -102,8 +102,8 @@ github.com/google/gofuzz v1.2.0/go.mod h1:dBl0BpW6vV/+mYPU4Po3pmUjxk6FQPldtuIdl/ github.com/google/subcommands v1.2.0/go.mod h1:ZjhPrFU+Olkh9WazFPsl27BQ4UPiG37m3yTrtFlrHVk= github.com/google/uuid v1.6.0 h1:NIvaJDMOsjHA8n1jAhLSgzrAzy1Hgr+hNrb57e+94F0= github.com/google/uuid v1.6.0/go.mod h1:TIyPZe4MgqvfeYDBFedMoGGpEw/LqOeaOT+nhxU+yHo= -github.com/gorilla/websocket v1.4.2 h1:+/TMaTYc4QFitKJxsQ7Yye35DkWvkdLcvGKqM+x0Ufc= -github.com/gorilla/websocket v1.4.2/go.mod h1:YR8l580nyteQvAITg2hZ9XVh4b55+EU/adAjf1fMHhE= +github.com/gorilla/websocket v1.5.3 h1:saDtZ6Pbx/0u+bgYQ3q96pZgCzfhKXGPqt7kZ72aNNg= +github.com/gorilla/websocket v1.5.3/go.mod h1:YR8l580nyteQvAITg2hZ9XVh4b55+EU/adAjf1fMHhE= github.com/hashicorp/go-bexpr v0.1.10 h1:9kuI5PFotCboP3dkDYFr/wi0gg0QVbSNz5oFRpxn4uE= github.com/hashicorp/go-bexpr v0.1.10/go.mod h1:oxlubA2vC/gFVfX1A6JGp7ls7uCDlfJn732ehYYg+g0= github.com/hashicorp/golang-lru/v2 v2.0.7 h1:a+bsQ5rvGLjzHuww6tVxozPZFVghXaHOwFs4luLUK2k= @@ -112,8 +112,8 @@ github.com/holiman/billy v0.0.0-20240216141850-2abb0c79d3c4 h1:X4egAf/gcS1zATw6w github.com/holiman/billy v0.0.0-20240216141850-2abb0c79d3c4/go.mod h1:5GuXa7vkL8u9FkFuWdVvfR5ix8hRB7DbOAaYULamFpc= github.com/holiman/bloomfilter/v2 v2.0.3 h1:73e0e/V0tCydx14a0SCYS/EWCxgwLZ18CZcZKVu0fao= github.com/holiman/bloomfilter/v2 v2.0.3/go.mod h1:zpoh+gs7qcpqrHr3dB55AMiJwo0iURXE7ZOP9L9hSkA= -github.com/holiman/uint256 v1.2.4 h1:jUc4Nk8fm9jZabQuqr2JzednajVmBpC+oiTiXZJEApU= -github.com/holiman/uint256 v1.2.4/go.mod h1:EOMSn4q6Nyt9P6efbI3bueV4e1b3dGlUCXeiRV4ng7E= +github.com/holiman/uint256 v1.3.1 h1:JfTzmih28bittyHM8z360dCjIA9dbPIBlcTI6lmctQs= +github.com/holiman/uint256 v1.3.1/go.mod h1:EOMSn4q6Nyt9P6efbI3bueV4e1b3dGlUCXeiRV4ng7E= github.com/huandu/go-assert v1.1.5 h1:fjemmA7sSfYHJD7CUqs9qTwwfdNAx7/j2/ZlHXzNB3c= github.com/huandu/go-assert v1.1.5/go.mod h1:yOLvuqZwmcHIC5rIzrBhT7D3Q9c3GFnd0JrPVhn/06U= github.com/huandu/go-clone v1.6.0 h1:HMo5uvg4wgfiy5FoGOqlFLQED/VGRm2D9Pi8g1FXPGc= @@ -124,6 +124,8 @@ github.com/huin/goupnp v1.3.0 h1:UvLUlWDNpoUdYzb2TCn+MuTWtcjXKSza2n6CBdQ0xXc= github.com/huin/goupnp v1.3.0/go.mod h1:gnGPsThkYa7bFi/KWmEysQRf48l2dvR5bxr2OFckNX8= github.com/jackpal/go-nat-pmp v1.0.2 h1:KzKSgb7qkJvOUTqYl9/Hg/me3pWgBmERKrTGD7BdWus= github.com/jackpal/go-nat-pmp v1.0.2/go.mod h1:QPH045xvCAeXUZOxsnwmrtiCoxIr9eob+4orBN1SBKc= +github.com/jbrower95/multicall-go v0.0.0-20241012224745-7e9c19976cb5 h1:MbF9mcEhOK8A1lphvcfh5Tg7Y2p4iUAtw2+yz3jUa94= +github.com/jbrower95/multicall-go v0.0.0-20241012224745-7e9c19976cb5/go.mod h1:cl6hJrk69g0EyKPgNySQbJE1nj29t2q7Pu0as27uC04= github.com/klauspost/compress v1.16.0 h1:iULayQNOReoYUe+1qtKOqw9CwJv3aNQu8ivo7lw1HU4= github.com/klauspost/compress v1.16.0/go.mod h1:ntbaceVETuRiXiv4DpjP66DpAtAGkEQskQzEyD//IeE= github.com/klauspost/cpuid/v2 v2.2.6 h1:ndNyv040zDGIDh8thGkXYjnFtiN02M1PVVF+JE/48xc= @@ -134,8 +136,8 @@ github.com/kr/text v0.2.0 h1:5Nx0Ya0ZqY2ygV366QzturHI13Jq95ApcVaJBhpS+AY= github.com/kr/text v0.2.0/go.mod h1:eLer722TekiGuMkidMxC/pM04lWEeraHUUmBw8l2grE= github.com/kylelemons/godebug v1.1.0 h1:RPNrshWIDI6G2gRW9EHilWtl7Z6Sb1BR0xunSBf0SNc= github.com/kylelemons/godebug v1.1.0/go.mod h1:9/0rRGxNHcop5bhtWyNeEfOS8JIWk580+fNqagV/RAw= -github.com/leanovate/gopter v0.2.9 h1:fQjYxZaynp97ozCzfOyOuAGOU4aU/z37zf/tOujFk7c= -github.com/leanovate/gopter v0.2.9/go.mod h1:U2L/78B+KVFIx2VmW6onHJQzXtFb+p5y3y2Sh+Jxxv8= +github.com/leanovate/gopter v0.2.11 h1:vRjThO1EKPb/1NsDXuDrzldR28RLkBflWYcU9CvzWu4= +github.com/leanovate/gopter v0.2.11/go.mod h1:aK3tzZP/C+p1m3SPRE4SYZFGP7jjkuSI4f7Xvpt0S9c= github.com/leodido/go-urn v1.2.0 h1:hpXL4XnriNwQ/ABnpepYM/1vCLWNDfUNts8dX3xTG6Y= github.com/leodido/go-urn v1.2.0/go.mod h1:+8+nEpDfqqsY+g338gtMEUOtuK+4dEMhiQEgxpxOKII= github.com/mattn/go-colorable v0.1.8/go.mod h1:u6P/XSegPjTcexA+o6vUJrdnUu04hMope9wVRipJSqc= @@ -178,8 +180,8 @@ github.com/r3labs/sse/v2 v2.10.0 h1:hFEkLLFY4LDifoHdiCN/LlGBAdVJYsANaLqNYa1l/v0= github.com/r3labs/sse/v2 v2.10.0/go.mod h1:Igau6Whc+F17QUgML1fYe1VPZzTV6EMCnYktEmkNJ7I= github.com/rivo/uniseg v0.2.0 h1:S1pD9weZBuJdFmowNwbpi7BJ8TNftyUImj/0WQi72jY= github.com/rivo/uniseg v0.2.0/go.mod h1:J6wj4VEh+S6ZtnVlnTBMWIodfgj8LQOQFoIToxlJtxc= -github.com/rogpeppe/go-internal v1.11.0 h1:cWPaGQEPrBb5/AsnsZesgZZ9yb1OQ+GOISoDNXVBh4M= -github.com/rogpeppe/go-internal v1.11.0/go.mod h1:ddIwULY96R17DhadqLgMfk9H9tvdUzkipdSkR5nkCZA= +github.com/rogpeppe/go-internal v1.12.0 h1:exVL4IDcn6na9z1rAb56Vxr+CgyK3nn3O+epU5NdKM8= +github.com/rogpeppe/go-internal v1.12.0/go.mod h1:E+RYuTGaKKdloAfM02xzb0FW3Paa99yedzYV+kq4uf4= github.com/rs/cors v1.7.0 h1:+88SsELBHx5r+hZ8TCkggzSstaWNbDvThkVK8H6f9ik= github.com/rs/cors v1.7.0/go.mod h1:gFx+x8UowdsKA9AchylcLynDq+nNFfI8FkUZdN/jGCU= github.com/rs/xid v1.4.0/go.mod h1:trrq9SKmegXys3aeAKXMUTdJsYXVwGY3RLcfgqegfbg= @@ -187,8 +189,8 @@ github.com/rs/zerolog v1.29.1 h1:cO+d60CHkknCbvzEWxP0S9K6KqyTjrCNUy1LdQLCGPc= github.com/rs/zerolog v1.29.1/go.mod h1:Le6ESbR7hc+DP6Lt1THiV8CQSdkkNrd3R0XbEgp3ZBU= github.com/russross/blackfriday/v2 v2.1.0 h1:JIOH55/0cWyOuilr9/qlrm0BSXldqnqwMsf35Ld67mk= github.com/russross/blackfriday/v2 v2.1.0/go.mod h1:+Rmxgy9KzJVeS9/2gXHxylqXiyQDYRxCVz55jmeOWTM= -github.com/shirou/gopsutil v3.21.4-0.20210419000835-c7a38de76ee5+incompatible h1:Bn1aCHHRnjv4Bl16T8rcaFjYSrGrIZvpiGO6P3Q4GpU= -github.com/shirou/gopsutil v3.21.4-0.20210419000835-c7a38de76ee5+incompatible/go.mod h1:5b4v6he4MtMOwMlS0TUMTu2PcXUg8+E1lC7eC3UO/RA= +github.com/shirou/gopsutil v3.21.11+incompatible h1:+1+c1VGhc88SSonWP6foOcLhvnKlUeu/erjjvaPEYiI= +github.com/shirou/gopsutil v3.21.11+incompatible/go.mod h1:5b4v6he4MtMOwMlS0TUMTu2PcXUg8+E1lC7eC3UO/RA= github.com/status-im/keycard-go v0.2.0 h1:QDLFswOQu1r5jsycloeQh3bVU8n/NatHHaZobtDnDzA= github.com/status-im/keycard-go v0.2.0/go.mod h1:wlp8ZLbsmrF6g6WjugPAx+IzoLrkdf9+mHxBEeo3Hbg= github.com/stretchr/objx v0.1.0/go.mod h1:HFkY916IF+rwdDfMAkV7OtwuqBVzrE8GR6GFx+wExME= @@ -196,14 +198,14 @@ github.com/stretchr/testify v1.4.0/go.mod h1:j7eGeouHqKxXV5pUuKE4zz7dFj8WfuZ+81P github.com/stretchr/testify v1.7.0/go.mod h1:6Fq8oRcR53rry900zMqJjRRixrwX3KX962/h/Wwjteg= github.com/stretchr/testify v1.9.0 h1:HtqpIVDClZ4nwg75+f6Lvsy/wHu+3BoSGCbBAcpTsTg= github.com/stretchr/testify v1.9.0/go.mod h1:r2ic/lqez/lEtzL7wO/rwa5dbSLXVDPFyf8C91i36aY= -github.com/supranational/blst v0.3.11 h1:LyU6FolezeWAhvQk0k6O/d49jqgO52MSDDfYgbeoEm4= -github.com/supranational/blst v0.3.11/go.mod h1:jZJtfjgudtNl4en1tzwPIV3KjUnQUvG3/j+w+fVonLw= +github.com/supranational/blst v0.3.13 h1:AYeSxdOMacwu7FBmpfloBz5pbFXDmJL33RuwnKtmTjk= +github.com/supranational/blst v0.3.13/go.mod h1:jZJtfjgudtNl4en1tzwPIV3KjUnQUvG3/j+w+fVonLw= github.com/syndtr/goleveldb v1.0.1-0.20210819022825-2ae1ddf74ef7 h1:epCh84lMvA70Z7CTTCmYQn2CKbY8j86K7/FAIr141uY= github.com/syndtr/goleveldb v1.0.1-0.20210819022825-2ae1ddf74ef7/go.mod h1:q4W45IWZaF22tdD+VEXcAWRA037jwmWEB5VWYORlTpc= -github.com/tklauser/go-sysconf v0.3.12 h1:0QaGUFOdQaIVdPgfITYzaTegZvdCjmYO52cSFAEVmqU= -github.com/tklauser/go-sysconf v0.3.12/go.mod h1:Ho14jnntGE1fpdOqQEEaiKRpvIavV0hSfmBq8nJbHYI= -github.com/tklauser/numcpus v0.6.1 h1:ng9scYS7az0Bk4OZLvrNXNSAO2Pxr1XXRAPyjhIx+Fk= -github.com/tklauser/numcpus v0.6.1/go.mod h1:1XfjsgE2zo8GVw7POkMbHENHzVg3GzmoZ9fESEdAacY= +github.com/tklauser/go-sysconf v0.3.14 h1:g5vzr9iPFFz24v2KZXs/pvpvh8/V9Fw6vQK5ZZb78yU= +github.com/tklauser/go-sysconf v0.3.14/go.mod h1:1ym4lWMLUOhuBOPGtRcJm7tEGX4SCYNEEEtghGG/8uY= +github.com/tklauser/numcpus v0.8.0 h1:Mx4Wwe/FjZLeQsK/6kt2EOepwwSl7SmJrK5bV/dXYgY= +github.com/tklauser/numcpus v0.8.0/go.mod h1:ZJZlAY+dmR4eut8epnzf0u/VwodKmryxR8txiloSqBE= github.com/tyler-smith/go-bip39 v1.1.0 h1:5eUemwrMargf3BSLRRCalXT93Ns6pQJIjYQN2nyfOP8= github.com/tyler-smith/go-bip39 v1.1.0/go.mod h1:gUYDtqQw1JS3ZJ8UWVcGTGqqr6YIN3CWg+kkNaLt55U= github.com/umbracle/gohashtree v0.0.2-alpha.0.20230207094856-5b775a815c10 h1:CQh33pStIp/E30b7TxDlXfM0145bn2e8boI30IxAhTg= @@ -212,6 +214,8 @@ github.com/urfave/cli/v2 v2.27.1 h1:8xSQ6szndafKVRmfyeUMxkNUJQMjL1F2zmsZ+qHpfho= github.com/urfave/cli/v2 v2.27.1/go.mod h1:8qnjx1vcq5s2/wpsqoZFndg2CE5tNFyrTvS6SinrnYQ= github.com/xrash/smetrics v0.0.0-20201216005158-039620a65673 h1:bAn7/zixMGCfxrRTfdpNzjtPYqr8smhKouy9mxVdGPU= github.com/xrash/smetrics v0.0.0-20201216005158-039620a65673/go.mod h1:N3UwUGtsrSj3ccvlPHLoLsHnpR27oXr4ZE984MbSER8= +github.com/yusufpapurcu/wmi v1.2.4 h1:zFUKzehAFReQwLys1b/iSMl+JQGSCSjtVqQn9bBrPo0= +github.com/yusufpapurcu/wmi v1.2.4/go.mod h1:SBZ9tNy3G9/m5Oi98Zks0QjeHVDvuK0qfxQmPyzfmi0= go.opentelemetry.io/otel v1.16.0 h1:Z7GVAX/UkAXPKsy94IU+i6thsQS4nb7LviLpnaNeW8s= go.opentelemetry.io/otel v1.16.0/go.mod h1:vl0h9NUa1D5s1nv3A5vZOYWn8av4K8Ml6JDeHrT/bx4= go.opentelemetry.io/otel/metric v1.16.0 h1:RbrpwVG1Hfv85LgnZ7+txXioPDoh6EdbZHo26Q3hqOo= @@ -220,18 +224,16 @@ go.opentelemetry.io/otel/trace v1.16.0 h1:8JRpaObFoW0pxuVPapkgH8UhHQj+bJW8jJsCZE go.opentelemetry.io/otel/trace v1.16.0/go.mod h1:Yt9vYq1SdNz3xdjZZK7wcXv1qv2pwLkqr2QVwea0ef0= golang.org/x/crypto v0.0.0-20190308221718-c2843e01d9a2/go.mod h1:djNgcEr1/C05ACkg1iLfiJU5Ep61QUkGW8qpdssI0+w= golang.org/x/crypto v0.0.0-20200622213623-75b288015ac9/go.mod h1:LzIPMQfyMNhhGPhUkYOs5KpL4U8rLKemX1yGLhDgUto= -golang.org/x/crypto v0.18.0 h1:PGVlW0xEltQnzFZ55hkuX5+KLyrMYhHld1YHO4AKcdc= -golang.org/x/crypto v0.18.0/go.mod h1:R0j02AL6hcrfOiy9T4ZYp/rcWeMxM3L6QYxlOuEG1mg= -golang.org/x/exp v0.0.0-20231110203233-9a3e6036ecaa h1:FRnLl4eNAQl8hwxVVC17teOw8kdjVDVAiFMtgUdTSRQ= -golang.org/x/exp v0.0.0-20231110203233-9a3e6036ecaa/go.mod h1:zk2irFbV9DP96SEBUUAy67IdHUaZuSnrz1n472HUCLE= -golang.org/x/mod v0.16.0 h1:QX4fJ0Rr5cPQCF7O9lh9Se4pmwfwskqZfq5moyldzic= -golang.org/x/mod v0.16.0/go.mod h1:hTbmBsO62+eylJbnUtE2MGJUyE7QWk4xUqPFrRgJ+7c= +golang.org/x/crypto v0.27.0 h1:GXm2NjJrPaiv/h1tb2UH8QfgC/hOf/+z0p6PT8o1w7A= +golang.org/x/crypto v0.27.0/go.mod h1:1Xngt8kV6Dvbssa53Ziq6Eqn0HqbZi5Z6R0ZpwQzt70= +golang.org/x/exp v0.0.0-20240909161429-701f63a606c0 h1:e66Fs6Z+fZTbFBAxKfP3PALWBtpfqks2bwGcexMxgtk= +golang.org/x/exp v0.0.0-20240909161429-701f63a606c0/go.mod h1:2TbTHSBQa924w8M6Xs1QcRcFwyucIwBGpK1p2f1YFFY= golang.org/x/net v0.0.0-20190404232315-eb5bcb51f2a3/go.mod h1:t9HGtf8HONx5eT2rtn7q6eTqICYqUVnKs3thJo3Qplg= golang.org/x/net v0.0.0-20191116160921-f9c825593386/go.mod h1:z5CRVTTTmAJ677TzLLGU+0bjPO0LkuOLi4/5GtJWs/s= -golang.org/x/net v0.20.0 h1:aCL9BSgETF1k+blQaYUBx9hJ9LOGP3gAVemcZlf1Kpo= -golang.org/x/net v0.20.0/go.mod h1:z8BVo6PvndSri0LbOE3hAn0apkU+1YvI6E70E9jsnvY= -golang.org/x/sync v0.5.0 h1:60k92dhOjHxJkrqnwsfl8KuaHbn/5dl0lUPUklKo3qE= -golang.org/x/sync v0.5.0/go.mod h1:Czt+wKu1gCyEFDUtn0jG5QVvpJ6rzVqr5aXyt9drQfk= +golang.org/x/net v0.29.0 h1:5ORfpBpCs4HzDYoodCDBbwHzdR5UrLBZ3sOnUJmFoHo= +golang.org/x/net v0.29.0/go.mod h1:gLkgy8jTGERgjzMic6DS9+SP0ajcu6Xu3Orq/SpETg0= +golang.org/x/sync v0.8.0 h1:3NFvSEYkUoMifnESzZl15y791HH1qU2xm6eCJU5ZPXQ= +golang.org/x/sync v0.8.0/go.mod h1:Czt+wKu1gCyEFDUtn0jG5QVvpJ6rzVqr5aXyt9drQfk= golang.org/x/sys v0.0.0-20190215142949-d0b11bdaac8a/go.mod h1:STP8DvDyc/dI5b8T5hshtkjS+E42TnysNCUPdjciGhY= golang.org/x/sys v0.0.0-20190412213103-97732733099d/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20190916202348-b4ddaad3f8a3/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= @@ -240,35 +242,30 @@ golang.org/x/sys v0.0.0-20200223170610-d5e6a3e2c0ae/go.mod h1:h1NjWce9XRLGQEsW7w golang.org/x/sys v0.0.0-20210630005230-0f9fa26af87c/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= golang.org/x/sys v0.0.0-20210927094055-39ccf1dd6fa6/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= golang.org/x/sys v0.0.0-20220811171246-fbc7d0a398ab/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= -golang.org/x/sys v0.0.0-20220908164124-27713097b956/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= golang.org/x/sys v0.1.0/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= golang.org/x/sys v0.5.0/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= golang.org/x/sys v0.6.0/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= -golang.org/x/sys v0.8.0/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= -golang.org/x/sys v0.11.0/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= -golang.org/x/sys v0.16.0 h1:xWw16ngr6ZMtmxDyKyIgsE93KNKz5HKmMa3b8ALHidU= -golang.org/x/sys v0.16.0/go.mod h1:/VUhepiaJMQUp4+oa/7Zr1D23ma6VTLIYjOOTFZPUcA= +golang.org/x/sys v0.25.0 h1:r+8e+loiHxRqhXVl6ML1nO3l1+oFoWbnlu2Ehimmi34= +golang.org/x/sys v0.25.0/go.mod h1:/VUhepiaJMQUp4+oa/7Zr1D23ma6VTLIYjOOTFZPUcA= golang.org/x/text v0.3.0/go.mod h1:NqM8EUOU14njkJ3fqMW+pc6Ldnwhi/IjpwHt7yyuwOQ= golang.org/x/text v0.3.2/go.mod h1:bEr9sfX3Q8Zfm5fL9x+3itogRgK3+ptLWKqgva+5dAk= -golang.org/x/text v0.14.0 h1:ScX5w1eTa3QqT8oi6+ziP7dTV1S2+ALU0bI+0zXKWiQ= -golang.org/x/text v0.14.0/go.mod h1:18ZOQIKpY8NJVqYksKHtTdi31H5itFRjB5/qKTNYzSU= -golang.org/x/time v0.3.0 h1:rg5rLMjNzMS1RkNLzCG38eapWhnYLFYXDXj2gOlr8j4= -golang.org/x/time v0.3.0/go.mod h1:tRJNPiyCQ0inRvYxbN9jk5I+vvW/OXSQhTDSoE431IQ= +golang.org/x/text v0.18.0 h1:XvMDiNzPAl0jr17s6W9lcaIhGUfUORdGCNsuLmPG224= +golang.org/x/text v0.18.0/go.mod h1:BuEKDfySbSR4drPmRPG/7iBdf8hvFMuRexcpahXilzY= +golang.org/x/time v0.5.0 h1:o7cqy6amK/52YcAKIPlM3a+Fpj35zvRj2TP+e1xFSfk= +golang.org/x/time v0.5.0/go.mod h1:3BpzKBy/shNhVucY/MWOyx10tF3SFh9QdLuxbVysPQM= golang.org/x/tools v0.0.0-20180917221912-90fa682c2a6e/go.mod h1:n7NCudcB/nEzxVGmLbDWY5pfWTLqBcC2KZ6jyYvM4mQ= -golang.org/x/tools v0.15.0 h1:zdAyfUGbYmuVokhzVmghFl2ZJh5QhcfebBgmVPFYA+8= -golang.org/x/tools v0.15.0/go.mod h1:hpksKq4dtpQWS1uQ61JkdqWM3LscIS6Slf+VVkm+wQk= golang.org/x/xerrors v0.0.0-20200804184101-5ec99f83aff1/go.mod h1:I/5z698sn9Ka8TeJc9MKroUUfqBBauWjQqLJ2OPfmY0= golang.org/x/xerrors v0.0.0-20231012003039-104605ab7028 h1:+cNy6SZtPcJQH3LJVLOSmiC7MMxXNOb3PU/VUEz+EhU= golang.org/x/xerrors v0.0.0-20231012003039-104605ab7028/go.mod h1:NDW/Ps6MPRej6fsCIbMTohpP40sJ/P/vI1MoTEGwX90= -google.golang.org/protobuf v1.32.0 h1:pPC6BG5ex8PDFnkbrGU3EixyhKcQ2aDuBS36lqK/C7I= -google.golang.org/protobuf v1.32.0/go.mod h1:c6P6GXX6sHbq/GpV6MGZEdwhWPcYBgnhAHhKbcUYpos= +google.golang.org/protobuf v1.34.2 h1:6xV6lTsCfpGD21XK49h7MhtcApnLqkfYgPcdHftf6hg= +google.golang.org/protobuf v1.34.2/go.mod h1:qYOHts0dSfpeUzUFpOMr/WGzszTmLH+DiWniOlNbLDw= gopkg.in/cenkalti/backoff.v1 v1.1.0 h1:Arh75ttbsvlpVA7WtVpH4u9h6Zl46xuptxqLxPiSo4Y= gopkg.in/cenkalti/backoff.v1 v1.1.0/go.mod h1:J6Vskwqd+OMVJl8C33mmtxTBs2gyzfv7UDAkHu8BrjI= gopkg.in/check.v1 v0.0.0-20161208181325-20d25e280405/go.mod h1:Co6ibVJAznAaIkqp8huTwlJQCZ016jof/cbN4VW5Yz0= gopkg.in/check.v1 v1.0.0-20201130134442-10cb98267c6c h1:Hei/4ADfdWqJk1ZMxUNpqntNwaWcugrBjAiHlqqRiVk= gopkg.in/check.v1 v1.0.0-20201130134442-10cb98267c6c/go.mod h1:JHkPIbrfpd72SG/EVd6muEfDQjcINNoR0C8j2r3qZ4Q= -gopkg.in/natefinch/lumberjack.v2 v2.0.0 h1:1Lc07Kr7qY4U2YPouBjpCLxpiyxIVoxqXgkXLknAOE8= -gopkg.in/natefinch/lumberjack.v2 v2.0.0/go.mod h1:l0ndWWf7gzL7RNwBG7wST/UCcT4T24xpD6X8LsfU/+k= +gopkg.in/natefinch/lumberjack.v2 v2.2.1 h1:bBRl1b0OH9s/DuPhuXpNl+VtCaJXFZ5/uEFST95x9zc= +gopkg.in/natefinch/lumberjack.v2 v2.2.1/go.mod h1:YD8tP3GAjkrDg1eZH7EGmyESg/lsYskCTPBJVb9jqSc= gopkg.in/yaml.v2 v2.2.2/go.mod h1:hI93XBmqTisBFMUTm0b8Fm+jr3Dg1NNxqwp+5A1VGuI= gopkg.in/yaml.v2 v2.4.0 h1:D8xgwECY7CYvx+Y2n4sBz93Jn9JRvxdiyyo8CTfuKaY= gopkg.in/yaml.v2 v2.4.0/go.mod h1:RDklbk79AGWmwhnvt/jBztapEOGDOx6ZbXqjP6csGnQ=