From ba65882b894ffcc02b248f12d62364838476b3da Mon Sep 17 00:00:00 2001 From: David Date: Mon, 25 Mar 2024 13:25:27 +0800 Subject: [PATCH] feat(repo): introduce `txmgr` package (#658) --- bindings/encoding/input.go | 5 + cmd/flags/common.go | 3 +- cmd/flags/proposer.go | 23 +- cmd/flags/prover.go | 29 +- cmd/flags/txmgr.go | 92 +++ driver/chain_syncer/calldata/syncer_test.go | 79 ++- driver/chain_syncer/chain_syncer_test.go | 16 + driver/driver_test.go | 90 +-- driver/txlist_fetcher/blob.go | 3 +- go.mod | 71 +-- go.sum | 299 ++++------ internal/docker/nodes/docker-compose.yml | 6 +- internal/testutils/helper.go | 8 - internal/testutils/interfaces.go | 2 - pkg/flags/config.go | 30 + pkg/rpc/beaconclient.go | 3 +- pkg/rpc/blob.go | 291 ---------- pkg/rpc/blob_tx.go | 3 +- pkg/rpc/blob_tx_test.go | 3 +- pkg/rpc/ethclient_test.go | 19 +- pkg/sender/common.go | 160 ------ pkg/sender/common_test.go | 21 - pkg/sender/sender.go | 536 ------------------ pkg/sender/sender_test.go | 232 -------- proposer/config.go | 101 ++-- proposer/config_test.go | 26 +- proposer/proposer.go | 74 +-- proposer/proposer_test.go | 92 +-- proposer/transaction_builder/blob.go | 39 +- proposer/transaction_builder/calldata.go | 25 +- proposer/transaction_builder/calldata_test.go | 5 +- proposer/transaction_builder/common_test.go | 18 +- proposer/transaction_builder/interface.go | 6 +- prover/config.go | 31 +- prover/config_test.go | 10 +- prover/init.go | 28 +- prover/proof_submitter/proof_contester.go | 6 +- prover/proof_submitter/proof_submitter.go | 8 +- .../proof_submitter/proof_submitter_test.go | 56 +- prover/proof_submitter/transaction/builder.go | 39 +- .../transaction/builder_test.go | 16 +- prover/proof_submitter/transaction/sender.go | 34 +- .../transaction/sender_test.go | 50 +- prover/prover.go | 39 +- prover/prover_test.go | 90 ++- 45 files changed, 807 insertions(+), 2010 deletions(-) create mode 100644 cmd/flags/txmgr.go create mode 100644 pkg/flags/config.go delete mode 100644 pkg/rpc/blob.go delete mode 100644 pkg/sender/common.go delete mode 100644 pkg/sender/common_test.go delete mode 100644 pkg/sender/sender.go delete mode 100644 pkg/sender/sender_test.go diff --git a/bindings/encoding/input.go b/bindings/encoding/input.go index d59ea6b14..fead02380 100644 --- a/bindings/encoding/input.go +++ b/bindings/encoding/input.go @@ -240,6 +240,7 @@ var ( var ( TaikoL1ABI *abi.ABI TaikoL2ABI *abi.ABI + TaikoTokenABI *abi.ABI GuardianProverABI *abi.ABI LibDepositingABI *abi.ABI LibProposingABI *abi.ABI @@ -264,6 +265,10 @@ func init() { log.Crit("Get TaikoL2 ABI error", "error", err) } + if TaikoTokenABI, err = bindings.TaikoTokenMetaData.GetAbi(); err != nil { + log.Crit("Get TaikoToken ABI error", "error", err) + } + if GuardianProverABI, err = bindings.GuardianProverMetaData.GetAbi(); err != nil { log.Crit("Get GuardianProver ABI error", "error", err) } diff --git a/cmd/flags/common.go b/cmd/flags/common.go index 98daef4ab..4f5266403 100644 --- a/cmd/flags/common.go +++ b/cmd/flags/common.go @@ -13,6 +13,7 @@ var ( driverCategory = "DRIVER" proposerCategory = "PROPOSER" proverCategory = "PROVER" + txmgrCategory = "TX_MANAGER" ) // Required flags used by all client software. @@ -112,7 +113,7 @@ var ( Name: "rpc.timeout", Usage: "Timeout in seconds for RPC calls", Category: commonCategory, - Value: 1 * time.Minute, + Value: 12 * time.Second, } WaitReceiptTimeout = &cli.DurationFlag{ Name: "rpc.waitReceiptTimeout", diff --git a/cmd/flags/proposer.go b/cmd/flags/proposer.go index 9c5751b6a..2d159f436 100644 --- a/cmd/flags/proposer.go +++ b/cmd/flags/proposer.go @@ -97,29 +97,13 @@ var ( Value: 1, Category: proposerCategory, } - // Transaction related. - ProposeBlockTxGasLimit = &cli.Uint64Flag{ - Name: "tx.gasLimit", - Usage: "Gas limit will be used for TaikoL1.proposeBlock transactions", - Category: proposerCategory, - } - ProposeBlockTxReplacementMultiplier = &cli.Uint64Flag{ - Name: "tx.replacementMultiplier", - Value: 2, - Usage: "Gas tip multiplier when replacing a TaikoL1.proposeBlock transaction with same nonce", - Category: proposerCategory, - } - ProposeBlockTxGasTipCap = &cli.Uint64Flag{ - Name: "tx.gasTipCap", - Usage: "Gas tip cap (in wei) for a TaikoL1.proposeBlock transaction when doing the transaction replacement", - Category: proposerCategory, - } ProposeBlockIncludeParentMetaHash = &cli.BoolFlag{ Name: "includeParentMetaHash", Usage: "Include parent meta hash when proposing block", Value: false, Category: proposerCategory, } + // Transaction related. BlobAllowed = &cli.BoolFlag{ Name: "l1.blobAllowed", Usage: "Send EIP-4844 blob transactions when proposing blocks", @@ -145,9 +129,6 @@ var ProposerFlags = MergeFlags(CommonFlags, []cli.Flag{ ExtraData, ProposeEmptyBlocksInterval, MaxProposedTxListsPerEpoch, - ProposeBlockTxGasLimit, - ProposeBlockTxReplacementMultiplier, - ProposeBlockTxGasTipCap, ProverEndpoints, OptimisticTierFee, SgxTierFee, @@ -157,4 +138,4 @@ var ProposerFlags = MergeFlags(CommonFlags, []cli.Flag{ ProposerAssignmentHookAddress, BlobAllowed, L1BlockBuilderTip, -}) +}, TxmgrFlags) diff --git a/cmd/flags/prover.go b/cmd/flags/prover.go index 7de07ca85..535c4da6f 100644 --- a/cmd/flags/prover.go +++ b/cmd/flags/prover.go @@ -93,29 +93,6 @@ var ( Value: 0 * time.Second, Category: proverCategory, } - // Transaction related. - ProofSubmissionMaxRetry = &cli.Uint64Flag{ - Name: "tx.submissionMaxRetry", - Usage: "Max retry counts for proof submission", - Value: 3, - Category: proverCategory, - } - ProveBlockTxGasLimit = &cli.Uint64Flag{ - Name: "tx.gasLimit", - Usage: "Gas limit will be used for TaikoL1.proveBlock transactions", - Category: proverCategory, - } - ProveBlockMaxTxGasFeeCap = &cli.Uint64Flag{ - Name: "tx.maxGasFeeCap", - Usage: "Gas fee cap (in wei) for a TaikoL1.proveBlock transaction when doing the transaction replacement", - Category: proverCategory, - } - TxReplacementGasGrowthRate = &cli.Uint64Flag{ - Name: "tx.replacementProveBlockGasGrowthRate", - Value: 50, - Usage: "Gas tip growth rate when replacing a TaikoL1.proveBlock transaction with same nonce", - Category: proverCategory, - } // Running mode ContesterMode = &cli.BoolFlag{ Name: "mode.contester", @@ -211,13 +188,9 @@ var ProverFlags = MergeFlags(CommonFlags, []cli.Flag{ GuardianProver, GuardianProofSubmissionDelay, GuardianProverHealthCheckServerEndpoint, - ProofSubmissionMaxRetry, - TxReplacementGasGrowthRate, - ProveBlockMaxTxGasFeeCap, Graffiti, ProveUnassignedBlocks, ContesterMode, - ProveBlockTxGasLimit, ProverHTTPServerPort, ProverCapacity, MaxExpiry, @@ -229,4 +202,4 @@ var ProverFlags = MergeFlags(CommonFlags, []cli.Flag{ L1NodeVersion, L2NodeVersion, BlockConfirmations, -}) +}, TxmgrFlags) diff --git a/cmd/flags/txmgr.go b/cmd/flags/txmgr.go new file mode 100644 index 000000000..15979903e --- /dev/null +++ b/cmd/flags/txmgr.go @@ -0,0 +1,92 @@ +package flags + +import ( + "time" + + "github.com/urfave/cli/v2" +) + +var ( + NumConfirmations = &cli.Uint64Flag{ + Name: "tx.numConfirmations", + Usage: "Number of confirmations which we will wait after sending a transaction", + Value: 1, + Category: txmgrCategory, + } + SafeAbortNonceTooLowCount = cli.Uint64Flag{ + Name: "tx.safeAbortNonceTooLowCount", + Usage: "Number of ErrNonceTooLow observations required to give up on " + + "a tx at a particular nonce without receiving confirmation", + Value: 3, + Category: txmgrCategory, + } + FeeLimitMultiplier = &cli.Uint64Flag{ + Name: "tx.feeLimitMultiplier", + Usage: "The multiplier applied to fee suggestions to put a hard limit on fee increases", + Value: 10, + Category: txmgrCategory, + } + FeeLimitThreshold = &cli.Float64Flag{ + Name: "tx.feeLimitThreshold", + Usage: "The minimum threshold (in GWei) at which fee bumping starts to be capped. " + + "Allows arbitrary fee bumps below this threshold.", + Value: 100.0, + Category: txmgrCategory, + } + MinTipCap = &cli.Float64Flag{ + Name: "tx.minTipCap", + Usage: "Enforces a minimum tip cap (in GWei) to use when determining tx fees. 1 GWei by default.", + Value: 1.0, + Category: txmgrCategory, + } + MinBaseFee = &cli.Float64Flag{ + Name: "tx.minBaseFee", + Usage: "Enforces a minimum base fee (in GWei) to assume when determining tx fees. 1 GWei by default.", + Value: 1.0, + Category: txmgrCategory, + } + ResubmissionTimeout = &cli.DurationFlag{ + Name: "tx.resubmissionTimeout", + Usage: "Duration we will wait before resubmitting a transaction to L1", + Value: 48 * time.Second, + Category: txmgrCategory, + } + TxSendTimeout = &cli.DurationFlag{ + Name: "tx.sendTimeout", + Usage: "Timeout for sending transactions. If 0 it is disabled.", + Value: 0, + Category: txmgrCategory, + } + TxNotInMempoolTimeout = &cli.DurationFlag{ + Name: "tx.notInMempoolTimeout", + Usage: "Timeout for aborting a tx send if the tx does not make it to the mempool.", + Value: 2 * time.Minute, + Category: txmgrCategory, + } + ReceiptQueryInterval = &cli.DurationFlag{ + Name: "tx.receiptQueryInterval", + Usage: "Frequency to poll for receipts", + Value: 12 * time.Second, + Category: txmgrCategory, + } + TxGasLimit = &cli.Uint64Flag{ + Name: "tx.gasLimit", + Usage: "Gas limit will be used for transactions (0 means using gas estimation)", + Value: 0, + Category: txmgrCategory, + } +) + +var TxmgrFlags = []cli.Flag{ + NumConfirmations, + &SafeAbortNonceTooLowCount, + FeeLimitMultiplier, + FeeLimitThreshold, + MinTipCap, + MinBaseFee, + ResubmissionTimeout, + TxSendTimeout, + TxNotInMempoolTimeout, + ReceiptQueryInterval, + TxGasLimit, +} diff --git a/driver/chain_syncer/calldata/syncer_test.go b/driver/chain_syncer/calldata/syncer_test.go index 30de31d9c..e1e670623 100644 --- a/driver/chain_syncer/calldata/syncer_test.go +++ b/driver/chain_syncer/calldata/syncer_test.go @@ -7,6 +7,7 @@ import ( "testing" "time" + "github.com/ethereum-optimism/optimism/op-service/txmgr" "github.com/ethereum/go-ethereum/common" "github.com/ethereum/go-ethereum/core/rawdb" "github.com/ethereum/go-ethereum/crypto" @@ -43,33 +44,7 @@ func (s *CalldataSyncerTestSuite) SetupTest() { s.Nil(err) s.s = syncer - prop := new(proposer.Proposer) - l1ProposerPrivKey, err := crypto.ToECDSA(common.FromHex(os.Getenv("L1_PROPOSER_PRIVATE_KEY"))) - s.Nil(err) - - s.Nil(prop.InitFromConfig(context.Background(), &proposer.Config{ - ClientConfig: &rpc.ClientConfig{ - L1Endpoint: os.Getenv("L1_NODE_WS_ENDPOINT"), - L2Endpoint: os.Getenv("L2_EXECUTION_ENGINE_WS_ENDPOINT"), - TaikoL1Address: common.HexToAddress(os.Getenv("TAIKO_L1_ADDRESS")), - TaikoL2Address: common.HexToAddress(os.Getenv("TAIKO_L2_ADDRESS")), - TaikoTokenAddress: common.HexToAddress(os.Getenv("TAIKO_TOKEN_ADDRESS")), - }, - AssignmentHookAddress: common.HexToAddress(os.Getenv("ASSIGNMENT_HOOK_ADDRESS")), - L1ProposerPrivKey: l1ProposerPrivKey, - L2SuggestedFeeRecipient: common.HexToAddress(os.Getenv("L2_SUGGESTED_FEE_RECIPIENT")), - ProposeInterval: 1024 * time.Hour, - MaxProposedTxListsPerEpoch: 1, - WaitReceiptTimeout: 12 * time.Second, - ProverEndpoints: s.ProverEndpoints, - OptimisticTierFee: common.Big256, - SgxTierFee: common.Big256, - MaxTierFeePriceBumps: 3, - TierFeePriceBump: common.Big2, - L1BlockBuilderTip: common.Big0, - })) - - s.p = prop + s.initProposer() } func (s *CalldataSyncerTestSuite) TestCancelNewSyncer() { ctx, cancel := context.WithCancel(context.Background()) @@ -222,7 +197,6 @@ func (s *CalldataSyncerTestSuite) TestRetrievePastBlock() { 5, ) s.Nil(err) - sender := s.p.GetSender() s.s = syncer for i := 0; i < 10; i++ { @@ -235,8 +209,8 @@ func (s *CalldataSyncerTestSuite) TestRetrievePastBlock() { s.ProposeAndInsertValidBlock(s.p, s.s) } s.RevertL1Snapshot(l1Snapshot) - // Because of evm_revert operation, the nonce of the proposer need to be adjusted. - s.Nil(sender.SetNonce(nil, true)) + s.initProposer() + // Propose 5 blocks on another fork for i := 0; i < 5; i++ { s.ProposeInvalidTxListBytes(s.p) @@ -248,6 +222,51 @@ func (s *CalldataSyncerTestSuite) TestRetrievePastBlock() { s.GreaterOrEqual(reorgResult.L1CurrentToReset.Number.Uint64(), genesisL1Header.Number.Uint64()) } +func (s *CalldataSyncerTestSuite) initProposer() { + prop := new(proposer.Proposer) + l1ProposerPrivKey, err := crypto.ToECDSA(common.FromHex(os.Getenv("L1_PROPOSER_PRIVATE_KEY"))) + s.Nil(err) + + s.Nil(prop.InitFromConfig(context.Background(), &proposer.Config{ + ClientConfig: &rpc.ClientConfig{ + L1Endpoint: os.Getenv("L1_NODE_WS_ENDPOINT"), + L2Endpoint: os.Getenv("L2_EXECUTION_ENGINE_WS_ENDPOINT"), + TaikoL1Address: common.HexToAddress(os.Getenv("TAIKO_L1_ADDRESS")), + TaikoL2Address: common.HexToAddress(os.Getenv("TAIKO_L2_ADDRESS")), + TaikoTokenAddress: common.HexToAddress(os.Getenv("TAIKO_TOKEN_ADDRESS")), + }, + AssignmentHookAddress: common.HexToAddress(os.Getenv("ASSIGNMENT_HOOK_ADDRESS")), + L1ProposerPrivKey: l1ProposerPrivKey, + L2SuggestedFeeRecipient: common.HexToAddress(os.Getenv("L2_SUGGESTED_FEE_RECIPIENT")), + ProposeInterval: 1024 * time.Hour, + MaxProposedTxListsPerEpoch: 1, + WaitReceiptTimeout: 12 * time.Second, + ProverEndpoints: s.ProverEndpoints, + OptimisticTierFee: common.Big256, + SgxTierFee: common.Big256, + MaxTierFeePriceBumps: 3, + TierFeePriceBump: common.Big2, + L1BlockBuilderTip: common.Big0, + TxmgrConfigs: &txmgr.CLIConfig{ + L1RPCURL: os.Getenv("L1_NODE_WS_ENDPOINT"), + NumConfirmations: 1, + SafeAbortNonceTooLowCount: txmgr.DefaultBatcherFlagValues.SafeAbortNonceTooLowCount, + PrivateKey: common.Bytes2Hex(crypto.FromECDSA(l1ProposerPrivKey)), + FeeLimitMultiplier: txmgr.DefaultBatcherFlagValues.FeeLimitMultiplier, + FeeLimitThresholdGwei: txmgr.DefaultBatcherFlagValues.FeeLimitThresholdGwei, + MinBaseFeeGwei: txmgr.DefaultBatcherFlagValues.MinBaseFeeGwei, + MinTipCapGwei: txmgr.DefaultBatcherFlagValues.MinTipCapGwei, + ResubmissionTimeout: txmgr.DefaultBatcherFlagValues.ResubmissionTimeout, + ReceiptQueryInterval: 1 * time.Second, + NetworkTimeout: txmgr.DefaultBatcherFlagValues.NetworkTimeout, + TxSendTimeout: txmgr.DefaultBatcherFlagValues.TxSendTimeout, + TxNotInMempoolTimeout: txmgr.DefaultBatcherFlagValues.TxNotInMempoolTimeout, + }, + })) + + s.p = prop +} + func TestCalldataSyncerTestSuite(t *testing.T) { suite.Run(t, new(CalldataSyncerTestSuite)) } diff --git a/driver/chain_syncer/chain_syncer_test.go b/driver/chain_syncer/chain_syncer_test.go index 544bbfb49..200453652 100644 --- a/driver/chain_syncer/chain_syncer_test.go +++ b/driver/chain_syncer/chain_syncer_test.go @@ -8,6 +8,7 @@ import ( "testing" "time" + "github.com/ethereum-optimism/optimism/op-service/txmgr" "github.com/ethereum/go-ethereum/accounts/abi/bind" "github.com/ethereum/go-ethereum/common" "github.com/ethereum/go-ethereum/crypto" @@ -69,6 +70,21 @@ func (s *ChainSyncerTestSuite) SetupTest() { TierFeePriceBump: common.Big2, ExtraData: "test", L1BlockBuilderTip: common.Big0, + TxmgrConfigs: &txmgr.CLIConfig{ + L1RPCURL: os.Getenv("L1_NODE_WS_ENDPOINT"), + NumConfirmations: 1, + SafeAbortNonceTooLowCount: txmgr.DefaultBatcherFlagValues.SafeAbortNonceTooLowCount, + PrivateKey: common.Bytes2Hex(crypto.FromECDSA(l1ProposerPrivKey)), + FeeLimitMultiplier: txmgr.DefaultBatcherFlagValues.FeeLimitMultiplier, + FeeLimitThresholdGwei: txmgr.DefaultBatcherFlagValues.FeeLimitThresholdGwei, + MinBaseFeeGwei: txmgr.DefaultBatcherFlagValues.MinBaseFeeGwei, + MinTipCapGwei: txmgr.DefaultBatcherFlagValues.MinTipCapGwei, + ResubmissionTimeout: txmgr.DefaultBatcherFlagValues.ResubmissionTimeout, + ReceiptQueryInterval: 1 * time.Second, + NetworkTimeout: txmgr.DefaultBatcherFlagValues.NetworkTimeout, + TxSendTimeout: txmgr.DefaultBatcherFlagValues.TxSendTimeout, + TxNotInMempoolTimeout: txmgr.DefaultBatcherFlagValues.TxNotInMempoolTimeout, + }, })) s.p = prop diff --git a/driver/driver_test.go b/driver/driver_test.go index 3c1ff2f8b..cb42d2ee7 100644 --- a/driver/driver_test.go +++ b/driver/driver_test.go @@ -7,6 +7,7 @@ import ( "testing" "time" + "github.com/ethereum-optimism/optimism/op-service/txmgr" "github.com/ethereum/go-ethereum/common" "github.com/ethereum/go-ethereum/crypto" "github.com/stretchr/testify/suite" @@ -49,33 +50,7 @@ func (s *DriverTestSuite) SetupTest() { s.cancel = cancel // InitFromConfig proposer - p := new(proposer.Proposer) - - l1ProposerPrivKey, err := crypto.ToECDSA(common.FromHex(os.Getenv("L1_PROPOSER_PRIVATE_KEY"))) - s.Nil(err) - - s.Nil(p.InitFromConfig(context.Background(), &proposer.Config{ - ClientConfig: &rpc.ClientConfig{ - L1Endpoint: os.Getenv("L1_NODE_WS_ENDPOINT"), - L2Endpoint: os.Getenv("L2_EXECUTION_ENGINE_WS_ENDPOINT"), - TaikoL1Address: common.HexToAddress(os.Getenv("TAIKO_L1_ADDRESS")), - TaikoL2Address: common.HexToAddress(os.Getenv("TAIKO_L2_ADDRESS")), - TaikoTokenAddress: common.HexToAddress(os.Getenv("TAIKO_TOKEN_ADDRESS")), - }, - AssignmentHookAddress: common.HexToAddress(os.Getenv("ASSIGNMENT_HOOK_ADDRESS")), - L1ProposerPrivKey: l1ProposerPrivKey, - L2SuggestedFeeRecipient: common.HexToAddress(os.Getenv("L2_SUGGESTED_FEE_RECIPIENT")), - ProposeInterval: 1024 * time.Hour, - MaxProposedTxListsPerEpoch: 1, - WaitReceiptTimeout: 12 * time.Second, - ProverEndpoints: s.ProverEndpoints, - OptimisticTierFee: common.Big256, - SgxTierFee: common.Big256, - MaxTierFeePriceBumps: 3, - TierFeePriceBump: common.Big2, - L1BlockBuilderTip: common.Big0, - })) - s.p = p + s.InitProposer() } func (s *DriverTestSuite) TestName() { @@ -128,7 +103,6 @@ func (s *DriverTestSuite) TestProcessL1Blocks() { func (s *DriverTestSuite) TestCheckL1ReorgToHigherFork() { var ( testnetL1SnapshotID = s.SetL1Snapshot() - sender = s.p.GetSender() ) l1Head1, err := s.d.rpc.L1.HeaderByNumber(context.Background(), nil) s.Nil(err) @@ -156,6 +130,7 @@ func (s *DriverTestSuite) TestCheckL1ReorgToHigherFork() { // Reorg back to l2Head1 s.RevertL1Snapshot(testnetL1SnapshotID) + s.InitProposer() l1Head3, err := s.d.rpc.L1.HeaderByNumber(context.Background(), nil) s.Nil(err) @@ -163,7 +138,6 @@ func (s *DriverTestSuite) TestCheckL1ReorgToHigherFork() { s.Equal(l1Head3.Hash(), l1Head1.Hash()) // Because of evm_revert operation, the nonce of the proposer need to be adjusted. - s.Nil(sender.SetNonce(nil, true)) // Propose ten blocks on another fork for i := 0; i < 10; i++ { s.ProposeInvalidTxListBytes(s.p) @@ -190,7 +164,6 @@ func (s *DriverTestSuite) TestCheckL1ReorgToHigherFork() { func (s *DriverTestSuite) TestCheckL1ReorgToLowerFork() { var ( testnetL1SnapshotID = s.SetL1Snapshot() - sender = s.p.GetSender() ) l1Head1, err := s.d.rpc.L1.HeaderByNumber(context.Background(), nil) s.Nil(err) @@ -218,13 +191,12 @@ func (s *DriverTestSuite) TestCheckL1ReorgToLowerFork() { // Reorg back to l2Head1 s.RevertL1Snapshot(testnetL1SnapshotID) + s.InitProposer() l1Head3, err := s.d.rpc.L1.HeaderByNumber(context.Background(), nil) s.Nil(err) - s.Equal(l1Head3.Number.Uint64(), l1Head1.Number.Uint64()) - s.Equal(l1Head3.Hash(), l1Head1.Hash()) + s.GreaterOrEqual(l1Head3.Number.Uint64(), l1Head1.Number.Uint64()) - s.Nil(sender.SetNonce(nil, true)) // Propose one blocks on another fork s.ProposeInvalidTxListBytes(s.p) @@ -248,7 +220,6 @@ func (s *DriverTestSuite) TestCheckL1ReorgToLowerFork() { func (s *DriverTestSuite) TestCheckL1ReorgToSameHeightFork() { var ( testnetL1SnapshotID = s.SetL1Snapshot() - sender = s.p.GetSender() ) l1Head1, err := s.d.rpc.L1.HeaderByNumber(context.Background(), nil) s.Nil(err) @@ -276,13 +247,12 @@ func (s *DriverTestSuite) TestCheckL1ReorgToSameHeightFork() { // Reorg back to l2Head1 s.RevertL1Snapshot(testnetL1SnapshotID) + s.InitProposer() l1Head3, err := s.d.rpc.L1.HeaderByNumber(context.Background(), nil) s.Nil(err) - s.Equal(l1Head3.Number.Uint64(), l1Head1.Number.Uint64()) - s.Equal(l1Head3.Hash(), l1Head1.Hash()) + s.GreaterOrEqual(l1Head3.Number.Uint64(), l1Head1.Number.Uint64()) - s.Nil(sender.SetNonce(nil, true)) // Propose two blocks on another fork s.ProposeInvalidTxListBytes(s.p) time.Sleep(3 * time.Second) @@ -292,7 +262,6 @@ func (s *DriverTestSuite) TestCheckL1ReorgToSameHeightFork() { s.Nil(err) s.Greater(l1Head4.Number.Uint64(), l1Head3.Number.Uint64()) - s.Equal(l1Head4.Number.Uint64(), l1Head2.Number.Uint64()) s.Nil(s.d.ChainSyncer().CalldataSyncer().ProcessL1Blocks(context.Background(), l1Head4)) @@ -323,6 +292,51 @@ func (s *DriverTestSuite) TestL1Current() { s.Nil(s.d.state.ResetL1Current(s.d.ctx, common.Big1)) } +func (s *DriverTestSuite) InitProposer() { + p := new(proposer.Proposer) + + l1ProposerPrivKey, err := crypto.ToECDSA(common.FromHex(os.Getenv("L1_PROPOSER_PRIVATE_KEY"))) + s.Nil(err) + + s.Nil(p.InitFromConfig(context.Background(), &proposer.Config{ + ClientConfig: &rpc.ClientConfig{ + L1Endpoint: os.Getenv("L1_NODE_WS_ENDPOINT"), + L2Endpoint: os.Getenv("L2_EXECUTION_ENGINE_WS_ENDPOINT"), + TaikoL1Address: common.HexToAddress(os.Getenv("TAIKO_L1_ADDRESS")), + TaikoL2Address: common.HexToAddress(os.Getenv("TAIKO_L2_ADDRESS")), + TaikoTokenAddress: common.HexToAddress(os.Getenv("TAIKO_TOKEN_ADDRESS")), + }, + AssignmentHookAddress: common.HexToAddress(os.Getenv("ASSIGNMENT_HOOK_ADDRESS")), + L1ProposerPrivKey: l1ProposerPrivKey, + L2SuggestedFeeRecipient: common.HexToAddress(os.Getenv("L2_SUGGESTED_FEE_RECIPIENT")), + ProposeInterval: 1024 * time.Hour, + MaxProposedTxListsPerEpoch: 1, + WaitReceiptTimeout: 12 * time.Second, + ProverEndpoints: s.ProverEndpoints, + OptimisticTierFee: common.Big256, + SgxTierFee: common.Big256, + MaxTierFeePriceBumps: 3, + TierFeePriceBump: common.Big2, + L1BlockBuilderTip: common.Big0, + TxmgrConfigs: &txmgr.CLIConfig{ + L1RPCURL: os.Getenv("L1_NODE_WS_ENDPOINT"), + NumConfirmations: 1, + SafeAbortNonceTooLowCount: txmgr.DefaultBatcherFlagValues.SafeAbortNonceTooLowCount, + PrivateKey: common.Bytes2Hex(crypto.FromECDSA(l1ProposerPrivKey)), + FeeLimitMultiplier: txmgr.DefaultBatcherFlagValues.FeeLimitMultiplier, + FeeLimitThresholdGwei: txmgr.DefaultBatcherFlagValues.FeeLimitThresholdGwei, + MinBaseFeeGwei: txmgr.DefaultBatcherFlagValues.MinBaseFeeGwei, + MinTipCapGwei: txmgr.DefaultBatcherFlagValues.MinTipCapGwei, + ResubmissionTimeout: txmgr.DefaultBatcherFlagValues.ResubmissionTimeout, + ReceiptQueryInterval: 1 * time.Second, + NetworkTimeout: txmgr.DefaultBatcherFlagValues.NetworkTimeout, + TxSendTimeout: txmgr.DefaultBatcherFlagValues.TxSendTimeout, + TxNotInMempoolTimeout: txmgr.DefaultBatcherFlagValues.TxNotInMempoolTimeout, + }, + })) + s.p = p +} + func TestDriverTestSuite(t *testing.T) { suite.Run(t, new(DriverTestSuite)) } diff --git a/driver/txlist_fetcher/blob.go b/driver/txlist_fetcher/blob.go index a5b38efac..3f17da247 100644 --- a/driver/txlist_fetcher/blob.go +++ b/driver/txlist_fetcher/blob.go @@ -5,6 +5,7 @@ import ( "crypto/sha256" "math/big" + "github.com/ethereum-optimism/optimism/op-service/eth" "github.com/ethereum/go-ethereum/common" "github.com/ethereum/go-ethereum/core/types" "github.com/ethereum/go-ethereum/crypto/kzg4844" @@ -56,7 +57,7 @@ func (d *BlobFetcher) Fetch( sha256.New(), &commitment, ) == common.BytesToHash(meta.BlobHash[:]) { - blob := rpc.Blob(common.FromHex(sidecar.Blob)) + blob := eth.Blob(common.FromHex(sidecar.Blob)) return blob.ToData() } } diff --git a/go.mod b/go.mod index 4a9f7c5c3..97d108572 100644 --- a/go.mod +++ b/go.mod @@ -5,23 +5,21 @@ go 1.21 require ( github.com/btcsuite/btcd/btcec/v2 v2.3.2 github.com/cenkalti/backoff/v4 v4.1.3 - github.com/creasty/defaults v1.7.0 github.com/decred/dcrd/dcrec/secp256k1/v4 v4.2.0 + github.com/ethereum-optimism/optimism v1.7.0 github.com/ethereum/go-ethereum v1.13.14 github.com/go-resty/resty/v2 v2.7.0 github.com/holiman/uint256 v1.2.4 github.com/joho/godotenv v1.5.1 github.com/labstack/echo/v4 v4.11.1 github.com/modern-go/reflect2 v1.0.2 - github.com/orcaman/concurrent-map/v2 v2.0.1 - github.com/pborman/uuid v1.2.1 github.com/phayes/freeport v0.0.0-20220201140144-74d24b5ae9f5 github.com/prysmaticlabs/prysm/v4 v4.2.0 github.com/stretchr/testify v1.8.4 github.com/swaggo/swag v1.16.2 - github.com/urfave/cli/v2 v2.25.7 + github.com/urfave/cli/v2 v2.27.1 golang.org/x/exp v0.0.0-20231214170342-aacd6d4b4611 - golang.org/x/sync v0.5.0 + golang.org/x/sync v0.6.0 ) require ( @@ -35,13 +33,15 @@ require ( github.com/benbjohnson/clock v1.3.5 // indirect github.com/beorn7/perks v1.0.1 // indirect github.com/bits-and-blooms/bitset v1.10.0 // indirect - github.com/btcsuite/btcd/chaincfg/chainhash v1.0.2 // indirect + github.com/btcsuite/btcd v0.24.0 // indirect + github.com/btcsuite/btcd/btcutil v1.1.5 // indirect + github.com/btcsuite/btcd/chaincfg/chainhash v1.1.0 // indirect github.com/cespare/xxhash v1.1.0 // indirect github.com/cespare/xxhash/v2 v2.2.0 // indirect - github.com/cockroachdb/errors v1.9.1 // indirect + github.com/cockroachdb/errors v1.11.1 // indirect github.com/cockroachdb/logtags v0.0.0-20230118201751-21c54148d20b // indirect - github.com/cockroachdb/pebble v0.0.0-20230928194634-aa077af62593 // indirect - github.com/cockroachdb/redact v1.1.3 // indirect + github.com/cockroachdb/pebble v0.0.0-20231018212520-f6cde3fc2fa4 // indirect + github.com/cockroachdb/redact v1.1.5 // indirect github.com/cockroachdb/tokenbucket v0.0.0-20230807174530-cc333fc44b06 // indirect github.com/consensys/bavard v0.1.13 // indirect github.com/consensys/gnark-crypto v0.12.1 // indirect @@ -57,14 +57,15 @@ require ( github.com/docker/go-units v0.5.0 // indirect github.com/dustin/go-humanize v1.0.0 // indirect github.com/elastic/gosigar v0.14.2 // indirect + github.com/ethereum-optimism/go-ethereum-hdwallet v0.1.3 // indirect github.com/ethereum/c-kzg-4844 v0.4.0 // indirect github.com/fjl/memsize v0.0.2 // indirect github.com/flynn/noise v1.0.0 // indirect github.com/francoispqt/gojay v1.2.13 // indirect - github.com/fsnotify/fsnotify v1.6.0 // indirect + github.com/fsnotify/fsnotify v1.7.0 // indirect github.com/gballet/go-verkle v0.1.1-0.20231031103413-a67434b50f46 // indirect github.com/getsentry/sentry-go v0.18.0 // indirect - github.com/go-logr/logr v1.2.4 // indirect + github.com/go-logr/logr v1.3.0 // indirect github.com/go-ole/go-ole v1.3.0 // indirect github.com/go-openapi/jsonpointer v0.20.0 // indirect github.com/go-openapi/jsonreference v0.20.2 // indirect @@ -79,15 +80,15 @@ require ( github.com/golang/groupcache v0.0.0-20200121045136-8c9f03a8e57e // indirect github.com/golang/protobuf v1.5.3 // indirect github.com/golang/snappy v0.0.5-0.20220116011046-fa5810519dcb // indirect - github.com/google/go-cmp v0.5.9 // indirect - github.com/google/gofuzz v1.2.0 // indirect + github.com/google/go-cmp v0.6.0 // indirect + github.com/google/gofuzz v1.2.1-0.20220503160820-4a35382e8fc8 // indirect github.com/google/gopacket v1.1.19 // indirect github.com/google/pprof v0.0.0-20231023181126-ff6d637d2a7b // indirect github.com/google/uuid v1.6.0 // indirect github.com/gorilla/mux v1.8.0 // indirect github.com/gorilla/websocket v1.5.0 // indirect github.com/grpc-ecosystem/grpc-gateway/v2 v2.0.1 // indirect - github.com/hashicorp/go-bexpr v0.1.10 // indirect + github.com/hashicorp/go-bexpr v0.1.11 // indirect github.com/hashicorp/golang-lru v0.5.5-0.20210104140557-80c98217689d // indirect github.com/hashicorp/golang-lru/v2 v2.0.5 // indirect github.com/herumi/bls-eth-go-binary v0.0.0-20210917013441-d37c07cfda4e // indirect @@ -101,7 +102,7 @@ require ( github.com/json-iterator/go v1.1.12 // indirect github.com/k0kubun/go-ansi v0.0.0-20180517002512-3bf9e2903213 // indirect github.com/klauspost/compress v1.17.2 // indirect - github.com/klauspost/cpuid/v2 v2.2.5 // indirect + github.com/klauspost/cpuid/v2 v2.2.6 // indirect github.com/koron/go-ssdp v0.0.4 // indirect github.com/kr/pretty v0.3.1 // indirect github.com/kr/text v0.2.0 // indirect @@ -125,21 +126,22 @@ require ( github.com/mattn/go-isatty v0.0.20 // indirect github.com/mattn/go-runewidth v0.0.14 // indirect github.com/matttproud/golang_protobuf_extensions v1.0.4 // indirect + github.com/matttproud/golang_protobuf_extensions/v2 v2.0.0 // indirect github.com/miekg/dns v1.1.56 // indirect github.com/mikioh/tcpinfo v0.0.0-20190314235526-30a79bb1804b // indirect github.com/mikioh/tcpopt v0.0.0-20190314235656-172688c1accc // indirect github.com/minio/highwayhash v1.0.2 // indirect github.com/minio/sha256-simd v1.0.1 // indirect github.com/mitchellh/colorstring v0.0.0-20190213212951-d06e56a500db // indirect - github.com/mitchellh/mapstructure v1.4.1 // indirect - github.com/mitchellh/pointerstructure v1.2.0 // indirect + github.com/mitchellh/mapstructure v1.5.0 // indirect + github.com/mitchellh/pointerstructure v1.2.1 // indirect github.com/mmcloughlin/addchain v0.4.0 // indirect github.com/modern-go/concurrent v0.0.0-20180306012644-bacd9c7ef1dd // indirect github.com/mohae/deepcopy v0.0.0-20170929034955-c48cc78d4826 // indirect github.com/mr-tron/base58 v1.2.0 // indirect github.com/multiformats/go-base32 v0.1.0 // indirect github.com/multiformats/go-base36 v0.2.0 // indirect - github.com/multiformats/go-multiaddr v0.12.1 // indirect + github.com/multiformats/go-multiaddr v0.12.2 // indirect github.com/multiformats/go-multiaddr-dns v0.3.1 // indirect github.com/multiformats/go-multiaddr-fmt v0.1.0 // indirect github.com/multiformats/go-multibase v0.2.0 // indirect @@ -148,16 +150,16 @@ require ( github.com/multiformats/go-multistream v0.5.0 // indirect github.com/multiformats/go-varint v0.0.7 // indirect github.com/olekukonko/tablewriter v0.0.5 // indirect - github.com/onsi/ginkgo/v2 v2.13.0 // indirect + github.com/onsi/ginkgo/v2 v2.15.0 // indirect github.com/opencontainers/runtime-spec v1.1.0 // indirect github.com/patrickmn/go-cache v2.1.0+incompatible // indirect github.com/pbnjay/memory v0.0.0-20210728143218-7b4eea64cf58 // indirect github.com/pkg/errors v0.9.1 // indirect github.com/pmezard/go-difflib v1.0.0 // indirect - github.com/prometheus/client_golang v1.14.0 // indirect - github.com/prometheus/client_model v0.4.0 // indirect - github.com/prometheus/common v0.42.0 // indirect - github.com/prometheus/procfs v0.9.0 // indirect + github.com/prometheus/client_golang v1.18.0 // indirect + github.com/prometheus/client_model v0.5.0 // indirect + github.com/prometheus/common v0.45.0 // indirect + github.com/prometheus/procfs v0.12.0 // indirect github.com/prometheus/prom2json v1.3.0 // indirect github.com/prysmaticlabs/fastssz v0.0.0-20221107182844-78142813af44 // indirect github.com/prysmaticlabs/go-bitfield v0.0.0-20210809151128-385d8c5e3fb7 // indirect @@ -165,12 +167,12 @@ require ( github.com/prysmaticlabs/prombbolt v0.0.0-20210126082820-9b7adba6db7c // indirect github.com/quic-go/qpack v0.4.0 // indirect github.com/quic-go/qtls-go1-20 v0.3.4 // indirect - github.com/quic-go/quic-go v0.39.3 // indirect + github.com/quic-go/quic-go v0.39.4 // indirect github.com/quic-go/webtransport-go v0.6.0 // indirect github.com/raulk/go-watchdog v1.3.0 // indirect github.com/rivo/uniseg v0.4.4 // indirect - github.com/rogpeppe/go-internal v1.9.0 // indirect - github.com/rs/cors v1.7.0 // indirect + github.com/rogpeppe/go-internal v1.10.0 // indirect + github.com/rs/cors v1.9.0 // indirect github.com/russross/blackfriday/v2 v2.1.0 // indirect github.com/schollz/progressbar/v3 v3.3.4 // indirect github.com/shirou/gopsutil v3.21.11+incompatible // indirect @@ -183,6 +185,7 @@ require ( github.com/tklauser/go-sysconf v0.3.12 // indirect github.com/tklauser/numcpus v0.6.1 // indirect github.com/trailofbits/go-mutexasserts v0.0.0-20230328101604-8cdbc5f3d279 // indirect + github.com/tyler-smith/go-bip39 v1.1.0 // indirect github.com/uber/jaeger-client-go v2.25.0+incompatible // indirect github.com/valyala/bytebufferpool v1.0.0 // indirect github.com/valyala/fasttemplate v1.2.2 // indirect @@ -196,20 +199,20 @@ require ( go.uber.org/mock v0.3.0 // indirect go.uber.org/multierr v1.11.0 // indirect go.uber.org/zap v1.26.0 // indirect - golang.org/x/crypto v0.17.0 // indirect + golang.org/x/crypto v0.19.0 // indirect golang.org/x/mod v0.14.0 // indirect golang.org/x/net v0.19.0 // indirect - golang.org/x/oauth2 v0.7.0 // indirect - golang.org/x/sys v0.16.0 // indirect - golang.org/x/term v0.15.0 // indirect + golang.org/x/oauth2 v0.12.0 // indirect + golang.org/x/sys v0.17.0 // indirect + golang.org/x/term v0.17.0 // indirect golang.org/x/text v0.14.0 // indirect - golang.org/x/time v0.3.0 // indirect - golang.org/x/tools v0.16.0 // indirect + golang.org/x/time v0.5.0 // indirect + golang.org/x/tools v0.16.1 // indirect google.golang.org/api v0.44.0 // indirect google.golang.org/appengine v1.6.7 // indirect google.golang.org/genproto v0.0.0-20230410155749-daa745c078e1 // indirect google.golang.org/grpc v1.56.3 // indirect - google.golang.org/protobuf v1.30.0 // indirect + google.golang.org/protobuf v1.31.0 // indirect gopkg.in/inf.v0 v0.9.1 // indirect gopkg.in/natefinch/lumberjack.v2 v2.0.0 // indirect gopkg.in/yaml.v2 v2.4.0 // indirect @@ -224,4 +227,4 @@ require ( sigs.k8s.io/yaml v1.3.0 // indirect ) -replace github.com/ethereum/go-ethereum v1.13.14 => github.com/taikoxyz/taiko-geth v0.0.0-20240228040257-a00cd0963e60 +replace github.com/ethereum/go-ethereum v1.13.14 => github.com/taikoxyz/taiko-geth v0.0.0-20240320072400-5db50bce3e8e diff --git a/go.sum b/go.sum index 2064dcd26..906a82fcd 100644 --- a/go.sum +++ b/go.sum @@ -48,7 +48,6 @@ dmitri.shuralyov.com/html/belt v0.0.0-20180602232347-f7d459c86be0/go.mod h1:JLBr dmitri.shuralyov.com/service/change v0.0.0-20181023043359-a85b471d5412/go.mod h1:a1inKt/atXimZ4Mv927x+r7UpyzRUf4emIoiiSC2TN4= dmitri.shuralyov.com/state v0.0.0-20180228185332-28bcc343414c/go.mod h1:0PRwlb0D6DFvNNtx+9ybjezNCa8XF0xaYcETyp6rHWU= git.apache.org/thrift.git v0.0.0-20180902110319-2566ecd5d999/go.mod h1:fPE2ZNJGynbRyZ4dJvy6G277gSllfV2HJqblrnkyeyg= -github.com/AndreasBriese/bbloom v0.0.0-20190306092124-e2d15f34fcf9/go.mod h1:bOvUY6CB00SOBii9/FifXqc0awNKxLFCL/+pkDPuyl8= github.com/Azure/go-autorest v14.2.0+incompatible/go.mod h1:r+4oMnoxhatjLLJ6zxSWATqVooLgysK6ZNox3g/xq24= github.com/Azure/go-autorest/autorest v0.11.1/go.mod h1:JFgpikqFJ/MleTTxwepExTKnFUKKszPS8UavbQYUMuw= github.com/Azure/go-autorest/autorest/adal v0.9.0/go.mod h1:/c022QCutn2P7uY+/oQWWNcK9YU+MH96NgK+jErpbcg= @@ -62,11 +61,8 @@ github.com/BurntSushi/toml v0.3.1/go.mod h1:xHWCNGjB5oqiDr8zfno3MHue2Ht5sIBksp03 github.com/BurntSushi/toml v1.3.2 h1:o7IhLm0Msx3BaB+n3Ag7L8EVlByGnpq14C4YWiu/gL8= github.com/BurntSushi/toml v1.3.2/go.mod h1:CxXYINrC8qIiEnFrOxCa7Jy5BFHlXnUU2pbicEuybxQ= github.com/BurntSushi/xgb v0.0.0-20160522181843-27f122750802/go.mod h1:IVnqGOEym/WlBOVXweHU+Q+/VP0lqqI8lqeDx9IjBqo= -github.com/CloudyKit/fastprinter v0.0.0-20200109182630-33d98a066a53/go.mod h1:+3IMCy2vIlbG1XG/0ggNQv0SvxCAIpPM5b1nCz56Xno= -github.com/CloudyKit/jet/v3 v3.0.0/go.mod h1:HKQPgSJmdK8hdoAbKUUWajkHyHo4RaU5rMdUywE7VMo= github.com/DataDog/zstd v1.5.2 h1:vUG4lAyuPCXO0TLbXvPv7EB7cNK1QV/luu55UHLrrn8= github.com/DataDog/zstd v1.5.2/go.mod h1:g4AWEaM3yOg3HYfnJ3YIawPnVdXJh9QME85blwSAmyw= -github.com/Joker/hpp v1.0.0/go.mod h1:8x5n+M1Hp5hC0g8okX3sR3vFQwynaX/UgSOM9MeBKzY= github.com/Knetic/govaluate v3.0.1-0.20171022003610-9aa49832a739+incompatible/go.mod h1:r7JcOSlj0wfOMncg0iLm8Leh48TZaKVeNIfJntJ2wa0= github.com/KyleBanks/depth v1.2.1 h1:5h8fQADFrWtarTdtDudMmGsC7GPbOAu6RVB3ffsVFHc= github.com/KyleBanks/depth v1.2.1/go.mod h1:jzSb9d0L43HxTQfT+oSA1EEp2q+ne2uh6XgeJcm8brE= @@ -77,22 +73,22 @@ github.com/OneOfOne/xxhash v1.2.2 h1:KMrpdQIwFcEqXDklaen+P1axHaj9BSKzvpUUfnHldSE github.com/OneOfOne/xxhash v1.2.2/go.mod h1:HSdplMjZKSmBqAxg5vPj2TmRDmfkzw+cTzAElWljhcU= github.com/PuerkitoBio/purell v1.1.1/go.mod h1:c11w/QuzBsJSee3cPx9rAFu61PvFxuPbtSwDGJws/X0= github.com/PuerkitoBio/urlesc v0.0.0-20170810143723-de5bf2ad4578/go.mod h1:uGdkoq3SwY9Y+13GIhn11/XLaGBb4BfwItxLd5jeuXE= -github.com/Shopify/goreferrer v0.0.0-20181106222321-ec9c9a553398/go.mod h1:a1uqRtAwp2Xwc6WNPJEufxJ7fx3npB4UV/JOLmbu5I0= github.com/Shopify/sarama v1.19.0/go.mod h1:FVkBWblsNy7DGZRfXLU0O9RCGt5g3g3yEuWXgklEdEo= github.com/Shopify/sarama v1.26.1/go.mod h1:NbSGBSSndYaIhRcBtY9V0U7AyH+x71bG668AuWys/yU= github.com/Shopify/toxiproxy v2.1.4+incompatible/go.mod h1:OXgGpZ6Cli1/URJOF1DMxUHB2q5Ap20/P/eIdh4G0pI= github.com/VictoriaMetrics/fastcache v1.12.1 h1:i0mICQuojGDL3KblA7wUNlY5lOK6a4bwt3uRKnkZU40= github.com/VictoriaMetrics/fastcache v1.12.1/go.mod h1:tX04vaqcNoQeGLD+ra5pU5sWkuxnzWhEzLwhP9w653o= github.com/VividCortex/gohistogram v1.0.0/go.mod h1:Pf5mBqqDxYaXu3hDrrU+w6nw50o/4+TcAqDqk/vUH7g= +github.com/aead/siphash v1.0.1/go.mod h1:Nywa3cDsYNNK3gaciGTWPwHt0wlpNV15vwmswBAUSII= github.com/afex/hystrix-go v0.0.0-20180502004556-fa1af6a1f4f5/go.mod h1:SkGFH1ia65gfNATL8TAiHDNxPzPdmEL5uirI2Uyuz6c= -github.com/ajg/form v1.5.1/go.mod h1:uL1WgH+h2mgNtvBq0339dVnzXdBETtL2LeUXaIv25UY= github.com/alecthomas/template v0.0.0-20160405071501-a0175ee3bccc/go.mod h1:LOuyumcjzFXgccqObfd/Ljyb9UuFJ6TxHnclSeseNhc= github.com/alecthomas/template v0.0.0-20190718012654-fb15b899a751/go.mod h1:LOuyumcjzFXgccqObfd/Ljyb9UuFJ6TxHnclSeseNhc= github.com/alecthomas/units v0.0.0-20151022065526-2efee857e7cf/go.mod h1:ybxpYRFXyAe+OPACYpWeL0wqObRcbAqCMya13uyzqw0= github.com/alecthomas/units v0.0.0-20190717042225-c3de453c63f4/go.mod h1:ybxpYRFXyAe+OPACYpWeL0wqObRcbAqCMya13uyzqw0= github.com/alecthomas/units v0.0.0-20190924025748-f65c72e2690d/go.mod h1:rBZYJk541a8SKzHPHnH3zbiI+7dagKZ0cgpgrD7Fyho= -github.com/allegro/bigcache v1.2.1-0.20190218064605-e24eb225f156 h1:eMwmnE/GDgah4HI848JfFxHt+iPb26b4zyfspmqY0/8= github.com/allegro/bigcache v1.2.1-0.20190218064605-e24eb225f156/go.mod h1:Cb/ax3seSYIx7SuZdm2G2xzfwmv3TPSk2ucNfQESPXM= +github.com/allegro/bigcache v1.2.1 h1:hg1sY1raCwic3Vnsvje6TT7/pnZba83LeFck5NrFKSc= +github.com/allegro/bigcache v1.2.1/go.mod h1:Cb/ax3seSYIx7SuZdm2G2xzfwmv3TPSk2ucNfQESPXM= github.com/anmitsu/go-shlex v0.0.0-20161002113705-648efa622239/go.mod h1:2FmKhYUyUczH0OGQWaF5ceTx0UBShxjsH6f8oGKYe2c= github.com/antihax/optional v1.0.0/go.mod h1:uupD/76wgC+ih3iEmQUL+0Ugr19nfwCT1kdvxnR2qWY= github.com/apache/thrift v0.12.0/go.mod h1:cp2SuWMxlEZw2r+iP2GNCdIi4C1qmUzdZFSVb+bacwQ= @@ -103,7 +99,6 @@ github.com/aristanetworks/goarista v0.0.0-20200805130819-fd197cf57d96 h1:XJH0YfV github.com/aristanetworks/goarista v0.0.0-20200805130819-fd197cf57d96/go.mod h1:QZe5Yh80Hp1b6JxQdpfSEEe8X7hTyTEZSosSrFf/oJE= github.com/aristanetworks/splunk-hec-go v0.3.3/go.mod h1:1VHO9r17b0K7WmOlLb9nTk/2YanvOEnLMUgsFrxBROc= github.com/armon/circbuf v0.0.0-20150827004946-bbbad097214e/go.mod h1:3U/XgcO3hCbHZ8TKRvWD2dDTCfh9M9ya+I9JpbB7O8o= -github.com/armon/consul-api v0.0.0-20180202201655-eb2c6b5be1b6/go.mod h1:grANhF5doyWs3UAsr3K4I6qtAmlQcZDesFNEHPZAzj8= github.com/armon/go-metrics v0.0.0-20180917152333-f0300d1749da/go.mod h1:Q73ZrmVTwzkszR9V5SSuryQ31EELlFMUz1kKyl939pY= github.com/armon/go-radix v0.0.0-20180808171621-7fddfc383310/go.mod h1:ufUuZ+zHj4x4TnLV4JWEpy2hxWSpsRywHrMgIH9cCH8= github.com/aryann/difflib v0.0.0-20170710044230-e206f873d14a/go.mod h1:DAHtR1m6lCRdSC2Tm3DSWRPvIPr6xNKyeHdqDQSQT+A= @@ -111,7 +106,6 @@ github.com/asaskevich/govalidator v0.0.0-20190424111038-f61b66f89f4a/go.mod h1:l github.com/aws/aws-lambda-go v1.13.3/go.mod h1:4UKl9IzQMoD+QF79YdCuzCwp8VbmG4VAQwij/eHl5CU= github.com/aws/aws-sdk-go v1.27.0/go.mod h1:KmX6BPdI08NWTb3/sm4ZGu5ShLoqVDhKgpiN924inxo= github.com/aws/aws-sdk-go-v2 v0.18.0/go.mod h1:JWVYvqSMppoMJC0x5wdwiImzgXTI9FuZwxzkQq9wy+g= -github.com/aymerick/raymond v2.0.3-0.20180322193309-b565731e1464+incompatible/go.mod h1:osfaiScAUVup+UC9Nfq76eWqDhXlp+4UYaA8uhTBO6g= github.com/bazelbuild/rules_go v0.23.2 h1:Wxu7JjqnF78cKZbsBsARLSXx/jlGaSLCnUV3mTlyHvM= github.com/bazelbuild/rules_go v0.23.2/go.mod h1:MC23Dc/wkXEyk3Wpq6lCqz0ZAYOZDw2DR5y3N1q2i7M= github.com/benbjohnson/clock v1.1.0/go.mod h1:J11/hYXuz8f4ySSvYwY0FKfm+ezbsZBKZxNJlLklBHA= @@ -126,10 +120,32 @@ github.com/bgentry/speakeasy v0.1.0/go.mod h1:+zsyZBPWlz7T6j88CTgSN5bM796AkVf0kB 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/bradfitz/go-smtpd v0.0.0-20170404230938-deb6d6237625/go.mod h1:HYsPBTaaSFSlLx/70C2HPIMNZpVV8+vt/A+FMnYP11g= +github.com/btcsuite/btcd v0.20.1-beta/go.mod h1:wVuoA8VJLEcwgqHBwHmzLRazpKxTv13Px/pDuV7OomQ= +github.com/btcsuite/btcd v0.22.0-beta.0.20220111032746-97732e52810c/go.mod h1:tjmYdS6MLJ5/s0Fj4DbLgSbDHbEqLJrtnHecBFkdz5M= +github.com/btcsuite/btcd v0.23.5-0.20231215221805-96c9fd8078fd/go.mod h1:nm3Bko6zh6bWP60UxwoT5LzdGJsQJaPo6HjduXq9p6A= +github.com/btcsuite/btcd v0.24.0 h1:gL3uHE/IaFj6fcZSu03SvqPMSx7s/dPzfpG/atRwWdo= +github.com/btcsuite/btcd v0.24.0/go.mod h1:K4IDc1593s8jKXIF7yS7yCTSxrknB9z0STzc2j6XgE4= +github.com/btcsuite/btcd/btcec/v2 v2.1.0/go.mod h1:2VzYrv4Gm4apmbVVsSq5bqf1Ec8v56E48Vt0Y/umPgA= +github.com/btcsuite/btcd/btcec/v2 v2.1.3/go.mod h1:ctjw4H1kknNJmRN4iP1R7bTQ+v3GJkZBd6mui8ZsAZE= github.com/btcsuite/btcd/btcec/v2 v2.3.2 h1:5n0X6hX0Zk+6omWcihdYvdAlGf2DfasC0GMf7DClJ3U= github.com/btcsuite/btcd/btcec/v2 v2.3.2/go.mod h1:zYzJ8etWJQIv1Ogk7OzpWjowwOdXY1W/17j2MW85J04= -github.com/btcsuite/btcd/chaincfg/chainhash v1.0.2 h1:KdUfX2zKommPRa+PD0sWZUyXe9w277ABlgELO7H04IM= -github.com/btcsuite/btcd/chaincfg/chainhash v1.0.2/go.mod h1:7SFka0XMvUgj3hfZtydOrQY2mwhPclbT2snogU7SQQc= +github.com/btcsuite/btcd/btcutil v1.0.0/go.mod h1:Uoxwv0pqYWhD//tfTiipkxNfdhG9UrLwaeswfjfdF0A= +github.com/btcsuite/btcd/btcutil v1.1.0/go.mod h1:5OapHB7A2hBBWLm48mmw4MOHNJCcUBTwmWH/0Jn8VHE= +github.com/btcsuite/btcd/btcutil v1.1.5 h1:+wER79R5670vs/ZusMTF1yTcRYE5GUsFbdjdisflzM8= +github.com/btcsuite/btcd/btcutil v1.1.5/go.mod h1:PSZZ4UitpLBWzxGd5VGOrLnmOjtPP/a6HaFo12zMs00= +github.com/btcsuite/btcd/chaincfg/chainhash v1.0.0/go.mod h1:7SFka0XMvUgj3hfZtydOrQY2mwhPclbT2snogU7SQQc= +github.com/btcsuite/btcd/chaincfg/chainhash v1.0.1/go.mod h1:7SFka0XMvUgj3hfZtydOrQY2mwhPclbT2snogU7SQQc= +github.com/btcsuite/btcd/chaincfg/chainhash v1.1.0 h1:59Kx4K6lzOW5w6nFlA0v5+lk/6sjybR934QNHSJZPTQ= +github.com/btcsuite/btcd/chaincfg/chainhash v1.1.0/go.mod h1:7SFka0XMvUgj3hfZtydOrQY2mwhPclbT2snogU7SQQc= +github.com/btcsuite/btclog v0.0.0-20170628155309-84c8d2346e9f/go.mod h1:TdznJufoqS23FtqVCzL0ZqgP5MqXbb4fg/WgDys70nA= +github.com/btcsuite/btcutil v0.0.0-20190425235716-9e5f4b9a998d/go.mod h1:+5NJ2+qvTyV9exUAL/rxXi3DcLg2Ts+ymUAY5y4NvMg= +github.com/btcsuite/go-socks v0.0.0-20170105172521-4720035b7bfd/go.mod h1:HHNXQzUsZCxOoE+CPiyCTO6x34Zs86zZUiwtpXoGdtg= +github.com/btcsuite/goleveldb v0.0.0-20160330041536-7834afc9e8cd/go.mod h1:F+uVaaLLH7j4eDXPRvw78tMflu7Ie2bzYOH4Y8rRKBY= +github.com/btcsuite/goleveldb v1.0.0/go.mod h1:QiK9vBlgftBg6rWQIj6wFzbPfRjiykIEhBH4obrXJ/I= +github.com/btcsuite/snappy-go v0.0.0-20151229074030-0bdef8d06723/go.mod h1:8woku9dyThutzjeg+3xrA5iCpBRH8XEEg3lh6TiUghc= +github.com/btcsuite/snappy-go v1.0.0/go.mod h1:8woku9dyThutzjeg+3xrA5iCpBRH8XEEg3lh6TiUghc= +github.com/btcsuite/websocket v0.0.0-20150119174127-31079b680792/go.mod h1:ghJtEyQwv5/p4Mg4C0fgbePVuGr935/5ddU9Z3TmDRY= +github.com/btcsuite/winsvc v1.0.0/go.mod h1:jsenWakMcC0zFBFurPLEAyrnc/teJEM1O46fmI40EZs= github.com/buger/jsonparser v0.0.0-20181115193947-bf1c66bbce23/go.mod h1:bbYlZJ7hK1yFx9hf58LP0zeX7UjIGs20ufpu3evjr+s= github.com/casbin/casbin/v2 v2.1.2/go.mod h1:YcPU1XXisHhLzuxH9coDNf2FbKpjGlbCg3n9yuLkIJQ= github.com/cenkalti/backoff v2.2.1+incompatible/go.mod h1:90ReRw6GdpyfrHakVjL/QHaoyV4aDUVVkXQJJJ3NXXM= @@ -153,22 +169,19 @@ github.com/cncf/udpa/go v0.0.0-20191209042840-269d4d468f6f/go.mod h1:M8M6+tZqaGX github.com/cncf/udpa/go v0.0.0-20200629203442-efcf912fb354/go.mod h1:WmhPx2Nbnhtbo57+VJT5O0JRkEi1Wbu0z5j0R8u5Hbk= github.com/cncf/udpa/go v0.0.0-20201120205902-5459f2c99403/go.mod h1:WmhPx2Nbnhtbo57+VJT5O0JRkEi1Wbu0z5j0R8u5Hbk= github.com/cockroachdb/datadriven v0.0.0-20190809214429-80d97fb3cbaa/go.mod h1:zn76sxSg3SzpJ0PPJaLDCu+Bu0Lg3sKTORVIj19EIF8= -github.com/cockroachdb/datadriven v1.0.2/go.mod h1:a9RdTaap04u637JoCzcUoIcDmvwSUtcUFtT/C3kJlTU= github.com/cockroachdb/datadriven v1.0.3-0.20230413201302-be42291fc80f h1:otljaYPt5hWxV3MUfO5dFPFiOXg9CyG5/kCfayTqsJ4= github.com/cockroachdb/datadriven v1.0.3-0.20230413201302-be42291fc80f/go.mod h1:a9RdTaap04u637JoCzcUoIcDmvwSUtcUFtT/C3kJlTU= -github.com/cockroachdb/errors v1.9.1 h1:yFVvsI0VxmRShfawbt/laCIDy/mtTqqnvoNgiy5bEV8= -github.com/cockroachdb/errors v1.9.1/go.mod h1:2sxOtL2WIc096WSZqZ5h8fa17rdDq9HZOZLBCor4mBk= -github.com/cockroachdb/logtags v0.0.0-20211118104740-dabe8e521a4f/go.mod h1:Vz9DsVWQQhf3vs21MhPMZpMGSht7O/2vFW2xusFUVOs= +github.com/cockroachdb/errors v1.11.1 h1:xSEW75zKaKCWzR3OfxXUxgrk/NtT4G1MiOv5lWZazG8= +github.com/cockroachdb/errors v1.11.1/go.mod h1:8MUxA3Gi6b25tYlFEBGLf+D8aISL+M4MIpiWMSNRfxw= 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 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.1.3 h1:AKZds10rFSIj7qADf0g46UixK8NNLwWTNdCIGS5wfSQ= -github.com/cockroachdb/redact v1.1.3/go.mod h1:BVNblN9mBWFyMyqK1k3AAiSxhvhfK2oOZZ2lK+dpvRg= +github.com/cockroachdb/pebble v0.0.0-20231018212520-f6cde3fc2fa4 h1:PuHFhOUMnD62r80dN+Ik5qco2drekgsUSVdcHsvllec= +github.com/cockroachdb/pebble v0.0.0-20231018212520-f6cde3fc2fa4/go.mod h1:sEHm5NOXxyiAoKWhoFxT8xMgd/f3RA6qUqQ1BXKrh2E= +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/codahale/hdrhistogram v0.0.0-20161010025455-3a0bb77429bd/go.mod h1:sE/e/2PUdi/liOCUjSTXgM1o87ZssimdTWN964YiIeI= -github.com/codegangsta/inject v0.0.0-20150114235600-33e0aa1cb7c0/go.mod h1:4Zcjuz89kmFXt9morQgcfYZAYZ5n8WHjt81YYWIwtTM= 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= @@ -176,8 +189,6 @@ github.com/consensys/gnark-crypto v0.12.1/go.mod h1:v2Gy7L/4ZRosZ7Ivs+9SfUDr0f5U github.com/containerd/cgroups v0.0.0-20201119153540-4cbc285b3327/go.mod h1:ZJeTFisyysqgcCdecO57Dj79RfL0LNeGiFUqLYQRYLE= github.com/containerd/cgroups v1.1.0 h1:v8rEWFl6EoqHB+swVNjVoCJE8o3jX7e8nqBGPLaDFBM= github.com/containerd/cgroups v1.1.0/go.mod h1:6ppBcbh/NOOUU+dMKrykgaBnK9lCIBxHqJDGwsa1mIw= -github.com/coreos/etcd v3.3.10+incompatible/go.mod h1:uF7uidLiAD3TWHmW31ZFd/JWoc32PjwdhPthX9715RE= -github.com/coreos/go-etcd v2.0.0+incompatible/go.mod h1:Jez6KQU2B/sWsbdaef3ED8NzMklzPG4d5KIOhIy30Tk= github.com/coreos/go-semver v0.2.0/go.mod h1:nnelYz7RCh+5ahJtPPxZlU+153eP4D4r3EedlOD2RNk= github.com/coreos/go-systemd v0.0.0-20180511133405-39ca1b05acc7/go.mod h1:F5haX7vjVVG0kc13fIWeqUViNPyEJxv/OmvnBo0Yme4= github.com/coreos/go-systemd v0.0.0-20181012123002-c6f51f82210d/go.mod h1:F5haX7vjVVG0kc13fIWeqUViNPyEJxv/OmvnBo0Yme4= @@ -185,7 +196,6 @@ github.com/coreos/go-systemd/v22 v22.1.0/go.mod h1:xO0FLkIi5MaZafQlIrOotqXZ90ih+ github.com/coreos/go-systemd/v22 v22.5.0 h1:RrqgGjYQKalulkV8NGVIfkXQf6YYmOyiJKk8iXXhfZs= github.com/coreos/go-systemd/v22 v22.5.0/go.mod h1:Y58oyj3AT4RCenI/lSvhwexgC+NSVTIJ3seZv2GcEnc= github.com/coreos/pkg v0.0.0-20160727233714-3ac0863d7acf/go.mod h1:E3G3o1h8I7cfcXa63jLwjI0eiQQMgzzUDFVpN/nH/eA= -github.com/cpuguy83/go-md2man v1.0.10/go.mod h1:SmD6nW6nTyfqj6ABTjUi3V3JVMnlJmwcJI5acqYI6dE= github.com/cpuguy83/go-md2man/v2 v2.0.0-20190314233015-f79a8a8ca69d/go.mod h1:maD7wRr/U5Z6m/iR4s+kqSMx2CaBsrgA7czyZG/E6dU= github.com/cpuguy83/go-md2man/v2 v2.0.0/go.mod h1:maD7wRr/U5Z6m/iR4s+kqSMx2CaBsrgA7czyZG/E6dU= github.com/cpuguy83/go-md2man/v2 v2.0.2 h1:p1EgwI/C7NhT0JmVkwCD2ZBK8j4aeHQX2pMHHBfMQ6w= @@ -196,10 +206,9 @@ github.com/crate-crypto/go-kzg-4844 v0.7.0 h1:C0vgZRk4q4EZ/JgPfzuSoxdCq3C3mOZMBS github.com/crate-crypto/go-kzg-4844 v0.7.0/go.mod h1:1kMhvPgI0Ky3yIa+9lFySEBUBXkYxeOi8ZF1sYioxhc= github.com/creack/pty v1.1.7/go.mod h1:lj5s0c3V2DBrqTV7llrYr5NG6My20zk30Fl46Y7DoTY= github.com/creack/pty v1.1.9/go.mod h1:oKZEueFk5CKHvIhNR5MUki03XCEU+Q6VDXinZuGJ33E= -github.com/creasty/defaults v1.7.0 h1:eNdqZvc5B509z18lD8yc212CAqJNvfT1Jq6L8WowdBA= -github.com/creasty/defaults v1.7.0/go.mod h1:iGzKe6pbEHnpMPtfDXZEr0NVxWnPTjb1bbDy08fPzYM= github.com/d4l3k/messagediff v1.2.1 h1:ZcAIMYsUg0EAp9X+tt8/enBE/Q8Yd5kzPynLyKptt9U= github.com/d4l3k/messagediff v1.2.1/go.mod h1:Oozbb1TVXFac9FtSIxHBMnBCq2qeH/2KkEQxENCrlLo= +github.com/davecgh/go-spew v0.0.0-20171005155431-ecdeabc65495/go.mod h1:J7Y8YcW2NihsgmVo/mv3lAwl/skON4iLHjSsI+c5H38= 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= @@ -207,11 +216,13 @@ github.com/davidlazar/go-crypto v0.0.0-20200604182044-b73af7476f6c h1:pFUpOrbxDR github.com/davidlazar/go-crypto v0.0.0-20200604182044-b73af7476f6c/go.mod h1:6UhI8N9EjYm1c2odKpFpAYeR8dsBeM7PtzQhRgxRr9U= 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/go.mod h1:sQl2p6Y26YV+ZOcSTP6thNdn47hh8kt6rqSlvmrXFAc= 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.0.1/go.mod h1:hyedUtir6IdtD/7lIxGeCxkaw7y45JueMRL4DIyJDKs= github.com/decred/dcrd/dcrec/secp256k1/v4 v4.2.0 h1:8UrgZ3GkP4i/CLijOJx79Yu+etlyjdBU4sfcs2WYQMs= github.com/decred/dcrd/dcrec/secp256k1/v4 v4.2.0/go.mod h1:v57UDF4pDQJcEfFUCRop3lJL149eHGSe9Jvczhzjo/0= -github.com/dgraph-io/badger v1.6.0/go.mod h1:zwt7syl517jmP8s94KqSxTlM6IMsdhYy6psNgSztDR4= +github.com/decred/dcrd/lru v1.0.0/go.mod h1:mxKOwFd7lFjN2GZYsiz/ecgqR6kkYAl+0pz0tEMk218= github.com/dgraph-io/ristretto v0.0.4-0.20210318174700-74754f61e018 h1:cNcG4c2n5xanQzp2hMyxDxPYVQmZ91y4WN6fJFlndLo= github.com/dgraph-io/ristretto v0.0.4-0.20210318174700-74754f61e018/go.mod h1:MIonLggsKgZLUSt414ExgwNtlOL5MuEoAJP514mwGe8= github.com/dgrijalva/jwt-go v3.2.0+incompatible/go.mod h1:E3ru+11k8xSBh+hMPgOLZmtrrCbhqsmaPHjLKYnJCaQ= @@ -230,7 +241,6 @@ github.com/eapache/go-resiliency v1.2.0/go.mod h1:kFI+JgMyC7bLPUVY133qvEBtVayf5m github.com/eapache/go-xerial-snappy v0.0.0-20180814174437-776d5712da21/go.mod h1:+020luEh2TKB4/GOp8oxxtq0Daoen/Cii55CzbTV6DU= github.com/eapache/queue v1.1.0/go.mod h1:6eCeP0CKFpHLu8blIFXhExK/dRa7WDZfr6jVFPTqq+I= github.com/edsrzf/mmap-go v1.0.0/go.mod h1:YO35OhQPt3KJa3ryjFM5Bs14WD66h8eGKpfaBNrHW5M= -github.com/eknkc/amber v0.0.0-20171010120322-cdade1c07385/go.mod h1:0vRUJqYpeSZifjYj7uP3BG/gKcuzL9xWVV/Y+cK33KM= github.com/elastic/gosigar v0.12.0/go.mod h1:iXRIGg2tLnu7LBdpqzyQfGDEidKCfWcCMS0WKyPWoMs= github.com/elastic/gosigar v0.14.2 h1:Dg80n8cr90OZ7x+bAax/QjoW/XqTI11RmA79ZwIm9/4= github.com/elastic/gosigar v0.14.2/go.mod h1:iXRIGg2tLnu7LBdpqzyQfGDEidKCfWcCMS0WKyPWoMs= @@ -242,15 +252,15 @@ github.com/envoyproxy/go-control-plane v0.9.1-0.20191026205805-5f8ba28d4473/go.m github.com/envoyproxy/go-control-plane v0.9.4/go.mod h1:6rpuAdCZL397s3pYoYcLgu1mIlRU8Am5FuJP05cCM98= github.com/envoyproxy/go-control-plane v0.9.7/go.mod h1:cwu0lG7PUMfa9snN8LXBig5ynNVH9qI8YYLbd1fK2po= github.com/envoyproxy/go-control-plane v0.9.9-0.20201210154907-fd9021fe5dad/go.mod h1:cXg6YxExXjJnVBQHBLXeUAgxn2UodCpnH306RInaBQk= -github.com/envoyproxy/go-control-plane v0.9.9-0.20210217033140-668b12f5399d/go.mod h1:cXg6YxExXjJnVBQHBLXeUAgxn2UodCpnH306RInaBQk= github.com/envoyproxy/protoc-gen-validate v0.1.0/go.mod h1:iSmxcyjqTsJpI2R4NaDN7+kN2VEUnK/pcBlmesArF7c= -github.com/etcd-io/bbolt v1.3.3/go.mod h1:ZF2nL25h33cCyBtcyWeZ2/I3HQOfTP+0PIEvHjkjCrw= +github.com/ethereum-optimism/go-ethereum-hdwallet v0.1.3 h1:RWHKLhCrQThMfch+QJ1Z8veEq5ZO3DfIhZ7xgRP9WTc= +github.com/ethereum-optimism/go-ethereum-hdwallet v0.1.3/go.mod h1:QziizLAiF0KqyLdNJYD7O5cpDlaFMNZzlxYNcWsJUxs= +github.com/ethereum-optimism/optimism v1.7.0 h1:tDzT+46hkJyUTqyB3VuE+zsb+pw4RmQN48NLICHsWpo= +github.com/ethereum-optimism/optimism v1.7.0/go.mod h1:CT8RgUDaJuySsnQ/6XTiBYmwVuIys587cE8zMPwflZ8= 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/evanphx/json-patch v4.9.0+incompatible/go.mod h1:50XU6AFN0ol/bzJsmQLiYLvXMP4fmwYFNcr97nuDLSk= -github.com/fasthttp-contrib/websocket v0.0.0-20160511215533-1f3b11f56072/go.mod h1:duJ4Jxv5lDcvg4QuQr0oowTf7dz4/CR8NtyCooz9HL8= github.com/fatih/color v1.7.0/go.mod h1:Zm6kSWBoL9eyXnKyktHP6abPY2pDugNf5KwzbycvMj4= -github.com/fatih/structs v1.1.0/go.mod h1:9NiDSp5zOcgEDl+j00MP/WkGVPOlPRLejGD8Ga6PJ7M= 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/flynn/go-shlex v0.0.0-20150515145356-3f9db97f8568/go.mod h1:xEzjJPgXI435gkrCt3MPfRiAkVrwSbHsst4LCFVfpJc= @@ -266,23 +276,18 @@ github.com/frankban/quicktest v1.7.2/go.mod h1:jaStnuzAqU1AJdCO0l53JDCJrVDKcS03D github.com/fsnotify/fsnotify v1.4.7/go.mod h1:jwhsz4b93w/PPRr/qN1Yymfu8t87LnFCMoQvtojpjFo= github.com/fsnotify/fsnotify v1.4.9/go.mod h1:znqG4EE+3YCdAaPaxE2ZRY/06pZUdp0tY4IgpuI1SZQ= github.com/fsnotify/fsnotify v1.5.4/go.mod h1:OVB6XrOHzAwXMpEM7uPOzcehqUV2UqJxmVXmkdnm1bU= -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/garyburd/redigo v1.6.0/go.mod h1:NR3MbYisc3/PwhQ00EMzDiPmrwpPxAn5GI05/YaO1SY= -github.com/gavv/httpexpect v2.0.0+incompatible/go.mod h1:x+9tiU1YnrOvnB725RkpoLv1M62hOWzwo5OXotisrKc= github.com/gballet/go-libpcsclite v0.0.0-20191108122812-4678299bea08 h1:f6D9Hr8xV8uYKlyuj8XIruxlh9WjVjdh1gIicAS7ays= github.com/gballet/go-libpcsclite v0.0.0-20191108122812-4678299bea08/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.12.0/go.mod h1:NSap0JBYWzHND8oMbyi0+XZhUalc1TBdRL1M71JZW2c= github.com/getsentry/sentry-go v0.18.0 h1:MtBW5H9QgdcJabtZcuJG80BMOwaBpkRDZkxRkNC1sN0= github.com/getsentry/sentry-go v0.18.0/go.mod h1:Kgon4Mby+FJ7ZWHFUAZgVaIa8sxHtnRJRLTXZr51aKQ= github.com/ghodss/yaml v0.0.0-20150909031657-73d445a93680/go.mod h1:4dBDuWmgqj2HViK6kFavaiC9ZROes6MMH2rRYeMEF04= github.com/ghodss/yaml v1.0.0/go.mod h1:4dBDuWmgqj2HViK6kFavaiC9ZROes6MMH2rRYeMEF04= -github.com/gin-contrib/sse v0.0.0-20190301062529-5545eab6dad3/go.mod h1:VJ0WA2NBN22VlZ2dKZQPAPnyWw5XTlK1KymzLKsr59s= -github.com/gin-gonic/gin v1.4.0/go.mod h1:OW2EZn3DO8Ln9oIKOvM++LBO+5UPHJJDH72/q/3rZdM= github.com/gliderlabs/ssh v0.1.1/go.mod h1:U7qILu1NlMHj9FlMhZLlkCdDnU1DBEAqr0aevW3Awn0= -github.com/go-check/check v0.0.0-20180628173108-788fd7840127/go.mod h1:9ES+weclKsC9YodN5RgxqK/VD9HM9JsCSh7rNhMZE98= github.com/go-errors/errors v1.0.1/go.mod h1:f4zRHt4oKfwPJE5k8C9vpYG+aDHdBFUsgrm6/TyX73Q= github.com/go-errors/errors v1.4.2 h1:J6MZopCL4uSllY1OfXM374weqZFFItUbrImctkmUxIA= github.com/go-errors/errors v1.4.2/go.mod h1:sIVyrIiJhuEF+Pj9Ebtd6P/rEYROXFi3BopGUQ5a5Og= @@ -298,9 +303,8 @@ github.com/go-logfmt/logfmt v0.5.0/go.mod h1:wCYkCAKZfumFQihp8CzCvQ3paCTfi41vtzG github.com/go-logr/logr v0.1.0/go.mod h1:ixOQHD9gLJUVQQ2ZOR7zLEifBX6tGkNJF4QyIY7sIas= github.com/go-logr/logr v0.2.0/go.mod h1:z6/tIYblkpsD+a4lm/fGIIU9mZ+XfAiaFtq7xTgseGU= github.com/go-logr/logr v1.2.0/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-martini/martini v0.0.0-20170121215854-22fa46961aab/go.mod h1:/P9AEU963A2AYjv4d1V5eVL1CQbEJq6aCNHDDjibzu8= +github.com/go-logr/logr v1.3.0 h1:2y3SDp0ZXuc6/cjLSZ+Q3ir+QB9T/iG5yYRXqsagWSY= +github.com/go-logr/logr v1.3.0/go.mod h1:9T104GzyrTigFIr8wt5mBrctHMim0Nb2HLGrmQ40KvY= 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= @@ -331,25 +335,19 @@ github.com/go-stack/stack v1.8.0/go.mod h1:v0f6uXyyMGvRgIKkXu+yp6POWl0qKG85gN/me github.com/go-task/slim-sprig v0.0.0-20210107165309-348f09dbbbc0/go.mod h1:fyg7847qk6SyHyPtNmDHnmrv/HOrqktSC+C9fM+CJOE= github.com/go-task/slim-sprig v0.0.0-20230315185526-52ccab3ef572 h1:tfuBGBXKqDEevZMzYi5KSi8KkcZtzBcTgAUUtapy0OI= github.com/go-task/slim-sprig v0.0.0-20230315185526-52ccab3ef572/go.mod h1:9Pwr4B2jHnOSGXyyzV8ROjYa2ojvAY6HCGYYfMoC3Ls= -github.com/gobwas/httphead v0.0.0-20180130184737-2c6c146eadee/go.mod h1:L0fX3K22YWvt/FAX9NnzrNzcI4wNYi9Yku4O0LKYflo= -github.com/gobwas/pool v0.2.0/go.mod h1:q8bcK0KcYlCgd9e7WYLm9LpyS+YeLd8JVDW6WezmKEw= -github.com/gobwas/ws v1.0.2/go.mod h1:szmBTxLgaFppYjEmNtny/v3w89xOydFnnZMcgRRu/EM= github.com/godbus/dbus/v5 v5.0.3/go.mod h1:xhWf0FNVPg57R7Z0UbKHbJfkEywrmjJnf7w5xrFpKfA= github.com/godbus/dbus/v5 v5.0.4/go.mod h1:xhWf0FNVPg57R7Z0UbKHbJfkEywrmjJnf7w5xrFpKfA= github.com/godbus/dbus/v5 v5.1.0 h1:4KLkAxT3aOY8Li4FRJe/KvhoNFFxo0m6fNuFUO8QJUk= github.com/godbus/dbus/v5 v5.1.0/go.mod h1:xhWf0FNVPg57R7Z0UbKHbJfkEywrmjJnf7w5xrFpKfA= github.com/gofrs/flock v0.8.1 h1:+gYjHKf32LDeiEEFhQaotPbLuUXjY5ZqxKgXy7n59aw= github.com/gofrs/flock v0.8.1/go.mod h1:F1TvTiK9OcQqauNUHlbJvyl9Qa1QvF/gOUDKA14jxHU= -github.com/gogo/googleapis v0.0.0-20180223154316-0cd9801be74a/go.mod h1:gf4bu3Q80BeJ6H1S1vYPm8/ELATdvryBaNFGgqEef3s= github.com/gogo/googleapis v1.1.0/go.mod h1:gf4bu3Q80BeJ6H1S1vYPm8/ELATdvryBaNFGgqEef3s= -github.com/gogo/googleapis v1.4.1/go.mod h1:2lpHqI5OcWCtVElxXnPt+s8oJvMpySlOyM6xDCrzib4= github.com/gogo/protobuf v1.1.1/go.mod h1:r8qH/GZQm5c6nD/R0oafs1akxWv10x8SbQlK7atdtwQ= github.com/gogo/protobuf v1.2.0/go.mod h1:r8qH/GZQm5c6nD/R0oafs1akxWv10x8SbQlK7atdtwQ= github.com/gogo/protobuf v1.2.1/go.mod h1:hp+jE20tsWTFYpLwKvXlhS1hjn+gTNwPg2I6zVXpSg4= github.com/gogo/protobuf v1.3.1/go.mod h1:SlYgWuQ5SjCEi6WLHjHCa1yvBfUnHcTbrrZtXPKa29o= github.com/gogo/protobuf v1.3.2 h1:Ov1cvc58UF3b5XjBnZv7+opcTcQFZebYjWzi34vdm4Q= github.com/gogo/protobuf v1.3.2/go.mod h1:P1XiOD3dCwIKUDQYPy72D8LYyHL2YPYrpS2s69NZV8Q= -github.com/gogo/status v1.1.0/go.mod h1:BFv9nrluPLmrS0EmGVvLaPNmRosr9KapBYd5/hpY1WM= github.com/golang-jwt/jwt v3.2.2+incompatible h1:IfV12K8xAKAnZqdXVzCZ+TOjboZ2keLg81eXfW3O+oY= github.com/golang-jwt/jwt v3.2.2+incompatible/go.mod h1:8pz2t5EyA70fFQQSrl6XZXzqecmYZeUEB8OUGHkxJ+I= github.com/golang-jwt/jwt/v4 v4.5.0 h1:7cYmW1XlMY7h7ii7UhUyChSgS5wUJEnm9uZVTGqOWzg= @@ -397,7 +395,6 @@ github.com/golang/snappy v0.0.1/go.mod h1:/XxbfmMg8lxefKM7IXC3fBNl/7bRcc72aCRzEW github.com/golang/snappy v0.0.4/go.mod h1:/XxbfmMg8lxefKM7IXC3fBNl/7bRcc72aCRzEWrmP2Q= github.com/golang/snappy v0.0.5-0.20220116011046-fa5810519dcb h1:PBC98N2aIaM3XXiurYmW7fx4GZkL8feAMVq7nEjURHk= github.com/golang/snappy v0.0.5-0.20220116011046-fa5810519dcb/go.mod h1:/XxbfmMg8lxefKM7IXC3fBNl/7bRcc72aCRzEWrmP2Q= -github.com/gomodule/redigo v1.7.1-0.20190724094224-574c33c3df38/go.mod h1:B4C85qUVwatsJoIUNIfCRsp7qO0iAmpGFZ4EELWSbC4= github.com/google/btree v0.0.0-20180813153112-4030bb1f1f0c/go.mod h1:lNA+9X1NB3Zf8V7Ke586lFgjr2dZNuvo3lPJSGZ5JPQ= github.com/google/btree v1.0.0/go.mod h1:lNA+9X1NB3Zf8V7Ke586lFgjr2dZNuvo3lPJSGZ5JPQ= github.com/google/go-cmp v0.2.0/go.mod h1:oXzfMopK8JAjlY9xF4vHSVASa0yLyX7SntLO5aqRK0M= @@ -411,14 +408,14 @@ github.com/google/go-cmp v0.5.2/go.mod h1:v8dTdLbMG2kIc/vJvl+f65V22dbkXbowE6jgT/ github.com/google/go-cmp v0.5.3/go.mod h1:v8dTdLbMG2kIc/vJvl+f65V22dbkXbowE6jgT/gNBxE= github.com/google/go-cmp v0.5.4/go.mod h1:v8dTdLbMG2kIc/vJvl+f65V22dbkXbowE6jgT/gNBxE= github.com/google/go-cmp v0.5.5/go.mod h1:v8dTdLbMG2kIc/vJvl+f65V22dbkXbowE6jgT/gNBxE= -github.com/google/go-cmp v0.5.9 h1:O2Tfq5qg4qc4AmwVlvv0oLiVAGB7enBSJ2x2DqQFi38= -github.com/google/go-cmp v0.5.9/go.mod h1:17dUlkBOakJ0+DkrSSNjCkIjxS6bF9zb3elmeNGIjoY= +github.com/google/go-cmp v0.6.0 h1:ofyhxvXcZhMsU5ulbFiLKl/XBFqE1GSq7atu8tAmTRI= +github.com/google/go-cmp v0.6.0/go.mod h1:17dUlkBOakJ0+DkrSSNjCkIjxS6bF9zb3elmeNGIjoY= github.com/google/go-github v17.0.0+incompatible/go.mod h1:zLgOLi98H3fifZn+44m+umXrS52loVEgC2AApnigrVQ= github.com/google/go-querystring v1.0.0/go.mod h1:odCYkC5MyYFN7vkCjXpyrEuKhc/BUO6wN/zVPAxq5ck= github.com/google/gofuzz v1.0.0/go.mod h1:dBl0BpW6vV/+mYPU4Po3pmUjxk6FQPldtuIdl/M65Eg= github.com/google/gofuzz v1.1.0/go.mod h1:dBl0BpW6vV/+mYPU4Po3pmUjxk6FQPldtuIdl/M65Eg= -github.com/google/gofuzz v1.2.0 h1:xRy4A+RhZaiKjJ1bPfwQ8sedCA+YS2YcCHW6ec7JMi0= -github.com/google/gofuzz v1.2.0/go.mod h1:dBl0BpW6vV/+mYPU4Po3pmUjxk6FQPldtuIdl/M65Eg= +github.com/google/gofuzz v1.2.1-0.20220503160820-4a35382e8fc8 h1:Ep/joEub9YwcjRY6ND3+Y/w0ncE540RtGatVhtZL0/Q= +github.com/google/gofuzz v1.2.1-0.20220503160820-4a35382e8fc8/go.mod h1:dBl0BpW6vV/+mYPU4Po3pmUjxk6FQPldtuIdl/M65Eg= github.com/google/gopacket v1.1.19 h1:ves8RnFZPGiFnTS0uPQStjwru6uO6h+nlr9j6fL7kF8= github.com/google/gopacket v1.1.19/go.mod h1:iJ8V8n6KS+z2U1A8pUwu8bW5SyEMkXJB8Yo/Vo+TKTo= github.com/google/martian v2.1.0+incompatible/go.mod h1:9I4somxYTbIHy5NJKHRl3wXiIaQGbYVAs8BPL6v8lEs= @@ -459,7 +456,6 @@ github.com/gorilla/mux v1.7.3/go.mod h1:1lud6UwP+6orDFRuTfBEV8e9/aOM/c4fVVCaMa2z github.com/gorilla/mux v1.8.0 h1:i40aqfkR1h2SlN9hojwV5ZA91wcXFOvkdNIeFDP5koI= github.com/gorilla/mux v1.8.0/go.mod h1:DVbg23sWSpFRCP0SfiEN6jmj59UnW/n46BH5rLB71So= github.com/gorilla/websocket v0.0.0-20170926233335-4201258b820c/go.mod h1:E7qHFY5m1UJ88s3WnNqhKjPHQ0heANvMoAMk2YaljkQ= -github.com/gorilla/websocket v1.4.1/go.mod h1:YR8l580nyteQvAITg2hZ9XVh4b55+EU/adAjf1fMHhE= github.com/gorilla/websocket v1.5.0 h1:PPwGk2jz7EePpoHN/+ClbZu8SPxiqlu12wZP/3sWmnc= github.com/gorilla/websocket v1.5.0/go.mod h1:YR8l580nyteQvAITg2hZ9XVh4b55+EU/adAjf1fMHhE= github.com/gregjones/httpcache v0.0.0-20180305231024-9cad4c3443a7/go.mod h1:FecbI9+v66THATjSRHfNgh1IVFe/9kFxbXtjV0ctIMA= @@ -472,8 +468,8 @@ github.com/grpc-ecosystem/grpc-gateway/v2 v2.0.1/go.mod h1:oVMjMN64nzEcepv1kdZKg github.com/hashicorp/consul/api v1.3.0/go.mod h1:MmDNSzIMUjNpY/mQ398R4bk2FnqQLoPndWW5VkKPlCE= github.com/hashicorp/consul/sdk v0.3.0/go.mod h1:VKf9jXwCTEY1QZP2MOLRhb5i/I/ssyNV1vwHyQBF0x8= github.com/hashicorp/errwrap v1.0.0/go.mod h1:YH+1FKiLXxHSkmPseP+kNlulaMuP3n2brvKWEqk/Jc4= -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/go-bexpr v0.1.11 h1:6DqdA/KBjurGby9yTY0bmkathya0lfwF2SeuubCI7dY= +github.com/hashicorp/go-bexpr v0.1.11/go.mod h1:f03lAo0duBlDIUMGCuad8oLcgejw4m7U+N8T+6Kz1AE= github.com/hashicorp/go-cleanhttp v0.5.1/go.mod h1:JpRdi6/HCYpAwUzNwuwqhbovhLtngrth3wmdIIUrZ80= github.com/hashicorp/go-immutable-radix v1.0.0/go.mod h1:0y9vanUI8NX6FsYoO3zeMjhV/C5i9g4Q3DwcSNZ4P60= github.com/hashicorp/go-msgpack v0.5.3/go.mod h1:ahLV/dePpqEmjfWmKiqvPkv/twdG7iPBM1vqhUKIvfM= @@ -492,7 +488,6 @@ github.com/hashicorp/golang-lru v0.5.5-0.20210104140557-80c98217689d h1:dg1dEPuW github.com/hashicorp/golang-lru v0.5.5-0.20210104140557-80c98217689d/go.mod h1:iADmTwqILo4mZ8BN3D2Q6+9jd8WM5uGBxy+E8yxSoD4= github.com/hashicorp/golang-lru/v2 v2.0.5 h1:wW7h1TG88eUIJ2i69gaE3uNVtEPIagzhGvHgwfx2Vm4= github.com/hashicorp/golang-lru/v2 v2.0.5/go.mod h1:QeFd9opnmA6QUJc5vARoKUSoFhyfM2/ZepoAG6RGpeM= -github.com/hashicorp/hcl v1.0.0/go.mod h1:E5yfLk+7swimpb2L/Alb/PJmXilQ/rhwaUYs4T20WEQ= github.com/hashicorp/logutils v1.0.0/go.mod h1:QIAnNjmIWmVIIkWDTG1z5v++HQmx9WQRO+LraFDTW64= github.com/hashicorp/mdns v1.0.0/go.mod h1:tL+uN++7HEJ6SQLQ2/p+z2pH24WQKWjBPkE0mNTz8vQ= github.com/hashicorp/memberlist v0.1.3/go.mod h1:ajVTdAv/9Im8oMAAj5G31PhhMCZJV2pPBoIllUwCN7I= @@ -509,28 +504,23 @@ github.com/hpcloud/tail v1.0.0/go.mod h1:ab1qPbhIpdTxEkNHXyeSf5vhxWSCs/tWer42PpO github.com/hudl/fargo v1.3.0/go.mod h1:y3CKSmjA+wD2gak7sUSXTAoopbhU08POFhmITJgmKTg= github.com/huin/goupnp v1.3.0 h1:UvLUlWDNpoUdYzb2TCn+MuTWtcjXKSza2n6CBdQ0xXc= github.com/huin/goupnp v1.3.0/go.mod h1:gnGPsThkYa7bFi/KWmEysQRf48l2dvR5bxr2OFckNX8= -github.com/hydrogen18/memlistener v0.0.0-20200120041712-dcc25e7acd91/go.mod h1:qEIFzExnS6016fRpRfxrExeVn2gbClQA99gQhnIcdhE= github.com/ianlancetaylor/demangle v0.0.0-20181102032728-5e5cf60278f6/go.mod h1:aSSvb/t6k1mPoxDqO4vJh6VOCGPwU4O0C2/Eqndh1Sc= github.com/ianlancetaylor/demangle v0.0.0-20200824232613-28f6c0f3b639/go.mod h1:aSSvb/t6k1mPoxDqO4vJh6VOCGPwU4O0C2/Eqndh1Sc= github.com/imdario/mergo v0.3.5/go.mod h1:2EnlNZ0deacrJVfApfmtdGgDfMuh/nq6Ok1EcJh5FfA= -github.com/imkira/go-interpol v1.1.0/go.mod h1:z0h2/2T3XF8kyEPpRgJ3kmNv+C43p+I/CoI+jC3w2iA= github.com/inconshreveable/mousetrap v1.0.0/go.mod h1:PxqpIevigyE2G7u3NXJIT2ANytuPF1OarO4DADm73n8= github.com/influxdata/influxdb1-client v0.0.0-20191209144304-8bf82d3c094d/go.mod h1:qj24IKcXYK6Iy9ceXlo3Tc+vtHo9lIhSX5JddghvEPo= github.com/ipfs/go-cid v0.4.1 h1:A/T3qGvxi4kpKWWcPC/PgbvDA2bjVLO7n4UeVwnbs/s= github.com/ipfs/go-cid v0.4.1/go.mod h1:uQHwDeX4c6CtyrFwdqyhpNcxVewur1M7l7fNU7LKwZk= github.com/ipfs/go-log/v2 v2.5.1 h1:1XdUzF7048prq4aBjDQQ4SL5RxftpRGdXhNRwKSAlcY= github.com/ipfs/go-log/v2 v2.5.1/go.mod h1:prSpmC1Gpllc9UYWxDiZDreBYw7zp4Iqp1kOLU9U5UI= -github.com/iris-contrib/blackfriday v2.0.0+incompatible/go.mod h1:UzZ2bDEoaSGPbkg6SAB4att1aAwTmVIx/5gCVqeyUdI= -github.com/iris-contrib/go.uuid v2.0.0+incompatible/go.mod h1:iz2lgM/1UnEf1kP0L/+fafWORmlnuysV2EMP8MW+qe0= -github.com/iris-contrib/jade v1.1.3/go.mod h1:H/geBymxJhShH5kecoiOCSssPX7QWYH7UaeZTSWddIk= -github.com/iris-contrib/pongo2 v0.0.1/go.mod h1:Ssh+00+3GAZqSQb30AvBRNxBx7rf0GqwkjqxNd0u65g= -github.com/iris-contrib/schema v0.0.1/go.mod h1:urYA3uvUNG1TIIjOSCzHr9/LmbQo8LrOcOqfqxa4hXw= 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/jbenet/go-temp-err-catcher v0.1.0 h1:zpb3ZH6wIE8Shj2sKS+khgRvf7T7RABoLk/+KKHggpk= github.com/jbenet/go-temp-err-catcher v0.1.0/go.mod h1:0kJRvmDZXNMIiJirNPEYfhpPwbGVtZVWC34vc5WLsDk= github.com/jcmturner/gofork v1.0.0/go.mod h1:MK8+TM0La+2rjBD4jE12Kj1pCCxK7d2LK/UM3ncEo0o= github.com/jellevandenhooff/dkim v0.0.0-20150330215556-f50fe3d243e1/go.mod h1:E0B/fFc00Y+Rasa88328GlI/XbtyysCtTHZS8h7IrBU= +github.com/jessevdk/go-flags v0.0.0-20141203071132-1679536dcc89/go.mod h1:4FA24M0QyGHXBuZZK/XkWh8h0e1EYbRYJSGM75WSRxI= +github.com/jessevdk/go-flags v1.4.0/go.mod h1:4FA24M0QyGHXBuZZK/XkWh8h0e1EYbRYJSGM75WSRxI= github.com/jmespath/go-jmespath v0.0.0-20180206201540-c2b33e8439af/go.mod h1:Nht3zPeWKUH0NzdCt2Blrr5ys8VGpn0CEB0cQHVjt7k= github.com/joho/godotenv v1.5.1 h1:7eLL/+HRGLY0ldzfGMeQkb7vMd0as4CfYvUVzLqw0N0= github.com/joho/godotenv v1.5.1/go.mod h1:f4LDr5Voq0i2e/R5DDNOoa2zzDfwtkZa6DnEwAbqwq4= @@ -538,6 +528,7 @@ github.com/jonboulle/clockwork v0.1.0/go.mod h1:Ii8DK3G1RaLaWxj9trq07+26W01tbo22 github.com/josharian/intern v1.0.0 h1:vlS4z54oSdjm0bgjRigI+G1HpF+tI+9rE5LLzOg8HmY= github.com/josharian/intern v1.0.0/go.mod h1:5DoeVV0s6jJacbCEi61lwdGj/aVlrQvzHFFd8Hwg//Y= github.com/jpillora/backoff v1.0.0/go.mod h1:J/6gKK9jxlEcS3zixgDgUAsiuZ7yrSoa/FX5e0EB2j4= +github.com/jrick/logrotate v1.0.0/go.mod h1:LNinyqDIJnpAur+b8yyulnQw/wDuN1+BYKlTRt3OuAQ= github.com/json-iterator/go v1.1.6/go.mod h1:+SdeFBvtyEkXs7REEP0seUULqWtbJapLOCVDaaPEHmU= github.com/json-iterator/go v1.1.7/go.mod h1:KdQUCv79m/52Kvf8AW2vK1V8akMuk1QjK/uOdHXbAo4= github.com/json-iterator/go v1.1.8/go.mod h1:KdQUCv79m/52Kvf8AW2vK1V8akMuk1QjK/uOdHXbAo4= @@ -550,28 +541,20 @@ github.com/jstemmer/go-junit-report v0.9.1/go.mod h1:Brl9GWCQeLvo8nXZwPNNblvFj/X github.com/jtolds/gls v4.20.0+incompatible/go.mod h1:QJZ7F/aHp+rZTRtaJ1ow/lLfFfVYBRgL+9YlvaHOwJU= github.com/julienschmidt/httprouter v1.2.0/go.mod h1:SYymIcj16QtmaHHD7aYtjjsJG7VTCxuUUipMqKk8s4w= github.com/julienschmidt/httprouter v1.3.0/go.mod h1:JR6WtHb+2LUe8TCKY3cZOxFyyO8IZAc4RVcycCCAKdM= -github.com/k0kubun/colorstring v0.0.0-20150214042306-9440f1994b88/go.mod h1:3w7q1U84EfirKl04SVQ/s7nPm1ZPhiXd34z40TNz36k= github.com/k0kubun/go-ansi v0.0.0-20180517002512-3bf9e2903213 h1:qGQQKEcAR99REcMpsXCp3lJ03zYT1PkRd3kQGPn9GVg= github.com/k0kubun/go-ansi v0.0.0-20180517002512-3bf9e2903213/go.mod h1:vNUNkEQ1e29fT/6vq2aBdFsgNPmy8qMdSay1npru+Sw= -github.com/kataras/golog v0.0.10/go.mod h1:yJ8YKCmyL+nWjERB90Qwn+bdyBZsaQwU3bTVFgkFIp8= -github.com/kataras/iris/v12 v12.1.8/go.mod h1:LMYy4VlP67TQ3Zgriz8RE2h2kMZV2SgMYbq3UhfoFmE= -github.com/kataras/neffos v0.0.14/go.mod h1:8lqADm8PnbeFfL7CLXh1WHw53dG27MC3pgi2R1rmoTE= -github.com/kataras/pio v0.0.2/go.mod h1:hAoW0t9UmXi4R5Oyq5Z4irTbaTsOemSrDGUtaTl7Dro= -github.com/kataras/sitemap v0.0.5/go.mod h1:KY2eugMKiPwsJgx7+U103YZehfvNGOXURubcGyk0Bz8= github.com/kisielk/errcheck v1.1.0/go.mod h1:EZBBE59ingxPouuu3KfxchcWSUPOHkagtvWXihfKN4Q= github.com/kisielk/errcheck v1.2.0/go.mod h1:/BMXB+zMLi60iA8Vv6Ksmxu/1UDYcXs4uQLJ+jE2L00= github.com/kisielk/errcheck v1.5.0/go.mod h1:pFxgyoBC7bSaBwPgfKdkLd5X25qrDl4LWUI2bnpBCr8= github.com/kisielk/gotool v1.0.0/go.mod h1:XhKaO+MFFWcvkIS/tQcRk01m1F5IRFswLeQ+oQHNcck= -github.com/klauspost/compress v1.8.2/go.mod h1:RyIbtBH6LamlWaDj8nUwkbUhJ87Yi3uG0guNDohfE1A= -github.com/klauspost/compress v1.9.7/go.mod h1:RyIbtBH6LamlWaDj8nUwkbUhJ87Yi3uG0guNDohfE1A= +github.com/kkdai/bstream v0.0.0-20161212061736-f391b8402d23/go.mod h1:J+Gs4SYgM6CZQHDETBtE9HaSEkGmuNXF86RwHhHUvq4= github.com/klauspost/compress v1.9.8/go.mod h1:RyIbtBH6LamlWaDj8nUwkbUhJ87Yi3uG0guNDohfE1A= github.com/klauspost/compress v1.10.1/go.mod h1:aoV0uJVorq1K+umq18yTdKaF57EivdYsUV+/s2qKfXs= github.com/klauspost/compress v1.17.2 h1:RlWWUY/Dr4fL8qk9YG7DTZ7PDgME2V4csBXA8L/ixi4= github.com/klauspost/compress v1.17.2/go.mod h1:ntbaceVETuRiXiv4DpjP66DpAtAGkEQskQzEyD//IeE= -github.com/klauspost/cpuid v1.2.1/go.mod h1:Pj4uuM528wm8OyEC2QMXAi2YiTZ96dNQPGgoMS4s3ek= github.com/klauspost/cpuid v1.2.3/go.mod h1:Pj4uuM528wm8OyEC2QMXAi2YiTZ96dNQPGgoMS4s3ek= -github.com/klauspost/cpuid/v2 v2.2.5 h1:0E5MSMDEoAulmXNFquVs//DdoomxaoTY1kUhbc/qbZg= -github.com/klauspost/cpuid/v2 v2.2.5/go.mod h1:Lcz8mBdAVJIBVzewtcLocK12l3Y+JytZYpaMropDUws= +github.com/klauspost/cpuid/v2 v2.2.6 h1:ndNyv040zDGIDh8thGkXYjnFtiN02M1PVVF+JE/48xc= +github.com/klauspost/cpuid/v2 v2.2.6/go.mod h1:Lcz8mBdAVJIBVzewtcLocK12l3Y+JytZYpaMropDUws= github.com/klauspost/reedsolomon v1.9.3/go.mod h1:CwCi+NUr9pqSVktrkN+Ondf06rkhYZ/pcNv7fu+8Un4= github.com/konsorten/go-windows-terminal-sequences v1.0.1/go.mod h1:T0+1ngSBFLxvqU3pZ+m/2kptfBszLMUkC4ZK/EgS/cQ= github.com/konsorten/go-windows-terminal-sequences v1.0.2/go.mod h1:T0+1ngSBFLxvqU3pZ+m/2kptfBszLMUkC4ZK/EgS/cQ= @@ -583,7 +566,6 @@ github.com/kr/logfmt v0.0.0-20140226030751-b84e30acd515/go.mod h1:+0opPa2QZZtGFB github.com/kr/pretty v0.1.0/go.mod h1:dAy3ld7l9f0ibDNOQOHHMYYIIbhfbHSm3C4ZsoJORNo= github.com/kr/pretty v0.2.0/go.mod h1:ipq/a2n7PKx3OHsz4KJII5eveXtPO4qwEXGdVfWzfnI= github.com/kr/pretty v0.2.1/go.mod h1:ipq/a2n7PKx3OHsz4KJII5eveXtPO4qwEXGdVfWzfnI= -github.com/kr/pretty v0.3.0/go.mod h1:640gp4NfQd8pI5XOwp5fnNeVWj67G7CFk/SaSQn7NBk= github.com/kr/pretty v0.3.1 h1:flRD4NNwYAUpkphVc1HcthR4KEIFJ65n8Mw5qdRn3LE= github.com/kr/pretty v0.3.1/go.mod h1:hoEshYVHaxMs3cyo3Yncou5ZscifuDolrwPKZanG3xk= github.com/kr/pty v1.1.1/go.mod h1:pFQYn66WHrOpPYNljwOMqo10TkYh1fy3cYio2l3bCsQ= @@ -594,10 +576,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/labstack/echo/v4 v4.5.0/go.mod h1:czIriw4a0C1dFun+ObrXp7ok03xON0N1awStJ6ArI7Y= github.com/labstack/echo/v4 v4.11.1 h1:dEpLU2FLg4UVmvCGPuk/APjlH6GDpbEPti61srUUUs4= github.com/labstack/echo/v4 v4.11.1/go.mod h1:YuYRTSM3CHs2ybfrL8Px48bO6BAnYIN4l8wSTMP6BDQ= -github.com/labstack/gommon v0.3.0/go.mod h1:MULnywXg0yavhxWKc+lOruYdAhDwPK9wf0OL7NoOu+k= github.com/labstack/gommon v0.4.0 h1:y7cvthEAEbU0yHOf4axH8ZG2NH8knB9iNSoTO8dyIk8= github.com/labstack/gommon v0.4.0/go.mod h1:uW6kP17uPlLJsD3ijUYn3/M5bAxtlZhMI6m3MFxTMTM= github.com/leanovate/gopter v0.2.9 h1:fQjYxZaynp97ozCzfOyOuAGOU4aU/z37zf/tOujFk7c= @@ -634,7 +614,6 @@ github.com/logrusorgru/aurora v2.0.3+incompatible h1:tOpm7WcpBTn4fjmVfgpQq0EfczG github.com/logrusorgru/aurora v2.0.3+incompatible/go.mod h1:7rIyQOR62GCctdiQpZ/zOJlFyk6y+94wXzv6RNZgaR4= github.com/lunixbochs/vtclean v1.0.0/go.mod h1:pHhQNgMf3btfWnGBVipUOjRYhoOsdGqdm/+2c2E2WMI= github.com/lyft/protoc-gen-validate v0.0.13/go.mod h1:XbGvPuh87YZc5TdIa2/I4pLk0QoUACkjt2znoq26NVQ= -github.com/magiconair/properties v1.8.0/go.mod h1:PppfXfuXeibc/6YijjN8zIbojt8czPbwD3XqdrwzmxQ= github.com/mailru/easyjson v0.0.0-20190312143242-1de009706dbe/go.mod h1:C1wdFJiN94OJF2b5HbByQZoLdCWB1Yqtg26g4irojpc= github.com/mailru/easyjson v0.0.0-20190614124828-94de47d64c63/go.mod h1:C1wdFJiN94OJF2b5HbByQZoLdCWB1Yqtg26g4irojpc= github.com/mailru/easyjson v0.0.0-20190626092158-b2ccc519800e/go.mod h1:C1wdFJiN94OJF2b5HbByQZoLdCWB1Yqtg26g4irojpc= @@ -644,16 +623,11 @@ github.com/mailru/easyjson v0.7.7/go.mod h1:xzfreul335JAWq5oZzymOObrkdz5UnU4kGfJ github.com/marten-seemann/tcp v0.0.0-20210406111302-dfbc87cc63fd h1:br0buuQ854V8u83wA0rVZ8ttrq5CpaPZdvrK0LP2lOk= github.com/marten-seemann/tcp v0.0.0-20210406111302-dfbc87cc63fd/go.mod h1:QuCEs1Nt24+FYQEqAAncTDPJIuGs+LxK1MCiFL25pMU= github.com/mattn/go-colorable v0.0.9/go.mod h1:9vuHe8Xs5qXnSaW/c/ABM9alt+Vo+STaOChaDxuIBZU= -github.com/mattn/go-colorable v0.1.2/go.mod h1:U0ppj6V5qS13XJ6of8GYAs25YV2eR4EVcfRqFIhoBtE= -github.com/mattn/go-colorable v0.1.8/go.mod h1:u6P/XSegPjTcexA+o6vUJrdnUu04hMope9wVRipJSqc= github.com/mattn/go-colorable v0.1.11/go.mod h1:u5H1YNBxpqRaxsYJYSkiCWKzEfiAb1Gb520KVy5xxl4= github.com/mattn/go-colorable v0.1.13 h1:fFA4WZxdEF4tXPZVKMLwD8oUnCTTo08duU7wxecdEvA= github.com/mattn/go-colorable v0.1.13/go.mod h1:7S9/ev0klgBDR4GtXTXX8a3vIGJpMovkB8vQcUbaXHg= github.com/mattn/go-isatty v0.0.3/go.mod h1:M+lRXTBqGeGNdLjl/ufCoiOlB5xdOkqRJdNxMWT7Zi4= github.com/mattn/go-isatty v0.0.4/go.mod h1:M+lRXTBqGeGNdLjl/ufCoiOlB5xdOkqRJdNxMWT7Zi4= -github.com/mattn/go-isatty v0.0.7/go.mod h1:Iq45c/XA43vh69/j3iqttzPXn0bhXyGjM0Hdxcsrc5s= -github.com/mattn/go-isatty v0.0.8/go.mod h1:Iq45c/XA43vh69/j3iqttzPXn0bhXyGjM0Hdxcsrc5s= -github.com/mattn/go-isatty v0.0.9/go.mod h1:YNRxwqDuOph6SZLI9vUUz6OYw3QyUt7WiY2yME+cCiQ= github.com/mattn/go-isatty v0.0.12/go.mod h1:cbi8OIDigv2wuxKPP5vlRcQ1OAZbq2CE4Kysco4FUpU= github.com/mattn/go-isatty v0.0.14/go.mod h1:7GGIvUiUoEMVVmxf/4nioHXj79iQHKdU27kJ6hsGG94= github.com/mattn/go-isatty v0.0.16/go.mod h1:kYGgaQfpe5nmfYZH+SKPsOc2e4SrIfOl2e/yFXSvRLM= @@ -663,13 +637,12 @@ github.com/mattn/go-runewidth v0.0.2/go.mod h1:LwmH8dsx7+W8Uxz3IHJYH5QSwggIsqBzp github.com/mattn/go-runewidth v0.0.9/go.mod h1:H031xJmbD/WCDINGzjvQ9THkh0rPKHF+m2gUSrubnMI= github.com/mattn/go-runewidth v0.0.14 h1:+xnbZSEeDbOIg5/mE6JF0w6n9duR1l3/WmbinWVwUuU= github.com/mattn/go-runewidth v0.0.14/go.mod h1:Jdepj2loyihRzMpdS35Xk/zdY8IAYHsh153qUoGf23w= -github.com/mattn/goveralls v0.0.2/go.mod h1:8d1ZMHsd7fW6IRPKQh46F2WRpyib5/X4FOpevwGNQEw= github.com/matttproud/golang_protobuf_extensions v1.0.1/go.mod h1:D8He9yQNgCq6Z5Ld7szi9bcBfOoFv/3dc6xSMkL2PC0= github.com/matttproud/golang_protobuf_extensions v1.0.4 h1:mmDVorXM7PCGKw94cs5zkfA9PSy5pEvNWRP0ET0TIVo= github.com/matttproud/golang_protobuf_extensions v1.0.4/go.mod h1:BSXmuO+STAnVfrANrmjBb36TMTDstsz7MSK+HVaYKv4= -github.com/mediocregopher/radix/v3 v3.4.2/go.mod h1:8FL3F6UQRXHXIBSPUs5h0RybMF8i4n7wVopoX3x7Bv8= +github.com/matttproud/golang_protobuf_extensions/v2 v2.0.0 h1:jWpvCLoY8Z/e3VKvlsiIGKtc+UG6U5vzxaoagmhXfyg= +github.com/matttproud/golang_protobuf_extensions/v2 v2.0.0/go.mod h1:QUyp042oQthUoa9bqDv0ER0wrtXnBruoNd7aNjkbP+k= github.com/microcosm-cc/bluemonday v1.0.1/go.mod h1:hsXNsILzKxV+sX77C5b8FSuKF00vh2OMYv+xgHpAMF4= -github.com/microcosm-cc/bluemonday v1.0.2/go.mod h1:iVP4YcDBq+n/5fb23BhYFvIMq/leAFZyRl6bYmGDlGc= github.com/miekg/dns v1.0.14/go.mod h1:W1PPwlIAgtquWBMBEV9nkV9Cazfe8ScdGz/Lj7v3Nrg= github.com/miekg/dns v1.1.41/go.mod h1:p6aan82bvRIyn+zDIv9xYNUpwa73JcSh9BKwknJysuI= github.com/miekg/dns v1.1.56 h1:5imZaSeoRNvpM9SzWNhEcP9QliKiz20/dA2QabIGVnE= @@ -690,16 +663,16 @@ github.com/mitchellh/cli v1.0.0/go.mod h1:hNIlj7HEI86fIcpObd7a0FcrxTWetlwJDGcceT github.com/mitchellh/colorstring v0.0.0-20190213212951-d06e56a500db h1:62I3jR2EmQ4l5rM/4FEfDWcRD+abF5XlKShorW5LRoQ= github.com/mitchellh/colorstring v0.0.0-20190213212951-d06e56a500db/go.mod h1:l0dey0ia/Uv7NcFFVbCLtqEBQbrT4OCwCSKTEv6enCw= github.com/mitchellh/go-homedir v1.0.0/go.mod h1:SfyaCUpYCn1Vlf4IUYiD9fPX4A5wJrkLzIz1N1q0pr0= -github.com/mitchellh/go-homedir v1.1.0/go.mod h1:SfyaCUpYCn1Vlf4IUYiD9fPX4A5wJrkLzIz1N1q0pr0= github.com/mitchellh/go-testing-interface v1.0.0/go.mod h1:kRemZodwjscx+RGhAo8eIhFbs2+BFgRtFPeD/KE+zxI= github.com/mitchellh/gox v0.4.0/go.mod h1:Sd9lOJ0+aimLBi73mGofS1ycjY8lL3uZM3JPS42BGNg= github.com/mitchellh/iochan v1.0.0/go.mod h1:JwYml1nuB7xOzsp52dPpHFffvOCDupsG0QubkSMEySY= github.com/mitchellh/mapstructure v0.0.0-20160808181253-ca63d7c062ee/go.mod h1:FVVH3fgwuzCH5S8UJGiWEs2h04kUh9fWfEaFds41c1Y= github.com/mitchellh/mapstructure v1.1.2/go.mod h1:FVVH3fgwuzCH5S8UJGiWEs2h04kUh9fWfEaFds41c1Y= -github.com/mitchellh/mapstructure v1.4.1 h1:CpVNEelQCZBooIPDn+AR3NpivK/TIKU8bDxdASFVQag= github.com/mitchellh/mapstructure v1.4.1/go.mod h1:bFUtVrKA4DC2yAKiSyO/QUcy7e+RRV2QTWOzhPopBRo= -github.com/mitchellh/pointerstructure v1.2.0 h1:O+i9nHnXS3l/9Wu7r4NrEdwA2VFTicjUEN1uBnDo34A= -github.com/mitchellh/pointerstructure v1.2.0/go.mod h1:BRAsLI5zgXmw97Lf6s25bs8ohIXc3tViBH44KcwB2g4= +github.com/mitchellh/mapstructure v1.5.0 h1:jeMsZIYE/09sWLaz43PL7Gy6RuMjD2eJVyuac5Z2hdY= +github.com/mitchellh/mapstructure v1.5.0/go.mod h1:bFUtVrKA4DC2yAKiSyO/QUcy7e+RRV2QTWOzhPopBRo= +github.com/mitchellh/pointerstructure v1.2.1 h1:ZhBBeX8tSlRpu/FFhXH4RC4OJzFlqsQhoHZAz4x7TIw= +github.com/mitchellh/pointerstructure v1.2.1/go.mod h1:BRAsLI5zgXmw97Lf6s25bs8ohIXc3tViBH44KcwB2g4= github.com/mmcloughlin/addchain v0.4.0 h1:SobOdjm2xLj1KkXN5/n0xTIWyZA2+s99UCY1iPfkHRY= github.com/mmcloughlin/addchain v0.4.0/go.mod h1:A86O+tHqZLMNO4w6ZZ4FlVQEadcoqkyU72HC5wJ4RlU= github.com/mmcloughlin/profile v0.1.1/go.mod h1:IhHD7q1ooxgwTgjxQYkACGA77oFTDdFVejUS1/tS/qU= @@ -712,7 +685,6 @@ github.com/modern-go/reflect2 v1.0.2 h1:xBagoLtFs94CBntxluKeaWgTMpvLxC4ur3nMaC9G github.com/modern-go/reflect2 v1.0.2/go.mod h1:yWuevngMOJpCy52FWWMvUC8ws7m/LJsjYzDa0/r8luk= github.com/mohae/deepcopy v0.0.0-20170929034955-c48cc78d4826 h1:RWengNIwukTxcDr9M+97sNutRR1RKhG96O6jWumTTnw= github.com/mohae/deepcopy v0.0.0-20170929034955-c48cc78d4826/go.mod h1:TaXosZuwdSHYgviHp1DAtfrULt5eUgsSMsZf+YrPgl8= -github.com/moul/http2curl v1.0.0/go.mod h1:8UbvGypXm98wA/IqH45anm5Y2Z6ep6O31QGOAZ3H0fQ= github.com/mr-tron/base58 v1.1.2/go.mod h1:BinMc/sQntlIE1frQmRFPUoPA1Zkr8VRgBdjWI2mNwc= github.com/mr-tron/base58 v1.2.0 h1:T/HDJBh4ZCPbU39/+c3rRvE0uKBQlU27+QI8LJ4t64o= github.com/mr-tron/base58 v1.2.0/go.mod h1:BinMc/sQntlIE1frQmRFPUoPA1Zkr8VRgBdjWI2mNwc= @@ -722,8 +694,8 @@ github.com/multiformats/go-base36 v0.2.0 h1:lFsAbNOGeKtuKozrtBsAkSVhv1p9D0/qedU9 github.com/multiformats/go-base36 v0.2.0/go.mod h1:qvnKE++v+2MWCfePClUEjE78Z7P2a1UV0xHgWc0hkp4= github.com/multiformats/go-multiaddr v0.1.1/go.mod h1:aMKBKNEYmzmDmxfX88/vz+J5IU55txyt0p4aiWVohjo= github.com/multiformats/go-multiaddr v0.2.0/go.mod h1:0nO36NvPpyV4QzvTLi/lafl2y95ncPj0vFwVF6k6wJ4= -github.com/multiformats/go-multiaddr v0.12.1 h1:vm+BA/WZA8QZDp1pF1FWhi5CT3g1tbi5GJmqpb6wnlk= -github.com/multiformats/go-multiaddr v0.12.1/go.mod h1:7mPkiBMmLeFipt+nNSq9pHZUeJSt8lHBgH6yhj0YQzE= +github.com/multiformats/go-multiaddr v0.12.2 h1:9G9sTY/wCYajKa9lyfWPmpZAwe6oV+Wb1zcmMS1HG24= +github.com/multiformats/go-multiaddr v0.12.2/go.mod h1:GKyaTYjZRdcUhyOetrxTk9z0cW+jA/YrnqTOvKgi44M= github.com/multiformats/go-multiaddr-dns v0.3.1 h1:QgQgR+LQVt3NPTjbrLLpsaT2ufAA2y0Mkk+QRVJbW3A= github.com/multiformats/go-multiaddr-dns v0.3.1/go.mod h1:G/245BRQ6FJGmryJCrOuTdB37AMA5AMOVuO6NY3JwTk= github.com/multiformats/go-multiaddr-fmt v0.1.0 h1:WLEFClPycPkp4fnIzoFoV9FVd49/eQsuaL3/CWe167E= @@ -766,24 +738,25 @@ github.com/onsi/ginkgo v0.0.0-20170829012221-11459a886d9c/go.mod h1:lLunBs/Ym6LB github.com/onsi/ginkgo v1.6.0/go.mod h1:lLunBs/Ym6LB5Z9jYTR76FiuTmxDTDusOGeTQH+WWjE= github.com/onsi/ginkgo v1.7.0/go.mod h1:lLunBs/Ym6LB5Z9jYTR76FiuTmxDTDusOGeTQH+WWjE= github.com/onsi/ginkgo v1.10.1/go.mod h1:lLunBs/Ym6LB5Z9jYTR76FiuTmxDTDusOGeTQH+WWjE= -github.com/onsi/ginkgo v1.10.3/go.mod h1:lLunBs/Ym6LB5Z9jYTR76FiuTmxDTDusOGeTQH+WWjE= github.com/onsi/ginkgo v1.11.0/go.mod h1:lLunBs/Ym6LB5Z9jYTR76FiuTmxDTDusOGeTQH+WWjE= github.com/onsi/ginkgo v1.12.1/go.mod h1:zj2OWP4+oCPe1qIXoGWkgMRwljMUYCdkwsT2108oapk= +github.com/onsi/ginkgo v1.14.0/go.mod h1:iSB4RoI2tjJc9BBv4NKIKWKya62Rps+oPG/Lv9klQyY= github.com/onsi/ginkgo v1.16.4/go.mod h1:dX+/inL/fNMqNlz0e9LfyB9TswhZpCVdJM/Z6Vvnwo0= github.com/onsi/ginkgo v1.16.5 h1:8xi0RTUf59SOSfEtZMvwTvXYMzG4gV23XVHOZiXNtnE= github.com/onsi/ginkgo v1.16.5/go.mod h1:+E8gABHa3K6zRBolWtd+ROzc/U5bkGt0FwiG042wbpU= github.com/onsi/ginkgo/v2 v2.1.3/go.mod h1:vw5CSIxN1JObi/U8gcbwft7ZxR2dgaR70JSE3/PpL4c= -github.com/onsi/ginkgo/v2 v2.13.0 h1:0jY9lJquiL8fcf3M4LAXN5aMlS/b2BV86HFFPCPMgE4= -github.com/onsi/ginkgo/v2 v2.13.0/go.mod h1:TE309ZR8s5FsKKpuB1YAQYBzCaAfUgatB/xlT/ETL/o= +github.com/onsi/ginkgo/v2 v2.15.0 h1:79HwNRBAZHOEwrczrgSOPy+eFTTlIGELKy5as+ClttY= +github.com/onsi/ginkgo/v2 v2.15.0/go.mod h1:HlxMHtYF57y6Dpf+mc5529KKmSq9h2FpCF+/ZkwUxKM= github.com/onsi/gomega v0.0.0-20170829124025-dcabb60a477c/go.mod h1:C1qb7wdrVGGVU+Z6iS04AVkA3Q65CEZX59MT0QO5uiA= +github.com/onsi/gomega v1.4.1/go.mod h1:C1qb7wdrVGGVU+Z6iS04AVkA3Q65CEZX59MT0QO5uiA= github.com/onsi/gomega v1.4.3/go.mod h1:ex+gbHU/CVuBBDIJjb2X0qEXbFg53c61hWP/1CpauHY= github.com/onsi/gomega v1.7.0/go.mod h1:ex+gbHU/CVuBBDIJjb2X0qEXbFg53c61hWP/1CpauHY= github.com/onsi/gomega v1.7.1/go.mod h1:XdKZgCCFLUoM/7CFJVPcG8C1xQ1AJ0vpAezJrB7JYyY= github.com/onsi/gomega v1.10.1/go.mod h1:iN09h71vgCQne3DLsj+A5owkum+a2tYe+TOCB1ybHNo= github.com/onsi/gomega v1.17.0/go.mod h1:HnhC7FXeEQY45zxNK3PPoIUhzk/80Xly9PcubAlGdZY= github.com/onsi/gomega v1.19.0/go.mod h1:LY+I3pBVzYsTBU1AnDwOSxaYi9WoWiqgwooUqq9yPro= -github.com/onsi/gomega v1.27.10 h1:naR28SdDFlqrG6kScpT8VWpu1xWY5nJRCF3XaYyBjhI= -github.com/onsi/gomega v1.27.10/go.mod h1:RsS8tutOdbdgzbPtzzATp12yT7kM5I5aElG3evPbQ0M= +github.com/onsi/gomega v1.31.1 h1:KYppCUK+bUgAZwHOu7EXVBKyQA6ILvOESHkn/tgoqvo= +github.com/onsi/gomega v1.31.1/go.mod h1:y40C95dwAD1Nz36SsEnxvfFe8FFfNxzI5eJ0EYGyAy0= github.com/op/go-logging v0.0.0-20160315200505-970db520ece7/go.mod h1:HzydrMdWErDVzsI23lYNej1Htcns9BCg93Dk0bBINWk= github.com/openconfig/gnmi v0.0.0-20190823184014-89b2bf29312c/go.mod h1:t+O9It+LKzfOAhKTT5O0ehDix+MTqbtT0T9t+7zzOvc= github.com/openconfig/reference v0.0.0-20190727015836-8dfd928c9696/go.mod h1:ym2A+zigScwkSEb/cVQB0/ZMpU3rqiH6X7WRRsxgOGw= @@ -799,8 +772,6 @@ github.com/openzipkin/zipkin-go v0.1.1/go.mod h1:NtoC/o8u3JlF1lSlyPNswIbeQH9bJTm github.com/openzipkin/zipkin-go v0.1.6/go.mod h1:QgAqvLzwWbR/WpD4A3cGpPtJrZXNIiJc5AZX7/PBEpw= github.com/openzipkin/zipkin-go v0.2.1/go.mod h1:NaW6tEwdmWMaCDZzg8sh+IBNOxHMPnhQw8ySjnjRyN4= github.com/openzipkin/zipkin-go v0.2.2/go.mod h1:NaW6tEwdmWMaCDZzg8sh+IBNOxHMPnhQw8ySjnjRyN4= -github.com/orcaman/concurrent-map/v2 v2.0.1 h1:jOJ5Pg2w1oeB6PeDurIYf6k9PQ+aTITr/6lP/L/zp6c= -github.com/orcaman/concurrent-map/v2 v2.0.1/go.mod h1:9Eq3TG2oBe5FirmYWQfYO5iH1q0Jv47PLaNK++uCdOM= github.com/pact-foundation/pact-go v1.0.4/go.mod h1:uExwJY4kCzNPcHRj+hCR/HBbOOIwwtUjcrb0b5/5kLM= github.com/pascaldekloe/goe v0.0.0-20180627143212-57f6aae5913c/go.mod h1:lzWF7FIEvWOWxwDKqyGYQf6ZUaNfKdP144TG7ZOy1lc= github.com/patrickmn/go-cache v2.1.0+incompatible h1:HRMgzkcYKYpi3C8ajMPV8OFXaaRUnok+kx1WdO15EQc= @@ -808,9 +779,6 @@ github.com/patrickmn/go-cache v2.1.0+incompatible/go.mod h1:3Qf8kWWT7OJRJbdiICTK github.com/pbnjay/memory v0.0.0-20210728143218-7b4eea64cf58 h1:onHthvaw9LFnH4t2DcNVpwGmV9E1BkGknEliJkfwQj0= github.com/pbnjay/memory v0.0.0-20210728143218-7b4eea64cf58/go.mod h1:DXv8WO4yhMYhSNPKjeNKa5WY9YCIEBRbNzFFPJbWO6Y= github.com/pborman/uuid v1.2.0/go.mod h1:X/NO0urCmaxf9VXbdlT7C2Yzkj2IKimNn4k+gtPdI/k= -github.com/pborman/uuid v1.2.1 h1:+ZZIw58t/ozdjRaXh/3awHfmWRbzYxJoAdNJxe/3pvw= -github.com/pborman/uuid v1.2.1/go.mod h1:X/NO0urCmaxf9VXbdlT7C2Yzkj2IKimNn4k+gtPdI/k= -github.com/pelletier/go-toml v1.2.0/go.mod h1:5z9KED0ma1S8pY6P1sdut58dfprrGBbd/94hg7ilaic= github.com/performancecopilot/speed v3.0.0+incompatible/go.mod h1:/CLtqpZ5gBg1M9iaPbIdPPGyKcA8hKdoy6hAWba7Yac= github.com/peterbourgon/diskv v2.0.1+incompatible/go.mod h1:uqqh8zWWbv1HBMNONnaR/tNboyR3/BZd58JJSHlUSCU= github.com/phayes/freeport v0.0.0-20220201140144-74d24b5ae9f5 h1:Ii+DKncOVM8Cu1Hc+ETb5K+23HdAMvESYE3ZJ5b5cMI= @@ -838,16 +806,16 @@ github.com/prometheus/client_golang v1.3.0/go.mod h1:hJaj2vgQTGQmVCsAACORcieXFeD github.com/prometheus/client_golang v1.4.1/go.mod h1:e9GMxYsXl05ICDXkRhurwBS4Q3OK1iX/F2sw+iXX5zU= github.com/prometheus/client_golang v1.7.1/go.mod h1:PY5Wy2awLA44sXw4AOSfFBetzPP4j5+D6mVACh+pe2M= github.com/prometheus/client_golang v1.9.0/go.mod h1:FqZLKOZnGdFAhOK4nqGHa7D66IdsO+O441Eve7ptJDU= -github.com/prometheus/client_golang v1.14.0 h1:nJdhIvne2eSX/XRAFV9PcvFFRbrjbcTUj0VP62TMhnw= -github.com/prometheus/client_golang v1.14.0/go.mod h1:8vpkKitgIVNcqrRBWh1C4TIUQgYNtG/XQE4E/Zae36Y= +github.com/prometheus/client_golang v1.18.0 h1:HzFfmkOzH5Q8L8G+kSJKUx5dtG87sewO+FoDDqP5Tbk= +github.com/prometheus/client_golang v1.18.0/go.mod h1:T+GXkCk5wSJyOqMIzVgvvjFDlkOQntgjkJWKrN5txjA= github.com/prometheus/client_model v0.0.0-20180712105110-5c3871d89910/go.mod h1:MbSGuTsp3dbXC40dX6PRTWyKYBIrTGTE9sqQNg2J8bo= github.com/prometheus/client_model v0.0.0-20190115171406-56726106282f/go.mod h1:MbSGuTsp3dbXC40dX6PRTWyKYBIrTGTE9sqQNg2J8bo= github.com/prometheus/client_model v0.0.0-20190129233127-fd36f4220a90/go.mod h1:xMI15A0UPsDsEKsMN9yxemIoYk6Tm2C1GtYGdfGttqA= github.com/prometheus/client_model v0.0.0-20190812154241-14fe0d1b01d4/go.mod h1:xMI15A0UPsDsEKsMN9yxemIoYk6Tm2C1GtYGdfGttqA= github.com/prometheus/client_model v0.1.0/go.mod h1:xMI15A0UPsDsEKsMN9yxemIoYk6Tm2C1GtYGdfGttqA= github.com/prometheus/client_model v0.2.0/go.mod h1:xMI15A0UPsDsEKsMN9yxemIoYk6Tm2C1GtYGdfGttqA= -github.com/prometheus/client_model v0.4.0 h1:5lQXD3cAg1OXBf4Wq03gTrXHeaV0TQvGfUooCfx1yqY= -github.com/prometheus/client_model v0.4.0/go.mod h1:oMQmHW1/JoDwqLtg57MGgP/Fb1CJEYF2imWWhWtMkYU= +github.com/prometheus/client_model v0.5.0 h1:VQw1hfvPvk3Uv6Qf29VrPF32JB6rtbgI6cYPYQjL0Qw= +github.com/prometheus/client_model v0.5.0/go.mod h1:dTiFglRmd66nLR9Pv9f0mZi7B7fk5Pm3gvsjB5tr+kI= github.com/prometheus/common v0.0.0-20180801064454-c7de2306084e/go.mod h1:daVV7qP5qjZbuso7PdcryaAu0sAZbrN9i7WWcTMWvro= github.com/prometheus/common v0.2.0/go.mod h1:TNfzLD0ON7rHzMJeJkieUDPYmFC7Snx/y86RQel1bk4= github.com/prometheus/common v0.4.1/go.mod h1:TNfzLD0ON7rHzMJeJkieUDPYmFC7Snx/y86RQel1bk4= @@ -855,8 +823,8 @@ github.com/prometheus/common v0.7.0/go.mod h1:DjGbpBbp5NYNiECxcL/VnbXCCaQpKd3tt2 github.com/prometheus/common v0.9.1/go.mod h1:yhUN8i9wzaXS3w1O07YhxHEBxD+W35wd8bs7vj7HSQ4= github.com/prometheus/common v0.10.0/go.mod h1:Tlit/dnDKsSWFlCLTWaA1cyBgKHSMdTB80sz/V91rCo= github.com/prometheus/common v0.15.0/go.mod h1:U+gB1OBLb1lF3O42bTCL+FK18tX9Oar16Clt/msog/s= -github.com/prometheus/common v0.42.0 h1:EKsfXEYo4JpWMHH5cg+KOUWeuJSov1Id8zGR8eeI1YM= -github.com/prometheus/common v0.42.0/go.mod h1:xBwqVerjNdUDjgODMpudtOMwlOwf2SaTr1yjz4b7Zbc= +github.com/prometheus/common v0.45.0 h1:2BGz0eBc2hdMDLnO/8n0jeB3oPrt2D08CekT0lneoxM= +github.com/prometheus/common v0.45.0/go.mod h1:YJmSTw9BoKxJplESWWxlbyttQR4uaEcGyv9MZjVOJsY= github.com/prometheus/procfs v0.0.0-20180725123919-05ee40e3a273/go.mod h1:c3At6R/oaqEKCNdg8wHV1ftS6bRYblBhIjjI8uT2IGk= github.com/prometheus/procfs v0.0.0-20181005140218-185b4288413d/go.mod h1:c3At6R/oaqEKCNdg8wHV1ftS6bRYblBhIjjI8uT2IGk= github.com/prometheus/procfs v0.0.0-20190117184657-bf6a532e95b1/go.mod h1:c3At6R/oaqEKCNdg8wHV1ftS6bRYblBhIjjI8uT2IGk= @@ -865,8 +833,8 @@ github.com/prometheus/procfs v0.0.8/go.mod h1:7Qr8sr6344vo1JqZ6HhLceV9o3AJ1Ff+Gx github.com/prometheus/procfs v0.0.10/go.mod h1:7Qr8sr6344vo1JqZ6HhLceV9o3AJ1Ff+GxbHq6oeK9A= github.com/prometheus/procfs v0.1.3/go.mod h1:lV6e/gmhEcM9IjHGsFOCxxuZ+z1YqCvr4OA4YeYWdaU= github.com/prometheus/procfs v0.2.0/go.mod h1:lV6e/gmhEcM9IjHGsFOCxxuZ+z1YqCvr4OA4YeYWdaU= -github.com/prometheus/procfs v0.9.0 h1:wzCHvIvM5SxWqYvwgVL7yJY8Lz3PKn49KQtpgMYJfhI= -github.com/prometheus/procfs v0.9.0/go.mod h1:+pB4zwohETzFnmlpe6yd2lSc+0/46IYZRB/chUwxUZY= +github.com/prometheus/procfs v0.12.0 h1:jluTpSng7V9hY0O2R9DzzJHYb2xULk9VTR1V1R/k6Bo= +github.com/prometheus/procfs v0.12.0/go.mod h1:pcuDEFsWDnvcgNzo4EEweacyhjeA9Zk3cnaOZAZEfOo= github.com/prometheus/prom2json v1.3.0 h1:BlqrtbT9lLH3ZsOVhXPsHzFrApCTKRifB7gjJuypu6Y= github.com/prometheus/prom2json v1.3.0/go.mod h1:rMN7m0ApCowcoDlypBHlkNbp5eJQf/+1isKykIP5ZnM= github.com/prysmaticlabs/fastssz v0.0.0-20221107182844-78142813af44 h1:c3p3UzV4vFA7xaCDphnDWOjpxcadrQ26l5b+ypsvyxo= @@ -885,8 +853,8 @@ github.com/quic-go/qpack v0.4.0 h1:Cr9BXA1sQS2SmDUWjSofMPNKmvF6IiIfDRmgU0w1ZCo= github.com/quic-go/qpack v0.4.0/go.mod h1:UZVnYIfi5GRk+zI9UMaCPsmZ2xKJP7XBUvVyT1Knj9A= github.com/quic-go/qtls-go1-20 v0.3.4 h1:MfFAPULvst4yoMgY9QmtpYmfij/em7O8UUi+bNVm7Cg= github.com/quic-go/qtls-go1-20 v0.3.4/go.mod h1:X9Nh97ZL80Z+bX/gUXMbipO6OxdiDi58b/fMC9mAL+k= -github.com/quic-go/quic-go v0.39.3 h1:o3YB6t2SR+HU/pgwF29kJ6g4jJIJEwEZ8CKia1h1TKg= -github.com/quic-go/quic-go v0.39.3/go.mod h1:T09QsDQWjLiQ74ZmacDfqZmhY/NLnw5BC40MANNNZ1Q= +github.com/quic-go/quic-go v0.39.4 h1:PelfiuG7wXEffUT2yceiqz5V6Pc0TA5ruOd1LcmFc1s= +github.com/quic-go/quic-go v0.39.4/go.mod h1:T09QsDQWjLiQ74ZmacDfqZmhY/NLnw5BC40MANNNZ1Q= github.com/quic-go/webtransport-go v0.6.0 h1:CvNsKqc4W2HljHJnoT+rMmbRJybShZ0YPFDD3NxaZLY= github.com/quic-go/webtransport-go v0.6.0/go.mod h1:9KjU4AEBqEQidGHNDkZrb8CAa1abRaosM2yGOyiikEc= github.com/raulk/go-watchdog v1.3.0 h1:oUmdlHxdkXRJlwfG0O9omj8ukerm8MEQavSiDTEtBsk= @@ -899,21 +867,18 @@ github.com/rivo/uniseg v0.4.4/go.mod h1:FN3SvrM+Zdj16jyLfmOkMNblXMcoc8DfTHruCPUc github.com/rogpeppe/fastuuid v0.0.0-20150106093220-6724a57986af/go.mod h1:XWv6SoW27p1b0cqNHllgS5HIMJraePCO15w5zCzIWYg= github.com/rogpeppe/fastuuid v1.2.0/go.mod h1:jVj6XXZzXRy/MSR5jhDC/2q6DgLz+nrA6LYCDYWNEvQ= github.com/rogpeppe/go-internal v1.3.0/go.mod h1:M8bDsm7K2OlrFYOpmOWEs/qY81heoFRclV5y23lUDJ4= -github.com/rogpeppe/go-internal v1.6.1/go.mod h1:xXDCJY+GAPziupqXw64V24skbSoqbTEfhy4qGm1nDQc= -github.com/rogpeppe/go-internal v1.8.1/go.mod h1:JeRgkft04UBgHMgCIwADu4Pn6Mtm5d4nPKWu0nJ5d+o= -github.com/rogpeppe/go-internal v1.9.0 h1:73kH8U+JUqXU8lRuOHeVHaa/SZPifC7BkcraZVejAe8= github.com/rogpeppe/go-internal v1.9.0/go.mod h1:WtVeX8xhTBvf0smdhujwtBcq4Qrzq/fJaraNFVN+nFs= -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/rogpeppe/go-internal v1.10.0 h1:TMyTOH3F/DB16zRVcYyreMH6GnZZrwQVAoYjRBZyWFQ= +github.com/rogpeppe/go-internal v1.10.0/go.mod h1:UQnix2H7Ngw/k4C5ijL5+65zddjncjaFoBhdsK/akog= +github.com/rs/cors v1.9.0 h1:l9HGsTsHJcvW14Nk7J9KFz8bzeAWXn3CG6bgt7LsrAE= +github.com/rs/cors v1.9.0/go.mod h1:XyqrcTp5zjWr1wsJ8PIRZssZ8b/WMcMf71DJnit4EMU= github.com/russross/blackfriday v1.5.2/go.mod h1:JO/DiYxRf+HjHt06OyowR9PTA263kcR/rfWxYHBV53g= github.com/russross/blackfriday/v2 v2.0.1/go.mod h1:+Rmxgy9KzJVeS9/2gXHxylqXiyQDYRxCVz55jmeOWTM= 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/ryanuber/columnize v0.0.0-20160712163229-9b3edd62028f/go.mod h1:sm1tb6uqfes/u+d4ooFouqFdy9/2g9QGwK3SQygK0Ts= -github.com/ryanuber/columnize v2.1.0+incompatible/go.mod h1:sm1tb6uqfes/u+d4ooFouqFdy9/2g9QGwK3SQygK0Ts= github.com/samuel/go-zookeeper v0.0.0-20190923202752-2cc03de413da/go.mod h1:gi+0XIa01GRL2eRQVjQkKGqKF3SF9vZR/HnPullcV2E= github.com/satori/go.uuid v1.2.0/go.mod h1:dA0hQrYB0VpLJoorglMZABFdXlWrHn1NEOzdhQKdks0= -github.com/schollz/closestmatch v2.1.0+incompatible/go.mod h1:RtP1ddjLong6gTkbtmuhtR2uUrrJOpYzYRvbcPAid+g= github.com/schollz/progressbar/v3 v3.3.4 h1:nMinx+JaEm/zJz4cEyClQeAw5rsYSB5th3xv+5lV6Vg= github.com/schollz/progressbar/v3 v3.3.4/go.mod h1:Rp5lZwpgtYmlvmGo1FyDwXMqagyRBQYSDwzlP9QDu84= github.com/sean-/seed v0.0.0-20170313163322-e2103e2c3529/go.mod h1:DxrIzT+xaE7yg65j358z/aeFdxmN0P9QXhEzd20vsDc= @@ -958,20 +923,14 @@ github.com/sourcegraph/syntaxhighlight v0.0.0-20170531221838-bd320f5d308e/go.mod github.com/spaolacci/murmur3 v0.0.0-20180118202830-f09979ecbc72/go.mod h1:JwIasOWyU6f++ZhiEuf87xNszmSA2myDM2Kzu9HwQUA= github.com/spaolacci/murmur3 v1.1.0 h1:7c1g84S4BPRrfL5Xrdp6fOJ206sU9y293DDHaoy0bLI= github.com/spaolacci/murmur3 v1.1.0/go.mod h1:JwIasOWyU6f++ZhiEuf87xNszmSA2myDM2Kzu9HwQUA= -github.com/spf13/afero v1.1.2/go.mod h1:j4pytiNVoe2o6bmDsKpLACNPDBIoEAkihy7loJ1B0CQ= github.com/spf13/afero v1.2.2/go.mod h1:9ZxEEn6pIJ8Rxe320qSDBk6AsU0r9pR7Q4OcevTdifk= github.com/spf13/afero v1.10.0 h1:EaGW2JJh15aKOejeuJ+wpFSHnbd7GE6Wvp3TsNhb6LY= github.com/spf13/afero v1.10.0/go.mod h1:UBogFpq8E9Hx+xc5CNTTEpTnuHVmXDwZcZcE1eb/UhQ= -github.com/spf13/cast v1.3.0/go.mod h1:Qx5cxh0v+4UWYiBimWS+eyWzqEqokIECu5etghLkUJE= github.com/spf13/cobra v0.0.3/go.mod h1:1l0Ry5zgKvJasoi3XT1TypsSe7PqH0Sj9dhYf7v3XqQ= -github.com/spf13/cobra v0.0.5/go.mod h1:3K3wKZymM7VvHMDS9+Akkh4K60UwM26emMESw8tLCHU= -github.com/spf13/jwalterweatherman v1.0.0/go.mod h1:cQK4TGJAtQXfYWX+Ddv3mKDzgVb68N+wFjFa4jdeBTo= github.com/spf13/pflag v0.0.0-20170130214245-9ff6c6923cff/go.mod h1:DYY7MBk1bdzusC3SYhjObp+wFpr4gzcvqqNjLnInEg4= github.com/spf13/pflag v1.0.1/go.mod h1:DYY7MBk1bdzusC3SYhjObp+wFpr4gzcvqqNjLnInEg4= -github.com/spf13/pflag v1.0.3/go.mod h1:DYY7MBk1bdzusC3SYhjObp+wFpr4gzcvqqNjLnInEg4= github.com/spf13/pflag v1.0.5 h1:iy+VFUOCP1a+8yFto/drg2CJ5u0yRoB7fZw3DKv/JXA= github.com/spf13/pflag v1.0.5/go.mod h1:McXfInJRrz4CZXVZOBLb0bTZqETkiAhM9Iw0y3An2Bg= -github.com/spf13/viper v1.3.2/go.mod h1:ZiWeW+zYFKm7srdB9IoDzzZXaJaI5eL9QjNiN/DMA2s= 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/streadway/amqp v0.0.0-20190404075320-75d898a42a94/go.mod h1:AZpEONHx3DKn8O/DFsRAY58/XVQiIPMTMB1SddzLXVw= @@ -999,10 +958,11 @@ github.com/supranational/blst v0.3.11 h1:LyU6FolezeWAhvQk0k6O/d49jqgO52MSDDfYgbe github.com/supranational/blst v0.3.11/go.mod h1:jZJtfjgudtNl4en1tzwPIV3KjUnQUvG3/j+w+fVonLw= github.com/swaggo/swag v1.16.2 h1:28Pp+8DkQoV+HLzLx8RGJZXNGKbFqnuvSbAAtoxiY04= github.com/swaggo/swag v1.16.2/go.mod h1:6YzXnDcpr0767iOejs318CwYkCQqyGer6BizOg03f+E= +github.com/syndtr/goleveldb v1.0.1-0.20210819022825-2ae1ddf74ef7/go.mod h1:q4W45IWZaF22tdD+VEXcAWRA037jwmWEB5VWYORlTpc= github.com/syndtr/goleveldb v1.0.1-0.20220721030215-126854af5e6d h1:vfofYNRScrDdvS342BElfbETmL1Aiz3i2t0zfRj16Hs= github.com/syndtr/goleveldb v1.0.1-0.20220721030215-126854af5e6d/go.mod h1:RRCYJbIwD5jmqPI9XoAFR0OcDxqUctll6zUj/+B4S48= -github.com/taikoxyz/taiko-geth v0.0.0-20240228040257-a00cd0963e60 h1:kJpiKwsHtNF8z8KZVEjLgwPWtI2AbMGNwrrr8VQc1EY= -github.com/taikoxyz/taiko-geth v0.0.0-20240228040257-a00cd0963e60/go.mod h1:TN8ZiHrdJwSe8Cb6x+p0hs5CxhJZPbqB7hHkaUXcmIU= +github.com/taikoxyz/taiko-geth v0.0.0-20240320072400-5db50bce3e8e h1:JCV4FpfGbF1bswFAG/00cvcDqQ0AFknBd30FqEahj38= +github.com/taikoxyz/taiko-geth v0.0.0-20240320072400-5db50bce3e8e/go.mod h1:nqByouVW0a0qx5KKgvYgoXba+pYEHznAAQp6LhZilgM= github.com/tarm/serial v0.0.0-20180830185346-98f6abe2eb07/go.mod h1:kDXzergiv9cbyO7IOYJZWg1U88JhDg3PB6klq9Hg2pA= github.com/templexxx/cpufeat v0.0.0-20180724012125-cef66df7f161/go.mod h1:wM7WEvslTq+iOEAMDLSzhVuOt5BRZ05WirO+b09GHQU= github.com/templexxx/xor v0.0.0-20191217153810-f85b25db303b/go.mod h1:5XA7W9S6mni3h5uvOC75dA3m9CCCaS83lltmc0ukdi4= @@ -1020,43 +980,27 @@ github.com/tyler-smith/go-bip39 v1.1.0 h1:5eUemwrMargf3BSLRRCalXT93Ns6pQJIjYQN2n github.com/tyler-smith/go-bip39 v1.1.0/go.mod h1:gUYDtqQw1JS3ZJ8UWVcGTGqqr6YIN3CWg+kkNaLt55U= github.com/uber/jaeger-client-go v2.25.0+incompatible h1:IxcNZ7WRY1Y3G4poYlx24szfsn/3LvK9QHCq9oQw8+U= github.com/uber/jaeger-client-go v2.25.0+incompatible/go.mod h1:WVhlPFC8FDjOFMMWRy2pZqQJSXxYSwNYOkTr/Z6d3Kk= -github.com/ugorji/go v1.1.4/go.mod h1:uQMGLiO92mf5W77hV/PUCpI3pbzQx3CRekS0kk+RGrc= -github.com/ugorji/go v1.1.7/go.mod h1:kZn38zHttfInRq0xu/PH0az30d+z6vm202qpg1oXVMw= -github.com/ugorji/go/codec v0.0.0-20181204163529-d75b2dcb6bc8/go.mod h1:VFNgLljTbGfSG7qAOspJ7OScBnGdDN/yBr0sguwnwf0= -github.com/ugorji/go/codec v1.1.7/go.mod h1:Ax+UKWsSmolVDwsd+7N3ZtXu+yMGCf907BLYF3GoBXY= github.com/urfave/cli v1.20.0/go.mod h1:70zkFmudgCuE/ngEzBv17Jvp/497gISqfk5gWijbERA= github.com/urfave/cli v1.22.1/go.mod h1:Gos4lmkARVdJ6EkW0WaNv/tZAAMe9V7XWyB60NtXRu0= github.com/urfave/cli v1.22.2/go.mod h1:Gos4lmkARVdJ6EkW0WaNv/tZAAMe9V7XWyB60NtXRu0= -github.com/urfave/cli/v2 v2.25.7 h1:VAzn5oq403l5pHjc4OhD54+XGO9cdKVL/7lDjF+iKUs= -github.com/urfave/cli/v2 v2.25.7/go.mod h1:8qnjx1vcq5s2/wpsqoZFndg2CE5tNFyrTvS6SinrnYQ= -github.com/urfave/negroni v1.0.0/go.mod h1:Meg73S6kFm/4PpbYdq35yYWoCZ9mS/YSx+lKnmiohz4= +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/valyala/bytebufferpool v1.0.0 h1:GqA5TC/0021Y/b9FG4Oi9Mr3q7XYx6KllzawFIhcdPw= github.com/valyala/bytebufferpool v1.0.0/go.mod h1:6bBcMArwyJ5K/AmCkWv1jt77kVWyCJ6HpOuEn7z0Csc= -github.com/valyala/fasthttp v1.6.0/go.mod h1:FstJa9V+Pj9vQ7OJie2qMHdwemEDaDiSdBnvPM1Su9w= -github.com/valyala/fasttemplate v1.0.1/go.mod h1:UQGH1tvbgY+Nz5t2n7tXsz52dQxojPUpymEIMZ47gx8= github.com/valyala/fasttemplate v1.2.1/go.mod h1:KHLXt3tVN2HBp8eijSv/kGJopbvo7S+qRAEEKiv+SiQ= github.com/valyala/fasttemplate v1.2.2 h1:lxLXG0uE3Qnshl9QyaK6XJxMXlQZELvChBOCmQD0Loo= github.com/valyala/fasttemplate v1.2.2/go.mod h1:KHLXt3tVN2HBp8eijSv/kGJopbvo7S+qRAEEKiv+SiQ= -github.com/valyala/tcplisten v0.0.0-20161114210144-ceec8f93295a/go.mod h1:v3UYOV9WzVtRmSR+PDvWpU/qWl4Wa5LApYYX4ZtKbio= github.com/viant/assertly v0.4.8/go.mod h1:aGifi++jvCrUaklKEKT0BU95igDNaqkvz+49uaYMPRU= github.com/viant/toolbox v0.24.0/go.mod h1:OxMCG57V0PXuIP2HNQrtJf2CjqdmbrOx5EkMILuUhzM= github.com/wealdtech/go-bytesutil v1.1.1 h1:ocEg3Ke2GkZ4vQw5lp46rmO+pfqCCTgq35gqOy8JKVc= github.com/wealdtech/go-bytesutil v1.1.1/go.mod h1:jENeMqeTEU8FNZyDFRVc7KqBdRKSnJ9CCh26TcuNb9s= github.com/xdg/scram v0.0.0-20180814205039-7eeb5667e42c/go.mod h1:lB8K/P019DLNhemzwFU4jHLhdvlE6uDZjXFejJXr49I= github.com/xdg/stringprep v1.0.0/go.mod h1:Jhud4/sHMO4oL310DaZAKk9ZaJ08SJfe+sJh0HrGL1Y= -github.com/xeipuuv/gojsonpointer v0.0.0-20180127040702-4e3ac2762d5f/go.mod h1:N2zxlSyiKSe5eX1tZViRH5QA0qijqEDrYZiPEAiq3wU= -github.com/xeipuuv/gojsonreference v0.0.0-20180127040603-bd5ef7bd5415/go.mod h1:GwrjFmJcFw6At/Gs6z4yjiIwzuJ1/+UwLxMQDVQXShQ= -github.com/xeipuuv/gojsonschema v1.2.0/go.mod h1:anYRn/JVcOK2ZgGU+IjEV4nwlhoK5sQluxsYJ78Id3Y= github.com/xiang90/probing v0.0.0-20190116061207-43a291ad63a2/go.mod h1:UETIi67q53MR2AWcXfiuqkDkRtnGDLqkBTpCHuJHxtU= -github.com/xordataexchange/crypt v0.0.3-0.20170626215501-b2862e3d0a77/go.mod h1:aYKd//L2LvnjZzWKhF00oedf4jCCReLcmhLdhm1A27Q= 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/xtaci/kcp-go v5.4.20+incompatible/go.mod h1:bN6vIwHQbfHaHtFpEssmWsN45a+AZwO7eyRCmEIbtvE= github.com/xtaci/lossyconn v0.0.0-20190602105132-8df528c0c9ae/go.mod h1:gXtu8J62kEgmN++bm9BVICuT/e8yiLI2KFobd/TRFsE= -github.com/yalp/jsonpath v0.0.0-20180802001716-5cc68e5049a0/go.mod h1:/LWChgwKmvncFJFHJ7Gvn9wZArjbV5/FppcK2fKk/tI= -github.com/yudai/gojsondiff v1.0.0/go.mod h1:AY32+k2cwILAkW1fbgxQ5mUmMiZFgLIV+FBNExI05xg= -github.com/yudai/golcs v0.0.0-20170316035057-ecda9a501e82/go.mod h1:lgjkn3NuSvDfVJdfcVVdX+jpBxNmX4rDAzaS45IcYoM= -github.com/yudai/pp v2.0.1+incompatible/go.mod h1:PuxR/8QJ7cyCkFp/aUDS+JY727OFEZkTdatxwunjIkc= github.com/yuin/goldmark v1.1.25/go.mod h1:3hX8gzYuyVAZsxl0MRgGTJEmQBFcNTphYh9decYSb74= github.com/yuin/goldmark v1.1.27/go.mod h1:3hX8gzYuyVAZsxl0MRgGTJEmQBFcNTphYh9decYSb74= github.com/yuin/goldmark v1.1.32/go.mod h1:3hX8gzYuyVAZsxl0MRgGTJEmQBFcNTphYh9decYSb74= @@ -1108,10 +1052,10 @@ go.uber.org/zap v1.26.0 h1:sI7k6L95XOKS281NhVKOFCUNIvv9e0w4BF8N3u+tCRo= go.uber.org/zap v1.26.0/go.mod h1:dtElttAiwGvoJ/vj4IwHBS/gXsEu/pZ50mUIRWuG0so= go4.org v0.0.0-20180809161055-417644f6feb5/go.mod h1:MkTOUMDaeVYJUOUsaDXIhWPZYa1yOyC1qaOBpL57BhE= golang.org/x/build v0.0.0-20190111050920-041ab4dc3f9d/go.mod h1:OWs+y06UdEOHN4y+MfF/py+xQ/tYqIWW03b70/CG9Rw= +golang.org/x/crypto v0.0.0-20170930174604-9419663f5a44/go.mod h1:6SG95UA2DQfeDnfUPMdvaQW0Q7yPrPDi9nlGo2tz2b4= golang.org/x/crypto v0.0.0-20180904163835-0709b304e793/go.mod h1:6SG95UA2DQfeDnfUPMdvaQW0Q7yPrPDi9nlGo2tz2b4= golang.org/x/crypto v0.0.0-20181029021203-45a5f77698d3/go.mod h1:6SG95UA2DQfeDnfUPMdvaQW0Q7yPrPDi9nlGo2tz2b4= golang.org/x/crypto v0.0.0-20181030102418-4d3f4d9ffa16/go.mod h1:6SG95UA2DQfeDnfUPMdvaQW0Q7yPrPDi9nlGo2tz2b4= -golang.org/x/crypto v0.0.0-20181203042331-505ab145d0a9/go.mod h1:6SG95UA2DQfeDnfUPMdvaQW0Q7yPrPDi9nlGo2tz2b4= golang.org/x/crypto v0.0.0-20190308221718-c2843e01d9a2/go.mod h1:djNgcEr1/C05ACkg1iLfiJU5Ep61QUkGW8qpdssI0+w= golang.org/x/crypto v0.0.0-20190313024323-a1f597ede03a/go.mod h1:djNgcEr1/C05ACkg1iLfiJU5Ep61QUkGW8qpdssI0+w= golang.org/x/crypto v0.0.0-20190510104115-cbcb75029529/go.mod h1:yigFU9vqHzYiE8UmvKecakEJjdnWj3jj499lnFckfCI= @@ -1120,7 +1064,6 @@ golang.org/x/crypto v0.0.0-20190611184440-5c40567a22f8/go.mod h1:yigFU9vqHzYiE8U golang.org/x/crypto v0.0.0-20190701094942-4def268fd1a4/go.mod h1:yigFU9vqHzYiE8UmvKecakEJjdnWj3jj499lnFckfCI= golang.org/x/crypto v0.0.0-20191011191535-87dc89f01550/go.mod h1:yigFU9vqHzYiE8UmvKecakEJjdnWj3jj499lnFckfCI= golang.org/x/crypto v0.0.0-20191219195013-becbf705a915/go.mod h1:LzIPMQfyMNhhGPhUkYOs5KpL4U8rLKemX1yGLhDgUto= -golang.org/x/crypto v0.0.0-20191227163750-53104e6ec876/go.mod h1:LzIPMQfyMNhhGPhUkYOs5KpL4U8rLKemX1yGLhDgUto= golang.org/x/crypto v0.0.0-20200204104054-c9f3fb736b72/go.mod h1:LzIPMQfyMNhhGPhUkYOs5KpL4U8rLKemX1yGLhDgUto= golang.org/x/crypto v0.0.0-20200221231518-2aa609cf4a9d/go.mod h1:LzIPMQfyMNhhGPhUkYOs5KpL4U8rLKemX1yGLhDgUto= golang.org/x/crypto v0.0.0-20200602180216-279210d13fed/go.mod h1:LzIPMQfyMNhhGPhUkYOs5KpL4U8rLKemX1yGLhDgUto= @@ -1128,10 +1071,9 @@ golang.org/x/crypto v0.0.0-20200622213623-75b288015ac9/go.mod h1:LzIPMQfyMNhhGPh golang.org/x/crypto v0.0.0-20201002170205-7f63de1d35b0/go.mod h1:LzIPMQfyMNhhGPhUkYOs5KpL4U8rLKemX1yGLhDgUto= golang.org/x/crypto v0.0.0-20210322153248-0c34fe9e7dc2/go.mod h1:T9bdIzuCu7OtxOm1hfPfRQxPLYneinmdGuTeoZ9dtd4= golang.org/x/crypto v0.0.0-20210421170649-83a5a9bb288b/go.mod h1:T9bdIzuCu7OtxOm1hfPfRQxPLYneinmdGuTeoZ9dtd4= -golang.org/x/crypto v0.0.0-20210921155107-089bfa567519/go.mod h1:GvvjBRRGRdwPK5ydBHafDWAxML/pGHZbMvKqRZ5+Abc= golang.org/x/crypto v0.0.0-20220722155217-630584e8d5aa/go.mod h1:IxCIyHEi3zRg3s0A5j5BB6A9Jmi73HwBIUl50j+osU4= -golang.org/x/crypto v0.17.0 h1:r8bRNjWL3GshPW3gkd+RpvzWrZAwPS49OmTGZ/uhM4k= -golang.org/x/crypto v0.17.0/go.mod h1:gCAAfMLgwOJRpTjQ2zCCt2OcSfYMTeZVSRtQlPC7Nq4= +golang.org/x/crypto v0.19.0 h1:ENy+Az/9Y1vSrlrvBSyna3PITt4tiZLf7sgCjZBX7Wo= +golang.org/x/crypto v0.19.0/go.mod h1:Iy9bg/ha4yyC70EfRS8jz+B6ybOBKMaSxLj6P6oBDfU= golang.org/x/exp v0.0.0-20190121172915-509febef88a4/go.mod h1:CJ0aWSM057203Lf6IL+f9T1iT9GByDxfZKAQTCR3kQA= golang.org/x/exp v0.0.0-20190306152737-a1d7652674e8/go.mod h1:CJ0aWSM057203Lf6IL+f9T1iT9GByDxfZKAQTCR3kQA= golang.org/x/exp v0.0.0-20190510132918-efd6b22b2522/go.mod h1:ZjyILWgesfNpC6sMxTJOJm9Kp84zZh5NQWvqDGG3Qr8= @@ -1158,7 +1100,6 @@ golang.org/x/lint v0.0.0-20191125180803-fdd1cda4f05f/go.mod h1:5qLYkcX4OjUUV8bRu golang.org/x/lint v0.0.0-20200130185559-910be7a94367/go.mod h1:3xt1FjdF8hUf6vQPIChWIBhFzV8gjjsPE/fR3IyQdNY= golang.org/x/lint v0.0.0-20200302205851-738671d3881b/go.mod h1:3xt1FjdF8hUf6vQPIChWIBhFzV8gjjsPE/fR3IyQdNY= golang.org/x/lint v0.0.0-20201208152925-83fdc39ff7b5/go.mod h1:3xt1FjdF8hUf6vQPIChWIBhFzV8gjjsPE/fR3IyQdNY= -golang.org/x/lint v0.0.0-20210508222113-6edffad5e616/go.mod h1:3xt1FjdF8hUf6vQPIChWIBhFzV8gjjsPE/fR3IyQdNY= golang.org/x/mobile v0.0.0-20190312151609-d3739f865fa6/go.mod h1:z+o9i4GpDbdi3rU15maQ/Ox0txvL9dWGYEHz965HBQE= golang.org/x/mobile v0.0.0-20190719004257-d2bd2a29d028/go.mod h1:E/iHnbuqvinMTCcRqshq8CkpyQDoeVncDDYHnLhea+o= golang.org/x/mod v0.0.0-20190513183733-4bf6d317e70e/go.mod h1:mXi4GBBbnImb6dmsKGUJ2LatrhH/nqhxcFungHvyanc= @@ -1172,6 +1113,7 @@ golang.org/x/mod v0.4.1/go.mod h1:s0Qsj1ACt9ePp/hMypM3fl4fZqREWJwdYDEqhRiZZUA= golang.org/x/mod v0.4.2/go.mod h1:s0Qsj1ACt9ePp/hMypM3fl4fZqREWJwdYDEqhRiZZUA= golang.org/x/mod v0.14.0 h1:dGoOF9QVLYng8IHTm7BAyWqCqSheQ5pYWGhzW00YJr0= golang.org/x/mod v0.14.0/go.mod h1:hTbmBsO62+eylJbnUtE2MGJUyE7QWk4xUqPFrRgJ+7c= +golang.org/x/net v0.0.0-20180719180050-a680a1efc54d/go.mod h1:mL1N/T3taQHkDXs73rZJwtUhF3w3ftmwwsq0BUmARs4= golang.org/x/net v0.0.0-20180724234803-3673e40ba225/go.mod h1:mL1N/T3taQHkDXs73rZJwtUhF3w3ftmwwsq0BUmARs4= golang.org/x/net v0.0.0-20180826012351-8a410e7b638d/go.mod h1:mL1N/T3taQHkDXs73rZJwtUhF3w3ftmwwsq0BUmARs4= golang.org/x/net v0.0.0-20180906233101-161cd47e91fd/go.mod h1:mL1N/T3taQHkDXs73rZJwtUhF3w3ftmwwsq0BUmARs4= @@ -1186,7 +1128,6 @@ golang.org/x/net v0.0.0-20190125091013-d26f9f9a57f3/go.mod h1:mL1N/T3taQHkDXs73r golang.org/x/net v0.0.0-20190213061140-3a22650c66bd/go.mod h1:mL1N/T3taQHkDXs73rZJwtUhF3w3ftmwwsq0BUmARs4= golang.org/x/net v0.0.0-20190311183353-d8887717615a/go.mod h1:t9HGtf8HONx5eT2rtn7q6eTqICYqUVnKs3thJo3Qplg= golang.org/x/net v0.0.0-20190313220215-9f648a60d977/go.mod h1:t9HGtf8HONx5eT2rtn7q6eTqICYqUVnKs3thJo3Qplg= -golang.org/x/net v0.0.0-20190327091125-710a502c58a2/go.mod h1:t9HGtf8HONx5eT2rtn7q6eTqICYqUVnKs3thJo3Qplg= golang.org/x/net v0.0.0-20190404232315-eb5bcb51f2a3/go.mod h1:t9HGtf8HONx5eT2rtn7q6eTqICYqUVnKs3thJo3Qplg= golang.org/x/net v0.0.0-20190501004415-9ce7a6920f09/go.mod h1:t9HGtf8HONx5eT2rtn7q6eTqICYqUVnKs3thJo3Qplg= golang.org/x/net v0.0.0-20190503192946-f4e77d36d62c/go.mod h1:t9HGtf8HONx5eT2rtn7q6eTqICYqUVnKs3thJo3Qplg= @@ -1211,6 +1152,7 @@ golang.org/x/net v0.0.0-20200520004742-59133d7f0dd7/go.mod h1:qpuaurCH72eLCgpAm/ golang.org/x/net v0.0.0-20200520182314-0ba52f642ac2/go.mod h1:qpuaurCH72eLCgpAm/N6yyVIVM9cpaDIP3A8BGJEC5A= golang.org/x/net v0.0.0-20200625001655-4c5254603344/go.mod h1:/O7V0waA8r7cgGh81Ro3o1hOxt32SMVPicZroKQ2sZA= golang.org/x/net v0.0.0-20200707034311-ab3426394381/go.mod h1:/O7V0waA8r7cgGh81Ro3o1hOxt32SMVPicZroKQ2sZA= +golang.org/x/net v0.0.0-20200813134508-3edf25e44fcc/go.mod h1:/O7V0waA8r7cgGh81Ro3o1hOxt32SMVPicZroKQ2sZA= golang.org/x/net v0.0.0-20200822124328-c89045814202/go.mod h1:/O7V0waA8r7cgGh81Ro3o1hOxt32SMVPicZroKQ2sZA= golang.org/x/net v0.0.0-20201021035429-f5854403a974/go.mod h1:sp8m0HH+o8qH0wwXwYZr8TS3Oi6o0r6Gce1SSxlDquU= golang.org/x/net v0.0.0-20201031054903-ff519b6c9102/go.mod h1:sp8m0HH+o8qH0wwXwYZr8TS3Oi6o0r6Gce1SSxlDquU= @@ -1222,7 +1164,6 @@ golang.org/x/net v0.0.0-20210226172049-e18ecbb05110/go.mod h1:m0MpNAwzfU5UDzcl9v golang.org/x/net v0.0.0-20210316092652-d523dce5a7f4/go.mod h1:RBQZq4jEuRlivfhVLdyRGr576XBO4/greRjx4P4O3yc= golang.org/x/net v0.0.0-20210405180319-a5a99cb37ef4/go.mod h1:p54w0d4576C0XHj96bSt6lcn1PtDYWL6XObtHCRCNQM= golang.org/x/net v0.0.0-20210428140749-89ef3d95e781/go.mod h1:OJAsFXCWl8Ukc7SiCT/9KSuxbyM7479/AVlXFRxuMCk= -golang.org/x/net v0.0.0-20211008194852-3b03d305991f/go.mod h1:9nx3DQGgdP8bBQD5qxJ1jj9UTztislL4KSBs9R2vV5Y= golang.org/x/net v0.0.0-20211029224645-99673261e6eb/go.mod h1:9nx3DQGgdP8bBQD5qxJ1jj9UTztislL4KSBs9R2vV5Y= golang.org/x/net v0.0.0-20211112202133-69e39bad7dc2/go.mod h1:9nx3DQGgdP8bBQD5qxJ1jj9UTztislL4KSBs9R2vV5Y= golang.org/x/net v0.0.0-20220225172249-27dd8689420f/go.mod h1:CfG3xpIq0wQ8r1q4Su4UZFWDARRcnwPjda9FqA0JpMk= @@ -1243,8 +1184,8 @@ golang.org/x/oauth2 v0.0.0-20210218202405-ba52d332ba99/go.mod h1:KelEdhl1UZF7XfJ golang.org/x/oauth2 v0.0.0-20210220000619-9bb904979d93/go.mod h1:KelEdhl1UZF7XfJ4dDtk6s++YSgaE7mD/BuKKDLBl4A= golang.org/x/oauth2 v0.0.0-20210313182246-cd4f82c27b84/go.mod h1:KelEdhl1UZF7XfJ4dDtk6s++YSgaE7mD/BuKKDLBl4A= golang.org/x/oauth2 v0.0.0-20210402161424-2e8d93401602/go.mod h1:KelEdhl1UZF7XfJ4dDtk6s++YSgaE7mD/BuKKDLBl4A= -golang.org/x/oauth2 v0.7.0 h1:qe6s0zUXlPX80/dITx3440hWZ7GwMwgDDyrSGTPJG/g= -golang.org/x/oauth2 v0.7.0/go.mod h1:hPLQkd9LyjfXTiRohC/41GhcFqxisoUQ99sCUOHO9x4= +golang.org/x/oauth2 v0.12.0 h1:smVPGxink+n1ZI5pkQa8y6fZT0RW0MgCO5bFpepy4B4= +golang.org/x/oauth2 v0.12.0/go.mod h1:A74bZ3aGXgCY0qaIC9Ahg6Lglin4AMAco8cIv9baba4= golang.org/x/perf v0.0.0-20180704124530-6e6d33e29852/go.mod h1:JLpeXjPJfIyPr5TlbXLkXWLhP8nz10XfvxElABhCtcw= golang.org/x/sync v0.0.0-20180314180146-1d60e4601c6f/go.mod h1:RxMgew5VJxzue5/jJTE5uejpjVlOe/izrB70Jof72aM= golang.org/x/sync v0.0.0-20181108010431-42b317875d0f/go.mod h1:RxMgew5VJxzue5/jJTE5uejpjVlOe/izrB70Jof72aM= @@ -1257,8 +1198,8 @@ golang.org/x/sync v0.0.0-20200625203802-6e8e738ad208/go.mod h1:RxMgew5VJxzue5/jJ golang.org/x/sync v0.0.0-20201020160332-67f06af15bc9/go.mod h1:RxMgew5VJxzue5/jJTE5uejpjVlOe/izrB70Jof72aM= golang.org/x/sync v0.0.0-20201207232520-09787c993a3a/go.mod h1:RxMgew5VJxzue5/jJTE5uejpjVlOe/izrB70Jof72aM= golang.org/x/sync v0.0.0-20210220032951-036812b2e83c/go.mod h1:RxMgew5VJxzue5/jJTE5uejpjVlOe/izrB70Jof72aM= -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/sync v0.6.0 h1:5BMeUDZ7vkXGfEr1x9B4bRcTH4lpkTkpdh0T/J+qjbQ= +golang.org/x/sync v0.6.0/go.mod h1:Czt+wKu1gCyEFDUtn0jG5QVvpJ6rzVqr5aXyt9drQfk= golang.org/x/sys v0.0.0-20180810173357-98c5dad5d1a0/go.mod h1:STP8DvDyc/dI5b8T5hshtkjS+E42TnysNCUPdjciGhY= golang.org/x/sys v0.0.0-20180823144017-11551d06cbcc/go.mod h1:STP8DvDyc/dI5b8T5hshtkjS+E42TnysNCUPdjciGhY= golang.org/x/sys v0.0.0-20180830151530-49385e6e1522/go.mod h1:STP8DvDyc/dI5b8T5hshtkjS+E42TnysNCUPdjciGhY= @@ -1269,10 +1210,8 @@ golang.org/x/sys v0.0.0-20181029174526-d69651ed3497/go.mod h1:STP8DvDyc/dI5b8T5h golang.org/x/sys v0.0.0-20181107165924-66b7b1311ac8/go.mod h1:STP8DvDyc/dI5b8T5hshtkjS+E42TnysNCUPdjciGhY= golang.org/x/sys v0.0.0-20181116152217-5ac8a444bdc5/go.mod h1:STP8DvDyc/dI5b8T5hshtkjS+E42TnysNCUPdjciGhY= golang.org/x/sys v0.0.0-20181122145206-62eef0e2fa9b/go.mod h1:STP8DvDyc/dI5b8T5hshtkjS+E42TnysNCUPdjciGhY= -golang.org/x/sys v0.0.0-20181205085412-a5c9d58dba9a/go.mod h1:STP8DvDyc/dI5b8T5hshtkjS+E42TnysNCUPdjciGhY= golang.org/x/sys v0.0.0-20190130150945-aca44879d564/go.mod h1:STP8DvDyc/dI5b8T5hshtkjS+E42TnysNCUPdjciGhY= golang.org/x/sys v0.0.0-20190215142949-d0b11bdaac8a/go.mod h1:STP8DvDyc/dI5b8T5hshtkjS+E42TnysNCUPdjciGhY= -golang.org/x/sys v0.0.0-20190222072716-a9d3bda3a223/go.mod h1:STP8DvDyc/dI5b8T5hshtkjS+E42TnysNCUPdjciGhY= golang.org/x/sys v0.0.0-20190312061237-fead79001313/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20190316082340-a2f829d7f35f/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20190412213103-97732733099d/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= @@ -1282,9 +1221,7 @@ golang.org/x/sys v0.0.0-20190507160741-ecd444e8653b/go.mod h1:h1NjWce9XRLGQEsW7w golang.org/x/sys v0.0.0-20190606165138-5da285871e9c/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20190616124812-15dcb6c0061f/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20190624142023-c5567b49c5d0/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= -golang.org/x/sys v0.0.0-20190626221950-04f50cda93cb/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20190726091711-fc99dfbffb4e/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= -golang.org/x/sys v0.0.0-20190813064441-fde4db37ae7a/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20190826190057-c7b8b68b1456/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20190904154756-749cb33beabd/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20190916202348-b4ddaad3f8a3/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= @@ -1310,11 +1247,13 @@ golang.org/x/sys v0.0.0-20200331124033-c3d80250170d/go.mod h1:h1NjWce9XRLGQEsW7w golang.org/x/sys v0.0.0-20200501052902-10377860bb8e/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20200511232937-7e40ca221e25/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20200515095857-1151b9dac4a9/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= +golang.org/x/sys v0.0.0-20200519105757-fe76b779f299/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20200523222454-059865788121/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20200602225109-6fdc65e7d980/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20200615200032-f1bc736245b1/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20200625212154-ddb9806d33ae/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20200803210538-64077c9b5642/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= +golang.org/x/sys v0.0.0-20200814200057-3d37ad5750ed/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20200905004654-be1d3432aa8f/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20200923182605-d9f96fdee20d/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20200930185726-fdedc70b468f/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= @@ -1339,26 +1278,23 @@ golang.org/x/sys v0.0.0-20210510120138-977fb7262007/go.mod h1:oPkhp1MJrh7nUepCBc golang.org/x/sys v0.0.0-20210615035016-665e8c7367d1/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= 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-20211007075335-d3039528d8ac/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= golang.org/x/sys v0.0.0-20211103235746-7861aae1554b/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= golang.org/x/sys v0.0.0-20211216021012-1d35b9e2eb4e/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= -golang.org/x/sys v0.0.0-20220209214540-3681064d5158/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= golang.org/x/sys v0.0.0-20220412211240-33da011f77ad/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= golang.org/x/sys v0.0.0-20220520151302-bc2c85ada10a/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= golang.org/x/sys v0.0.0-20220715151400-c0bba94af5f8/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.17.0 h1:25cE3gD+tdBA7lp7QfhuV+rJiE9YXTcS3VG1SqssI/Y= +golang.org/x/sys v0.17.0/go.mod h1:/VUhepiaJMQUp4+oa/7Zr1D23ma6VTLIYjOOTFZPUcA= golang.org/x/term v0.0.0-20201126162022-7de9c90e9dd1/go.mod h1:bj7SfCRtBDWHUb9snDiAeCFNEtKQo2Wmx5Cou7ajbmo= golang.org/x/term v0.0.0-20210927222741-03fcf44c2211/go.mod h1:jbD1KX2456YbFQfuXm/mYQcufACuNUgVhRMnK/tPxf8= -golang.org/x/term v0.15.0 h1:y/Oo/a/q3IXu26lQgl04j/gjuBDOBlx7X6Om1j2CPW4= -golang.org/x/term v0.15.0/go.mod h1:BDl952bC7+uMoWR75FIrCDx79TPU9oHkTZ9yRbYOrX0= +golang.org/x/term v0.17.0 h1:mkTF7LCd6WGJNL3K1Ad7kwxNfYAW6a8a8QqtMblp/4U= +golang.org/x/term v0.17.0/go.mod h1:lLRBjIVuehSbZlaOtGMbcMncT+aqLLLmKrsjNrUguwk= golang.org/x/text v0.0.0-20170915032832-14c0d48ead0c/go.mod h1:NqM8EUOU14njkJ3fqMW+pc6Ldnwhi/IjpwHt7yyuwOQ= golang.org/x/text v0.3.0/go.mod h1:NqM8EUOU14njkJ3fqMW+pc6Ldnwhi/IjpwHt7yyuwOQ= golang.org/x/text v0.3.1-0.20180807135948-17ff2d5776d2/go.mod h1:NqM8EUOU14njkJ3fqMW+pc6Ldnwhi/IjpwHt7yyuwOQ= @@ -1375,21 +1311,18 @@ golang.org/x/time v0.0.0-20181108054448-85acf8d2951c/go.mod h1:tRJNPiyCQ0inRvYxb golang.org/x/time v0.0.0-20190308202827-9d24e82272b4/go.mod h1:tRJNPiyCQ0inRvYxbN9jk5I+vvW/OXSQhTDSoE431IQ= golang.org/x/time v0.0.0-20191024005414-555d28b269f0/go.mod h1:tRJNPiyCQ0inRvYxbN9jk5I+vvW/OXSQhTDSoE431IQ= golang.org/x/time v0.0.0-20200630173020-3af7569d3a1e/go.mod h1:tRJNPiyCQ0inRvYxbN9jk5I+vvW/OXSQhTDSoE431IQ= -golang.org/x/time v0.0.0-20201208040808-7e3f01d25324/go.mod h1:tRJNPiyCQ0inRvYxbN9jk5I+vvW/OXSQhTDSoE431IQ= -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/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-20180221164845-07fd8470d635/go.mod h1:n7NCudcB/nEzxVGmLbDWY5pfWTLqBcC2KZ6jyYvM4mQ= golang.org/x/tools v0.0.0-20180828015842-6cd1fcedba52/go.mod h1:n7NCudcB/nEzxVGmLbDWY5pfWTLqBcC2KZ6jyYvM4mQ= golang.org/x/tools v0.0.0-20180917221912-90fa682c2a6e/go.mod h1:n7NCudcB/nEzxVGmLbDWY5pfWTLqBcC2KZ6jyYvM4mQ= golang.org/x/tools v0.0.0-20181030000716-a0a13e073c7b/go.mod h1:n7NCudcB/nEzxVGmLbDWY5pfWTLqBcC2KZ6jyYvM4mQ= golang.org/x/tools v0.0.0-20181030221726-6c7e314b6563/go.mod h1:n7NCudcB/nEzxVGmLbDWY5pfWTLqBcC2KZ6jyYvM4mQ= -golang.org/x/tools v0.0.0-20181221001348-537d06c36207/go.mod h1:n7NCudcB/nEzxVGmLbDWY5pfWTLqBcC2KZ6jyYvM4mQ= golang.org/x/tools v0.0.0-20190114222345-bf090417da8b/go.mod h1:n7NCudcB/nEzxVGmLbDWY5pfWTLqBcC2KZ6jyYvM4mQ= golang.org/x/tools v0.0.0-20190226205152-f727befe758c/go.mod h1:9Yl7xja0Znq3iFh3HoIrodX9oNMXvdceNzlUR8zjMvY= golang.org/x/tools v0.0.0-20190311212946-11955173bddd/go.mod h1:LCzVGOaR6xXOjkQ3onu1FJEFr0SW1gC7cKk1uF8kGRs= golang.org/x/tools v0.0.0-20190312151545-0bb0c0a6e846/go.mod h1:LCzVGOaR6xXOjkQ3onu1FJEFr0SW1gC7cKk1uF8kGRs= golang.org/x/tools v0.0.0-20190312170243-e65039ee4138/go.mod h1:LCzVGOaR6xXOjkQ3onu1FJEFr0SW1gC7cKk1uF8kGRs= -golang.org/x/tools v0.0.0-20190327201419-c70d86f8b7cf/go.mod h1:LCzVGOaR6xXOjkQ3onu1FJEFr0SW1gC7cKk1uF8kGRs= golang.org/x/tools v0.0.0-20190328211700-ab21143f2384/go.mod h1:LCzVGOaR6xXOjkQ3onu1FJEFr0SW1gC7cKk1uF8kGRs= golang.org/x/tools v0.0.0-20190425150028-36563e24a262/go.mod h1:RgjU9mgBXZiqYHBnxXauZ1Gv1EHHAz9KjViQ78xBX0Q= golang.org/x/tools v0.0.0-20190506145303-2d16b83fe98c/go.mod h1:RgjU9mgBXZiqYHBnxXauZ1Gv1EHHAz9KjViQ78xBX0Q= @@ -1440,10 +1373,9 @@ golang.org/x/tools v0.0.0-20210105154028-b0ab187a4818/go.mod h1:emZCQorbCU4vsT4f golang.org/x/tools v0.0.0-20210106214847-113979e3529a/go.mod h1:emZCQorbCU4vsT4fOWvOPXz4eW1wZW4PmDk9uLelYpA= golang.org/x/tools v0.0.0-20210108195828-e2f9c7f1fc8e/go.mod h1:emZCQorbCU4vsT4fOWvOPXz4eW1wZW4PmDk9uLelYpA= golang.org/x/tools v0.1.0/go.mod h1:xkSsbof2nBLbhDlRMhhhyNLN/zl3eTqcnHD5viDpcZ0= -golang.org/x/tools v0.1.3/go.mod h1:o0xws9oXOQQZyjljx8fwUC0k7L1pTE6eaCbjGeHmOkk= golang.org/x/tools v0.1.5/go.mod h1:o0xws9oXOQQZyjljx8fwUC0k7L1pTE6eaCbjGeHmOkk= -golang.org/x/tools v0.16.0 h1:GO788SKMRunPIBCXiQyo2AaexLstOrVhuAL5YwsckQM= -golang.org/x/tools v0.16.0/go.mod h1:kYVVN6I1mBNoB1OX+noeBjbRk4IUEPa7JJ+TJMEooJ0= +golang.org/x/tools v0.16.1 h1:TLyB3WofjdOEepBHAU20JdNC1Zbg87elYofWYAY5oZA= +golang.org/x/tools v0.16.1/go.mod h1:kYVVN6I1mBNoB1OX+noeBjbRk4IUEPa7JJ+TJMEooJ0= golang.org/x/xerrors v0.0.0-20190717185122-a985d3407aa7/go.mod h1:I/5z698sn9Ka8TeJc9MKroUUfqBBauWjQqLJ2OPfmY0= golang.org/x/xerrors v0.0.0-20191011141410-1b5146add898/go.mod h1:I/5z698sn9Ka8TeJc9MKroUUfqBBauWjQqLJ2OPfmY0= golang.org/x/xerrors v0.0.0-20191204190536-9bdfabe68543/go.mod h1:I/5z698sn9Ka8TeJc9MKroUUfqBBauWjQqLJ2OPfmY0= @@ -1486,7 +1418,6 @@ google.golang.org/appengine v1.6.5/go.mod h1:8WjMMxjGQR8xUklV/ARdw2HLXBOI7O7uCID google.golang.org/appengine v1.6.6/go.mod h1:8WjMMxjGQR8xUklV/ARdw2HLXBOI7O7uCIDZVag1xfc= google.golang.org/appengine v1.6.7 h1:FZR1q0exgwxzPzp/aF+VccGrSfxfPpkBqjIIEq3ru6c= google.golang.org/appengine v1.6.7/go.mod h1:8WjMMxjGQR8xUklV/ARdw2HLXBOI7O7uCIDZVag1xfc= -google.golang.org/genproto v0.0.0-20180518175338-11a468237815/go.mod h1:JiN7NxoALGmiZfu7CAH4rXhgtRTLTxftemlI0sWmxmc= google.golang.org/genproto v0.0.0-20180817151627-c66870c02cf8/go.mod h1:JiN7NxoALGmiZfu7CAH4rXhgtRTLTxftemlI0sWmxmc= google.golang.org/genproto v0.0.0-20180831171423-11092d34479b/go.mod h1:JiN7NxoALGmiZfu7CAH4rXhgtRTLTxftemlI0sWmxmc= google.golang.org/genproto v0.0.0-20181029155118-b69ba1387ce2/go.mod h1:JiN7NxoALGmiZfu7CAH4rXhgtRTLTxftemlI0sWmxmc= @@ -1535,10 +1466,8 @@ google.golang.org/genproto v0.0.0-20210303154014-9728d6b83eeb/go.mod h1:FWY/as6D google.golang.org/genproto v0.0.0-20210310155132-4ce2db91004e/go.mod h1:FWY/as6DDZQgahTzZj3fqbO1CbirC29ZNUFHwi0/+no= google.golang.org/genproto v0.0.0-20210319143718-93e7006c17a6/go.mod h1:FWY/as6DDZQgahTzZj3fqbO1CbirC29ZNUFHwi0/+no= google.golang.org/genproto v0.0.0-20210402141018-6c239bbf2bb1/go.mod h1:9lPAdzaEmUacj36I+k7YKbEc5CXzPIeORRgDAUOu28A= -google.golang.org/genproto v0.0.0-20210624195500-8bfb893ecb84/go.mod h1:SzzZ/N+nwJDaO1kznhnlzqS8ocJICar6hYhVyhi++24= google.golang.org/genproto v0.0.0-20230410155749-daa745c078e1 h1:KpwkzHKEF7B9Zxg18WzOa7djJ+Ha5DzthMyZYQfEn2A= google.golang.org/genproto v0.0.0-20230410155749-daa745c078e1/go.mod h1:nKE/iIaLqn2bQwXBg8f1g2Ylh6r5MN5CmZvuzZCgsCU= -google.golang.org/grpc v1.12.0/go.mod h1:yo6s7OP7yaDglbqo1J04qKzAhqBH6lvTonzMVmEdcZw= google.golang.org/grpc v1.14.0/go.mod h1:yo6s7OP7yaDglbqo1J04qKzAhqBH6lvTonzMVmEdcZw= google.golang.org/grpc v1.16.0/go.mod h1:0JHn/cJsOMiMfNA9+DeHDlAU7KAAB5GDlYFpa9MZMio= google.golang.org/grpc v1.17.0/go.mod h1:6QZJwpn2B+Zp71q/5VxRsJ6NXXVCE5NRUHRo+f3cWCs= @@ -1565,7 +1494,6 @@ google.golang.org/grpc v1.34.0/go.mod h1:WotjhfgOW/POjDeRt8vscBtXq+2VjORFy659qA5 google.golang.org/grpc v1.35.0/go.mod h1:qjiiYl8FncCW8feJPdyg3v6XW24KsRHe+dy9BAGRRjU= google.golang.org/grpc v1.36.0/go.mod h1:qjiiYl8FncCW8feJPdyg3v6XW24KsRHe+dy9BAGRRjU= google.golang.org/grpc v1.36.1/go.mod h1:qjiiYl8FncCW8feJPdyg3v6XW24KsRHe+dy9BAGRRjU= -google.golang.org/grpc v1.38.0/go.mod h1:NREThFqKR1f3iQ6oBuvc5LadQuXVGo9rkm5ZGrQdJfM= google.golang.org/grpc v1.56.3 h1:8I4C0Yq1EjstUzUJzpcRVbuYA2mODtEmpWiQoN/b2nc= google.golang.org/grpc v1.56.3/go.mod h1:I9bI3vqKfayGqPUAwGdOSu7kt6oIJLixfffKrpXqQ9s= google.golang.org/grpc/cmd/protoc-gen-go-grpc v1.0.0/go.mod h1:6Kw0yEErY5E/yWrBtf03jp27GLLJujG4z/JK95pnjjw= @@ -1581,8 +1509,8 @@ google.golang.org/protobuf v1.24.0/go.mod h1:r/3tXBNzIEhYS9I1OUVjXDlt8tc493IdKGj google.golang.org/protobuf v1.25.0/go.mod h1:9JNX74DMeImyA3h4bdi1ymwjUzf21/xIlbajtzgsN7c= google.golang.org/protobuf v1.26.0-rc.1/go.mod h1:jlhhOSvTdKEhbULTjvd4ARK9grFBp09yW+WbY/TyQbw= google.golang.org/protobuf v1.26.0/go.mod h1:9q0QmTI4eRPtz6boOQmLYwt+qCgq0jsYwAQnmE0givc= -google.golang.org/protobuf v1.30.0 h1:kPPoIgf3TsEvrm0PFe15JQ+570QVxYzEvvHqChK+cng= -google.golang.org/protobuf v1.30.0/go.mod h1:HV8QOd/L58Z+nl8r43ehVNZIU/HEI6OcFqwMG9pJV4I= +google.golang.org/protobuf v1.31.0 h1:g0LDEJHgrBl9N9r17Ru3sqWhkIx2NB67okBHPwC7hs8= +google.golang.org/protobuf v1.31.0/go.mod h1:HV8QOd/L58Z+nl8r43ehVNZIU/HEI6OcFqwMG9pJV4I= gopkg.in/alecthomas/kingpin.v2 v2.2.6/go.mod h1:FMv+mEhP44yOT+4EoQTLFTRgOQ1FBLkstjWtayDeSgw= gopkg.in/bsm/ratelimit.v1 v1.0.0-20160220154919-db14e161995a/go.mod h1:KF9sEfUPAXdG8Oev9e99iLGnl2uJMjc5B+4y3O7x610= gopkg.in/check.v1 v0.0.0-20161208181325-20d25e280405/go.mod h1:Co6ibVJAznAaIkqp8huTwlJQCZ016jof/cbN4VW5Yz0= @@ -1595,17 +1523,13 @@ gopkg.in/cheggaaa/pb.v1 v1.0.25/go.mod h1:V/YB90LKu/1FcN3WVnfiiE5oMCibMjukxqG/qS gopkg.in/errgo.v2 v2.1.0/go.mod h1:hNsd1EY+bozCKY1Ytp96fpM3vjJbqLJn88ws8XvfDNI= gopkg.in/fsnotify.v1 v1.4.7/go.mod h1:Tz8NjZHkW78fSQdbUxIjBTcgA1z1m8ZHf0WmKUhAMys= gopkg.in/gcfg.v1 v1.2.3/go.mod h1:yesOnuUOFQAhST5vPY4nbZsb/huCgGGXlipJsBn0b3o= -gopkg.in/go-playground/assert.v1 v1.2.1/go.mod h1:9RXL0bg/zibRAgZUYszZSwO/z8Y/a8bDuhia5mkpMnE= -gopkg.in/go-playground/validator.v8 v8.18.2/go.mod h1:RX2a/7Ha8BgOhfk7j780h4/u/RRjR0eouCJSH80/M2Y= gopkg.in/inf.v0 v0.9.1 h1:73M5CoZyi3ZLMOyDlQh031Cx6N9NDJ2Vvfl76EDAgDc= gopkg.in/inf.v0 v0.9.1/go.mod h1:cWUDdTG/fYaXco+Dcufb5Vnc6Gp2YChqWtbxRZE0mXw= -gopkg.in/ini.v1 v1.51.1/go.mod h1:pNLf8WUiyNEtQjuu5G5vTm06TEv9tsIgeAvK8hOrP4k= gopkg.in/jcmturner/aescts.v1 v1.0.1/go.mod h1:nsR8qBOg+OucoIW+WMhB3GspUQXq9XorLnQb9XtvcOo= gopkg.in/jcmturner/dnsutils.v1 v1.0.1/go.mod h1:m3v+5svpVOhtFAP/wSz+yzh4Mc0Fg7eRhxkJMWSIz9Q= gopkg.in/jcmturner/goidentity.v3 v3.0.0/go.mod h1:oG2kH0IvSYNIu80dVAyu/yoefjq1mNfM5bm88whjWx4= gopkg.in/jcmturner/gokrb5.v7 v7.5.0/go.mod h1:l8VISx+WGYp+Fp7KRbsiUuXTTOnxIc3Tuvyavf11/WM= gopkg.in/jcmturner/rpc.v1 v1.1.0/go.mod h1:YIdkC4XfD6GXbzje11McwsDuOlZQSb9W4vfLvuNnlv8= -gopkg.in/mgo.v2 v2.0.0-20180705113604-9856a29383ce/go.mod h1:yeKp02qBN3iKW1OzL3MGk2IdtZzaj7SFntXj72NppTA= 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/redis.v4 v4.2.4/go.mod h1:8KREHdypkCEojGKQcjMqAODMICIVwZAONWq8RowTITA= @@ -1623,7 +1547,6 @@ gopkg.in/yaml.v2 v2.2.8/go.mod h1:hI93XBmqTisBFMUTm0b8Fm+jr3Dg1NNxqwp+5A1VGuI= gopkg.in/yaml.v2 v2.3.0/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= -gopkg.in/yaml.v3 v3.0.0-20191120175047-4206685974f2/go.mod h1:K4uyk7z7BCEPqu6E+C64Yfv1cQ7kz7rIZviUmN+EgEM= gopkg.in/yaml.v3 v3.0.0-20200313102051-9f266ea9e77c/go.mod h1:K4uyk7z7BCEPqu6E+C64Yfv1cQ7kz7rIZviUmN+EgEM= gopkg.in/yaml.v3 v3.0.0-20200615113413-eeeca48fe776/go.mod h1:K4uyk7z7BCEPqu6E+C64Yfv1cQ7kz7rIZviUmN+EgEM= gopkg.in/yaml.v3 v3.0.0-20210107192922-496545a6307b/go.mod h1:K4uyk7z7BCEPqu6E+C64Yfv1cQ7kz7rIZviUmN+EgEM= diff --git a/internal/docker/nodes/docker-compose.yml b/internal/docker/nodes/docker-compose.yml index 62eee20a7..495e8912e 100644 --- a/internal/docker/nodes/docker-compose.yml +++ b/internal/docker/nodes/docker-compose.yml @@ -3,7 +3,7 @@ version: "3.9" services: l1_node: container_name: l1_node - image: ghcr.dockerproxy.com/foundry-rs/foundry:nightly-4a643801d0b3855934cdec778e33e79c79971783 + image: ghcr.io/foundry-rs/foundry:nightly-4a643801d0b3855934cdec778e33e79c79971783 restart: unless-stopped pull_policy: always ports: @@ -14,10 +14,12 @@ services: - "0.0.0.0" - --hardfork - cancun + - --block-time + - "1" l2_execution_engine: container_name: l2_node - image: gcr.dockerproxy.com/evmchain/taiko-geth:taiko + image: gcr.io/evmchain/taiko-geth:taiko restart: unless-stopped pull_policy: always volumes: diff --git a/internal/testutils/helper.go b/internal/testutils/helper.go index e8e11a49d..0a72da2d6 100644 --- a/internal/testutils/helper.go +++ b/internal/testutils/helper.go @@ -28,10 +28,6 @@ func (s *ClientTestSuite) ProposeInvalidTxListBytes(proposer Proposer) { invalidTxListBytes := RandomBytes(256) s.Nil(proposer.ProposeTxList(context.Background(), invalidTxListBytes, 1)) - for _, confirmCh := range proposer.GetSender().TxToConfirmChannels() { - confirm := <-confirmCh - s.Nil(confirm.Err) - } } func (s *ClientTestSuite) ProposeAndInsertEmptyBlocks( @@ -58,10 +54,6 @@ func (s *ClientTestSuite) ProposeAndInsertEmptyBlocks( s.Nil(err) s.Nil(proposer.ProposeTxList(context.Background(), encoded, 0)) - for _, confirmCh := range proposer.GetSender().TxToConfirmChannels() { - confirm := <-confirmCh - s.Nil(confirm.Err) - } s.ProposeInvalidTxListBytes(proposer) diff --git a/internal/testutils/interfaces.go b/internal/testutils/interfaces.go index ddc8b5e76..a6be5ef48 100644 --- a/internal/testutils/interfaces.go +++ b/internal/testutils/interfaces.go @@ -6,7 +6,6 @@ import ( "github.com/ethereum/go-ethereum/core/types" "github.com/taikoxyz/taiko-client/cmd/utils" - "github.com/taikoxyz/taiko-client/pkg/sender" ) type CalldataSyncer interface { @@ -22,5 +21,4 @@ type Proposer interface { txListBytes []byte, txNum uint, ) error - GetSender() *sender.Sender } diff --git a/pkg/flags/config.go b/pkg/flags/config.go new file mode 100644 index 000000000..b3be4ce92 --- /dev/null +++ b/pkg/flags/config.go @@ -0,0 +1,30 @@ +package flags + +import ( + "crypto/ecdsa" + + "github.com/ethereum-optimism/optimism/op-service/txmgr" + "github.com/ethereum/go-ethereum/common" + "github.com/ethereum/go-ethereum/crypto" + "github.com/taikoxyz/taiko-client/cmd/flags" + "github.com/urfave/cli/v2" +) + +// InitTxmgrConfigsFromCli initializes the transaction manager configs from the command line flags. +func InitTxmgrConfigsFromCli(l1Endpoint string, privateKey *ecdsa.PrivateKey, c *cli.Context) *txmgr.CLIConfig { + return &txmgr.CLIConfig{ + L1RPCURL: l1Endpoint, + PrivateKey: common.Bytes2Hex(crypto.FromECDSA(privateKey)), + NumConfirmations: c.Uint64(flags.NumConfirmations.Name), + SafeAbortNonceTooLowCount: c.Uint64(flags.SafeAbortNonceTooLowCount.Name), + FeeLimitMultiplier: c.Uint64(flags.FeeLimitMultiplier.Name), + FeeLimitThresholdGwei: c.Float64(flags.FeeLimitThreshold.Name), + MinBaseFeeGwei: c.Float64(flags.MinBaseFee.Name), + MinTipCapGwei: c.Float64(flags.MinTipCap.Name), + ResubmissionTimeout: c.Duration(flags.ResubmissionTimeout.Name), + NetworkTimeout: c.Duration(flags.RPCTimeout.Name), + ReceiptQueryInterval: c.Duration(flags.ReceiptQueryInterval.Name), + TxSendTimeout: c.Duration(flags.TxSendTimeout.Name), + TxNotInMempoolTimeout: c.Duration(flags.TxNotInMempoolTimeout.Name), + } +} diff --git a/pkg/rpc/beaconclient.go b/pkg/rpc/beaconclient.go index e231b7428..f69be6833 100644 --- a/pkg/rpc/beaconclient.go +++ b/pkg/rpc/beaconclient.go @@ -9,6 +9,7 @@ import ( "math/big" "time" + "github.com/ethereum-optimism/optimism/op-service/eth" "github.com/ethereum/go-ethereum/common" "github.com/ethereum/go-ethereum/crypto/kzg4844" "github.com/prysmaticlabs/prysm/v4/api/client" @@ -66,7 +67,7 @@ func (c *BeaconClient) GetBlobByHash(ctx context.Context, slot *big.Int, blobHas sha256.New(), &commitment, ) == blobHash { - blob := Blob(common.FromHex(sidecar.Blob)) + blob := eth.Blob(common.FromHex(sidecar.Blob)) return blob.ToData() } } diff --git a/pkg/rpc/blob.go b/pkg/rpc/blob.go deleted file mode 100644 index ee46faf25..000000000 --- a/pkg/rpc/blob.go +++ /dev/null @@ -1,291 +0,0 @@ -package rpc - -import ( - "crypto/sha256" - "errors" - "fmt" - "reflect" - - "github.com/ethereum/go-ethereum/common" - "github.com/ethereum/go-ethereum/common/hexutil" - "github.com/ethereum/go-ethereum/crypto/kzg4844" -) - -// Taken from: -// https://github.com/ethereum-optimism/optimism/blob/develop/op-service/eth/blob.go -const ( - BlobSize = 4096 * 32 - MaxBlobDataSize = (4*31+3)*1024 - 4 - EncodingVersion = 0 - VersionOffset = 1 // offset of the version byte in the blob encoding - Rounds = 1024 // number of encode/decode rounds - BlobTxHashVersion = 0x01 // Version byte of the commitment hash -) - -type Data = hexutil.Bytes - -var ( - ErrBlobInvalidFieldElement = errors.New("invalid field element") - ErrBlobInvalidEncodingVersion = errors.New("invalid encoding version") - ErrBlobInvalidLength = errors.New("invalid length for blob") - ErrBlobInputTooLarge = errors.New("too much data to encode in one blob") - ErrBlobExtraneousData = errors.New("non-zero data encountered where blob should be empty") - ErrBlobExtraneousDataFieldElement = errors.New("non-zero data encountered where field element should be empty") -) - -type Blob [BlobSize]byte - -func (b *Blob) KZGBlob() *kzg4844.Blob { - return (*kzg4844.Blob)(b) -} - -func (b *Blob) UnmarshalJSON(text []byte) error { - return hexutil.UnmarshalFixedJSON(reflect.TypeOf(b), text, b[:]) -} - -func (b *Blob) UnmarshalText(text []byte) error { - return hexutil.UnmarshalFixedText("Bytes32", text, b[:]) -} - -func (b *Blob) MarshalText() ([]byte, error) { - return hexutil.Bytes(b[:]).MarshalText() -} - -func (b *Blob) String() string { - return hexutil.Encode(b[:]) -} - -// TerminalString implements log.TerminalStringer, formatting a string for console -// output during logging. -func (b *Blob) TerminalString() string { - return fmt.Sprintf("%x..%x", b[:3], b[BlobSize-3:]) -} - -func (b *Blob) ComputeKZGCommitment() (kzg4844.Commitment, error) { - return kzg4844.BlobToCommitment(*b.KZGBlob()) -} - -// KZGToVersionedHash computes the "blob hash" (a.k.a. versioned-hash) of a blob-commitment, as used in a blob-tx. -// We implement it here because it is unfortunately not (currently) exposed by geth. -func KZGToVersionedHash(commitment kzg4844.Commitment) (out common.Hash) { - // EIP-4844 spec: - // def kzg_to_versioned_hash(commitment: KZGCommitment) -> VersionedHash: - // return VERSIONED_HASH_VERSION_KZG + sha256(commitment)[1:] - h := sha256.New() - h.Write(commitment[:]) - _ = h.Sum(out[:0]) - out[0] = BlobTxHashVersion - return out -} - -// VerifyBlobProof verifies that the given blob and proof corresponds to the given commitment, -// returning error if the verification fails. -func VerifyBlobProof(blob *Blob, commitment kzg4844.Commitment, proof kzg4844.Proof) error { - return kzg4844.VerifyBlobProof(*blob.KZGBlob(), commitment, proof) -} - -// FromData encodes the given input data into this blob. The encoding scheme is as follows: -// -// In each round we perform 7 reads of input of lengths (31,1,31,1,31,1,31) bytes respectively for -// a total of 127 bytes. This data is encoded into the next 4 field elements of the output by -// placing each of the 4x31 byte chunks into bytes [1:32] of its respective field element. The -// three single byte chunks (24 bits) are split into 4x6-bit chunks, each of which is written into -// the top most byte of its respective field element, leaving the top 2 bits of each field element -// empty to avoid modulus overflow. This process is repeated for up to 1024 rounds until all data -// is encoded. -// -// For only the very first output field, bytes [1:5] are used to encode the version and the length -// of the data. -func (b *Blob) FromData(data Data) error { - if len(data) > MaxBlobDataSize { - return fmt.Errorf("%w: len=%v", ErrBlobInputTooLarge, data) - } - b.Clear() - - readOffset := 0 - - // read 1 byte of input, 0 if there is no input left - read1 := func() byte { - if readOffset >= len(data) { - return 0 - } - out := data[readOffset] - readOffset++ - return out - } - - writeOffset := 0 - var buf31 [31]byte - var zero31 [31]byte - - // Read up to 31 bytes of input (left-aligned), into buf31. - read31 := func() { - if readOffset >= len(data) { - copy(buf31[:], zero31[:]) - return - } - n := copy(buf31[:], data[readOffset:]) // copy as much data as we can - copy(buf31[n:], zero31[:]) // pad with zeroes (since there might not be enough data) - readOffset += n - } - // Write a byte, updates the write-offset. - // Asserts that the write-offset matches encoding-algorithm expectations. - // Asserts that the value is 6 bits. - write1 := func(v byte) { - if writeOffset%32 != 0 { - panic(fmt.Errorf("blob encoding: invalid byte write offset: %d", writeOffset)) - } - if v&0b1100_0000 != 0 { - panic(fmt.Errorf("blob encoding: invalid 6 bit value: 0b%b", v)) - } - b[writeOffset] = v - writeOffset++ - } - // Write buf31 to the blob, updates the write-offset. - // Asserts that the write-offset matches encoding-algorithm expectations. - write31 := func() { - if writeOffset%32 != 1 { - panic(fmt.Errorf("blob encoding: invalid bytes31 write offset: %d", writeOffset)) - } - copy(b[writeOffset:], buf31[:]) - writeOffset += 31 - } - - for round := 0; round < Rounds && readOffset < len(data); round++ { - // The first field element encodes the version and the length of the data in [1:5]. - // This is a manual substitute for read31(), preparing the buf31. - if round == 0 { - buf31[0] = EncodingVersion - // Encode the length as big-endian uint24. - // The length check at the start above ensures we can always fit the length value into only 3 bytes. - ilen := uint32(len(data)) - buf31[1] = byte(ilen >> 16) - buf31[2] = byte(ilen >> 8) - buf31[3] = byte(ilen) - - readOffset += copy(buf31[4:], data[:]) - } else { - read31() - } - - x := read1() - A := x & 0b0011_1111 - write1(A) - write31() - - read31() - y := read1() - B := (y & 0b0000_1111) | ((x & 0b1100_0000) >> 2) - write1(B) - write31() - - read31() - z := read1() - C := z & 0b0011_1111 - write1(C) - write31() - - read31() - D := ((z & 0b1100_0000) >> 2) | ((y & 0b1111_0000) >> 4) - write1(D) - write31() - } - - if readOffset < len(data) { - panic(fmt.Errorf("expected to fit data but failed, read offset: %d, data: %d", readOffset, len(data))) - } - return nil -} - -// ToData decodes the blob into raw byte data. See FromData above for details on the encoding -// format. If error is returned it will be one of InvalidFieldElementError, -// InvalidEncodingVersionError and InvalidLengthError. -func (b *Blob) ToData() (Data, error) { - // check the version - if b[VersionOffset] != EncodingVersion { - return nil, fmt.Errorf( - "%w: expected version %d, got %d", ErrBlobInvalidEncodingVersion, EncodingVersion, b[VersionOffset]) - } - - // decode the 3-byte big-endian length value into a 4-byte integer - outputLen := uint32(b[2])<<16 | uint32(b[3])<<8 | uint32(b[4]) - if outputLen > MaxBlobDataSize { - return nil, fmt.Errorf("%w: got %d", ErrBlobInvalidLength, outputLen) - } - - // round 0 is special cased to copy only the remaining 27 bytes of the first field element into - // the output due to version/length encoding already occupying its first 5 bytes. - output := make(Data, MaxBlobDataSize) - copy(output[0:27], b[5:]) - - // now process remaining 3 field elements to complete round 0 - opos := 28 // current position into output buffer - ipos := 32 // current position into the input blob - var err error - encodedByte := make([]byte, 4) // buffer for the 4 6-bit chunks - encodedByte[0] = b[0] - for i := 1; i < 4; i++ { - encodedByte[i], opos, ipos, err = b.decodeFieldElement(opos, ipos, output) - if err != nil { - return nil, err - } - } - opos = reassembleBytes(opos, encodedByte, output) - - // in each remaining round we decode 4 field elements (128 bytes) of the input into 127 bytes - // of output - for i := 1; i < Rounds && opos < int(outputLen); i++ { - for j := 0; j < 4; j++ { - // save the first byte of each field element for later re-assembly - encodedByte[j], opos, ipos, err = b.decodeFieldElement(opos, ipos, output) - if err != nil { - return nil, err - } - } - opos = reassembleBytes(opos, encodedByte, output) - } - for i := int(outputLen); i < len(output); i++ { - if output[i] != 0 { - return nil, fmt.Errorf("fe=%d: %w", opos/32, ErrBlobExtraneousDataFieldElement) - } - } - output = output[:outputLen] - for ; ipos < BlobSize; ipos++ { - if b[ipos] != 0 { - return nil, fmt.Errorf("pos=%d: %w", ipos, ErrBlobExtraneousData) - } - } - return output, nil -} - -// decodeFieldElement decodes the next input field element by writing its lower 31 bytes into its -// appropriate place in the output and checking the high order byte is valid. Returns an -// InvalidFieldElementError if a field element is seen with either of its two high order bits set. -func (b *Blob) decodeFieldElement(opos, ipos int, output []byte) (byte, int, int, error) { - // two highest order bits of the first byte of each field element should always be 0 - if b[ipos]&0b1100_0000 != 0 { - return 0, 0, 0, fmt.Errorf("%w: field element: %d", ErrBlobInvalidFieldElement, ipos) - } - copy(output[opos:], b[ipos+1:ipos+32]) - return b[ipos], opos + 32, ipos + 32, nil -} - -// reassembleBytes takes the 4x6-bit chunks from encodedByte, reassembles them into 3 bytes of -// output, and places them in their appropriate output positions. -func reassembleBytes(opos int, encodedByte []byte, output []byte) int { - opos-- // account for fact that we don't output a 128th byte - x := (encodedByte[0] & 0b0011_1111) | ((encodedByte[1] & 0b0011_0000) << 2) - y := (encodedByte[1] & 0b0000_1111) | ((encodedByte[3] & 0b0000_1111) << 4) - z := (encodedByte[2] & 0b0011_1111) | ((encodedByte[3] & 0b0011_0000) << 2) - // put the re-assembled bytes in their appropriate output locations - output[opos-32] = z - output[opos-(32*2)] = y - output[opos-(32*3)] = x - return opos -} - -func (b *Blob) Clear() { - for i := 0; i < BlobSize; i++ { - b[i] = 0 - } -} diff --git a/pkg/rpc/blob_tx.go b/pkg/rpc/blob_tx.go index 2ba5ca856..97c7f0119 100644 --- a/pkg/rpc/blob_tx.go +++ b/pkg/rpc/blob_tx.go @@ -4,6 +4,7 @@ import ( "errors" "math/big" + "github.com/ethereum-optimism/optimism/op-service/eth" "github.com/ethereum/go-ethereum/accounts/abi/bind" "github.com/ethereum/go-ethereum/common" "github.com/ethereum/go-ethereum/common/hexutil" @@ -114,7 +115,7 @@ func (c *EthClient) CreateBlobTx( // MakeSidecar makes a sidecar which only includes one blob with the given data. func MakeSidecar(data []byte) (*types.BlobTxSidecar, error) { - var blob Blob + var blob eth.Blob if err := blob.FromData(data); err != nil { return nil, err } diff --git a/pkg/rpc/blob_tx_test.go b/pkg/rpc/blob_tx_test.go index 9b180086a..bcfb9103c 100644 --- a/pkg/rpc/blob_tx_test.go +++ b/pkg/rpc/blob_tx_test.go @@ -6,6 +6,7 @@ import ( "testing" "time" + "github.com/ethereum-optimism/optimism/op-service/eth" "github.com/ethereum/go-ethereum/accounts/abi/bind" "github.com/ethereum/go-ethereum/common" "github.com/ethereum/go-ethereum/common/hexutil" @@ -66,7 +67,7 @@ func TestMakeSideCar(t *testing.T) { sideCar, mErr := MakeSidecar(origin) assert.NoError(t, mErr) - blob := Blob(sideCar.Blobs[0]) + blob := eth.Blob(sideCar.Blobs[0]) origin1, dErr := blob.ToData() assert.NoError(t, dErr) assert.Equal(t, hexutil.Bytes(origin), origin1) diff --git a/pkg/rpc/ethclient_test.go b/pkg/rpc/ethclient_test.go index 6d8697211..e1087cbe2 100644 --- a/pkg/rpc/ethclient_test.go +++ b/pkg/rpc/ethclient_test.go @@ -48,11 +48,7 @@ func TestTransactionSender(t *testing.T) { block, err := client.L1.BlockByNumber(context.Background(), nil) require.Nil(t, err) - require.NotZero(t, block.Transactions().Len()) - - sender, err := client.L1.TransactionSender(context.Background(), block.Transactions()[0], block.Hash(), 0) - require.Nil(t, err) - require.NotEqual(t, common.Address{}, sender) + require.Zero(t, block.Transactions().Len()) } func TestTransactionCount(t *testing.T) { @@ -60,11 +56,7 @@ func TestTransactionCount(t *testing.T) { block, err := client.L1.BlockByNumber(context.Background(), nil) require.Nil(t, err) - require.NotZero(t, block.Transactions().Len()) - - c, err := client.L1.TransactionCount(context.Background(), block.Hash()) - require.Nil(t, err) - require.NotZero(t, c) + require.Zero(t, block.Transactions().Len()) } func TestTransactionInBlock(t *testing.T) { @@ -72,11 +64,10 @@ func TestTransactionInBlock(t *testing.T) { block, err := client.L1.BlockByNumber(context.Background(), nil) require.Nil(t, err) - require.NotZero(t, block.Transactions().Len()) + require.Zero(t, block.Transactions().Len()) - tx, err := client.L1.TransactionInBlock(context.Background(), block.Hash(), 0) - require.Nil(t, err) - require.NotEqual(t, common.Hash{}, tx.Hash()) + _, err = client.L1.TransactionInBlock(context.Background(), block.Hash(), 0) + require.NotNil(t, err) } func TestNetworkID(t *testing.T) { diff --git a/pkg/sender/common.go b/pkg/sender/common.go deleted file mode 100644 index 941b8e9a6..000000000 --- a/pkg/sender/common.go +++ /dev/null @@ -1,160 +0,0 @@ -package sender - -import ( - "fmt" - "math/big" - - "github.com/creasty/defaults" - "github.com/ethereum/go-ethereum/common" - "github.com/ethereum/go-ethereum/core/types" - "github.com/ethereum/go-ethereum/log" - "github.com/holiman/uint256" - - "github.com/taikoxyz/taiko-client/internal/utils" -) - -// AdjustGasFee adjusts the gas fee cap and gas tip cap of the given transaction with the configured -// growth rate. -func (s *Sender) AdjustGasFee(txData types.TxData) { - rate := s.GasGrowthRate - switch baseTx := txData.(type) { - case *types.DynamicFeeTx: - gasFeeCap := baseTx.GasFeeCap.Int64() - gasFeeCap += gasFeeCap * int64(rate) / 100 - baseTx.GasFeeCap = big.NewInt(utils.Min(gasFeeCap, int64(s.MaxGasFee))) - - gasTipCap := baseTx.GasTipCap.Int64() - gasTipCap += gasTipCap * int64(rate) / 100 - gasTipCap = utils.Min(gasFeeCap, utils.Min(gasTipCap, int64(s.MaxGasFee))) - baseTx.GasTipCap = big.NewInt(gasTipCap) - case *types.BlobTx: - gasFeeCap := baseTx.GasFeeCap.Uint64() - gasFeeCap += gasFeeCap * rate / 100 - baseTx.GasFeeCap = uint256.NewInt(utils.Min(gasFeeCap, s.MaxGasFee)) - - gasTipCap := baseTx.GasTipCap.Uint64() - gasTipCap += gasTipCap * rate / 100 - gasTipCap = utils.Min(gasFeeCap, utils.Min(gasTipCap, s.MaxGasFee)) - baseTx.GasTipCap = uint256.NewInt(gasTipCap) - default: - log.Warn("Unsupported transaction type when adjust gasFeeCap and gasTipCap", "from", s.opts.From) - } -} - -// AdjustBlobGasFee adjusts the gas fee cap and gas tip cap of the given transaction with the configured. -func (s *Sender) AdjustBlobGasFee(txData types.TxData) { - rate := s.GasGrowthRate + 100 - switch baseTx := txData.(type) { - case *types.BlobTx: - blobFeeCap := baseTx.BlobFeeCap.Uint64() - // Use Max check is to catch is situation: +1 is necessary, if blobFeeCap can't increase. - blobFeeCap = utils.Max(blobFeeCap*rate/100, blobFeeCap+1) - blobFeeCap = utils.Min(blobFeeCap, s.MaxBlobFee) - baseTx.BlobFeeCap = uint256.NewInt(blobFeeCap) - default: - log.Warn("Unsupported transaction type when adjust blobGasFeeCap", "from", s.opts.From) - } -} - -// SetNonce adjusts the nonce of the given transaction with the current nonce of the sender. -func (s *Sender) SetNonce(txData types.TxData, adjust bool) (err error) { - var nonce uint64 - if adjust { - s.nonce, err = s.client.NonceAt(s.ctx, s.opts.From, nil) - if err != nil { - log.Warn("Failed to get the nonce", "from", s.opts.From, "err", err) - return err - } - } - nonce = s.nonce - - if !utils.IsNil(txData) { - switch tx := txData.(type) { - case *types.DynamicFeeTx: - tx.Nonce = nonce - case *types.BlobTx: - tx.Nonce = nonce - case *types.LegacyTx: - tx.Nonce = nonce - case *types.AccessListTx: - tx.Nonce = nonce - default: - return fmt.Errorf("unsupported transaction type: %v", txData) - } - } - return -} - -// updateGasTipGasFee updates the gas tip cap and gas fee cap of the sender with the given chain head info. -func (s *Sender) updateGasTipGasFee(head *types.Header) error { - // Get the gas tip cap - gasTipCap, err := s.client.SuggestGasTipCap(s.ctx) - if err != nil { - return err - } - - // Get the gas fee cap - gasFeeCap := new(big.Int).Add(gasTipCap, new(big.Int).Mul(head.BaseFee, big.NewInt(2))) - // Check if the gas fee cap is less than the gas tip cap - if gasFeeCap.Cmp(gasTipCap) < 0 { - return fmt.Errorf("maxFeePerGas (%v) < maxPriorityFeePerGas (%v)", gasFeeCap, gasTipCap) - } - maxGasFee := new(big.Int).SetUint64(s.MaxGasFee) - if gasFeeCap.Cmp(maxGasFee) > 0 { - gasFeeCap = new(big.Int).Set(maxGasFee) - gasTipCap = new(big.Int).Set(maxGasFee) - } - - s.opts.GasTipCap = gasTipCap - s.opts.GasFeeCap = gasFeeCap - - return nil -} - -// buildTxData assembles the transaction data from the given transaction. -func (s *Sender) buildTxData(tx *types.Transaction) (types.TxData, error) { - switch tx.Type() { - case types.DynamicFeeTxType: - return &types.DynamicFeeTx{ - ChainID: s.client.ChainID, - To: tx.To(), - Nonce: tx.Nonce(), - GasFeeCap: s.opts.GasFeeCap, - GasTipCap: s.opts.GasTipCap, - Gas: tx.Gas(), - Value: tx.Value(), - Data: tx.Data(), - AccessList: tx.AccessList(), - }, nil - case types.BlobTxType: - var to common.Address - if tx.To() != nil { - to = *tx.To() - } - return &types.BlobTx{ - ChainID: uint256.MustFromBig(s.client.ChainID), - To: to, - Nonce: tx.Nonce(), - GasFeeCap: uint256.MustFromBig(s.opts.GasFeeCap), - GasTipCap: uint256.MustFromBig(s.opts.GasTipCap), - Gas: tx.Gas(), - Value: uint256.MustFromBig(tx.Value()), - Data: tx.Data(), - AccessList: tx.AccessList(), - BlobFeeCap: uint256.MustFromBig(tx.BlobGasFeeCap()), - BlobHashes: tx.BlobHashes(), - Sidecar: tx.BlobTxSidecar(), - }, nil - default: - return nil, fmt.Errorf("unsupported transaction type: %v", tx.Type()) - } -} - -// setConfigWithDefaultValues sets the config with default values if the given config is nil. -func setConfigWithDefaultValues(config *Config) *Config { - if config == nil { - config = new(Config) - } - _ = defaults.Set(config) - return config -} diff --git a/pkg/sender/common_test.go b/pkg/sender/common_test.go deleted file mode 100644 index b9ea812f2..000000000 --- a/pkg/sender/common_test.go +++ /dev/null @@ -1,21 +0,0 @@ -package sender - -import ( - "math" - "testing" - "time" - - "github.com/stretchr/testify/assert" -) - -func TestSetConfigWithDefaultValues(t *testing.T) { - cfg := setConfigWithDefaultValues(&Config{MaxRetrys: 1, MaxBlobFee: 1024}) - assert.Equal(t, uint64(50), cfg.GasGrowthRate) - assert.Equal(t, uint64(1), cfg.MaxRetrys) - assert.Equal(t, 5*time.Minute, cfg.MaxWaitingTime) - assert.Equal(t, uint64(math.MaxUint64), cfg.MaxGasFee) - assert.Equal(t, uint64(1024), cfg.MaxBlobFee) - - cfg = setConfigWithDefaultValues(nil) - assert.Equal(t, cfg.GasGrowthRate, uint64(50)) -} diff --git a/pkg/sender/sender.go b/pkg/sender/sender.go deleted file mode 100644 index 529bd28be..000000000 --- a/pkg/sender/sender.go +++ /dev/null @@ -1,536 +0,0 @@ -package sender - -import ( - "context" - "crypto/ecdsa" - "errors" - "fmt" - "math/big" - "os" - "strings" - "sync" - "time" - - "github.com/ethereum/go-ethereum" - "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/log" - cmap "github.com/orcaman/concurrent-map/v2" - "github.com/pborman/uuid" - - "github.com/taikoxyz/taiko-client/internal/metrics" - "github.com/taikoxyz/taiko-client/pkg/rpc" -) - -var ( - sendersMap = map[uint64]map[common.Address]*Sender{} - unconfirmedTxsCap = 100 - nonceIncorrectRetrys = 3 - unconfirmedTxsCheckInternal = 2 * time.Second - chainHeadFetchInterval = 3 * time.Second - errTimeoutInMempool = errors.New("transaction in mempool for too long") - errToManyPendings = errors.New("too many pending transactions") -) - -// Config represents the configuration of the transaction sender. -type Config struct { - // The minimum block confirmations to wait to confirm a transaction. - ConfirmationDepth uint64 `default:"0"` - // The maximum retry times when sending transactions. - MaxRetrys uint64 `default:"0"` - // The maximum waiting time for the inclusion of transactions. - MaxWaitingTime time.Duration `default:"5m"` - // The gas limit for transactions. - GasLimit uint64 `default:"0"` - // The gas rate to increase the gas price, 20 means 20% gas growth rate. - GasGrowthRate uint64 `default:"50"` - // The maximum gas fee can be used when sending transactions. - MaxGasFee uint64 `default:"0xffffffffffffffff"` // Use `math.MaxUint64` as default value - // The maximum blob gas fee can be used when sending transactions. - MaxBlobFee uint64 `default:"0xffffffffffffffff"` // Use `math.MaxUint64` as default value -} - -// TxToConfirm represents a transaction which is waiting for its confirmation. -type TxToConfirm struct { - confirmations uint64 - originalTx types.TxData - - ID string - Retrys uint64 - CurrentTx *types.Transaction - Receipt *types.Receipt - CreatedAt time.Time - - Err error -} - -// Sender represents a global transaction sender. -type Sender struct { - ctx context.Context - *Config - - head *types.Header - client *rpc.EthClient - - nonce uint64 - opts *bind.TransactOpts - - unconfirmedTxs cmap.ConcurrentMap[string, *TxToConfirm] - txToConfirmCh cmap.ConcurrentMap[string, chan *TxToConfirm] - - mu sync.Mutex - wg sync.WaitGroup - stopCh chan struct{} -} - -// NewSender creates a new instance of Sender. -func NewSender(ctx context.Context, cfg *Config, client *rpc.EthClient, priv *ecdsa.PrivateKey) (*Sender, error) { - cfg = setConfigWithDefaultValues(cfg) - - // Create a new transactor - opts, err := bind.NewKeyedTransactorWithChainID(priv, client.ChainID) - if err != nil { - return nil, err - } - // Do not automatically send transactions - opts.NoSend = true - opts.GasLimit = cfg.GasLimit - - // Add the sender to the root sender. - if root := sendersMap[client.ChainID.Uint64()]; root == nil { - sendersMap[client.ChainID.Uint64()] = map[common.Address]*Sender{} - } else { - if root[opts.From] != nil { - return nil, fmt.Errorf("sender already exists") - } - } - - // Get the nonce - nonce, err := client.NonceAt(ctx, opts.From, nil) - if err != nil { - return nil, err - } - - // Get the chain ID - head, err := client.HeaderByNumber(ctx, nil) - if err != nil { - return nil, err - } - - sender := &Sender{ - ctx: ctx, - Config: cfg, - head: head, - client: client, - nonce: nonce, - opts: opts, - unconfirmedTxs: cmap.New[*TxToConfirm](), - txToConfirmCh: cmap.New[chan *TxToConfirm](), - stopCh: make(chan struct{}), - } - - // Initialize the gas fee related fields - if err = sender.updateGasTipGasFee(head); err != nil { - return nil, err - } - if os.Getenv("RUN_TESTS") == "" { - sendersMap[client.ChainID.Uint64()][opts.From] = sender - } - - sender.wg.Add(1) - go sender.loop() - - return sender, nil -} - -// Close closes the sender. -func (s *Sender) Close() { - close(s.stopCh) - s.wg.Wait() -} - -// GetOpts returns the transaction options of the sender. -func (s *Sender) GetOpts(ctx context.Context) *bind.TransactOpts { - return &bind.TransactOpts{ - From: s.opts.From, - Nonce: s.opts.Nonce, - Signer: s.opts.Signer, - Value: s.opts.Value, - GasPrice: s.opts.GasPrice, - GasFeeCap: s.opts.GasFeeCap, - GasTipCap: s.opts.GasTipCap, - GasLimit: s.opts.GasLimit, - Context: ctx, - NoSend: s.opts.NoSend, - } -} - -// Address returns the sender's address. -func (s *Sender) Address() common.Address { - return s.opts.From -} - -// TxToConfirmChannel returns a channel to wait the given transaction's confirmation. -func (s *Sender) TxToConfirmChannel(txID string) <-chan *TxToConfirm { - ch, ok := s.txToConfirmCh.Get(txID) - if !ok { - log.Warn("Transaction not found", "id", txID) - } - return ch -} - -// TxToConfirmChannels returns channels to wait the given transactions confirmation. -func (s *Sender) TxToConfirmChannels() map[string]<-chan *TxToConfirm { - channels := map[string]<-chan *TxToConfirm{} - for txID, confirmCh := range s.txToConfirmCh.Items() { - channels[txID] = confirmCh - } - return channels -} - -// GetUnconfirmedTx returns the unconfirmed transaction by the transaction ID. -func (s *Sender) GetUnconfirmedTx(txID string) *types.Transaction { - txToConfirm, ok := s.unconfirmedTxs.Get(txID) - if !ok { - return nil - } - return txToConfirm.CurrentTx -} - -// SendRawTransaction sends a transaction to the given Ethereum node. -func (s *Sender) SendRawTransaction( - ctx context.Context, - nonce uint64, - target *common.Address, - value *big.Int, - data []byte, - sidecar *types.BlobTxSidecar, -) (string, error) { - // If there are too many pending transactions to be confirmed, return an error here. - if s.unconfirmedTxs.Count() >= unconfirmedTxsCap { - return "", errToManyPendings - } - if nonce == 0 { - nonce = s.nonce - } - - var ( - originalTx types.TxData - opts = s.GetOpts(ctx) - gasLimit = s.GasLimit - err error - ) - if sidecar != nil { - opts.Value = value - if target == nil { - target = &common.Address{} - } - blobTx, err := s.client.CreateBlobTx(opts, *target, data, sidecar) - if err != nil { - return "", err - } - blobTx.Nonce = nonce - originalTx = blobTx - } else { - if gasLimit == 0 { - if gasLimit, err = s.client.EstimateGas(s.ctx, ethereum.CallMsg{ - From: opts.From, - To: target, - Value: value, - Data: data, - GasTipCap: opts.GasTipCap, - GasFeeCap: opts.GasFeeCap, - }); err != nil { - return "", err - } - } - - originalTx = &types.DynamicFeeTx{ - ChainID: s.client.ChainID, - To: target, - Nonce: nonce, - GasFeeCap: opts.GasFeeCap, - GasTipCap: opts.GasTipCap, - Gas: gasLimit, - Value: value, - Data: data, - } - } - - txToConfirm := &TxToConfirm{originalTx: originalTx} - - if err := s.send(txToConfirm, false); err != nil && !strings.Contains(err.Error(), "replacement transaction") { - log.Error( - "Failed to send transaction", - "txId", txToConfirm.ID, - "nonce", nonce, - "err", err, - ) - return "", err - } - - txID := txToConfirm.ID - // Add the transaction to the unconfirmed transactions - s.unconfirmedTxs.Set(txID, txToConfirm) - s.txToConfirmCh.Set(txID, make(chan *TxToConfirm, 1)) - - return txID, nil -} - -// SendTransaction sends a transaction to the given Ethereum node. -func (s *Sender) SendTransaction(tx *types.Transaction) (string, error) { - if s.unconfirmedTxs.Count() >= unconfirmedTxsCap { - return "", errToManyPendings - } - - txData, err := s.buildTxData(tx) - if err != nil { - return "", err - } - - txToConfirm := &TxToConfirm{originalTx: txData, CurrentTx: tx} - - if err = s.send(txToConfirm, true); err != nil && !strings.Contains(err.Error(), "replacement transaction") { - log.Error( - "Failed to send transaction", - "txId", txToConfirm.ID, - "hash", tx.Hash(), - "err", err, - ) - return "", err - } - - txID := txToConfirm.ID - // Add the transaction to the unconfirmed transactions - s.unconfirmedTxs.Set(txID, txToConfirm) - s.txToConfirmCh.Set(txID, make(chan *TxToConfirm, 1)) - - return txID, nil -} - -// send is the internal method to send the real transaction. -func (s *Sender) send(tx *TxToConfirm, resetNonce bool) error { - s.mu.Lock() - defer s.mu.Unlock() - - // Set the transaction ID and its creation time - if tx.ID == "" { - tx.ID = uuid.New() - tx.CreatedAt = time.Now() - } - - originalTx := tx.originalTx - - if resetNonce { - // Set the nonce of the transaction. - if err := s.SetNonce(originalTx, false); err != nil { - return err - } - } - - for i := 0; i < nonceIncorrectRetrys; i++ { - // Retry when nonce is incorrect - rawTx, err := s.opts.Signer(s.opts.From, types.NewTx(originalTx)) - if err != nil { - return err - } - tx.CurrentTx = rawTx - err = s.client.SendTransaction(s.ctx, rawTx) - tx.Err = err - // Check if the error is nonce too low - if err != nil { - if strings.Contains(err.Error(), "nonce too low") { - if err := s.SetNonce(originalTx, true); err != nil { - log.Error( - "Failed to set nonce when appear nonce too low", - "txId", tx.ID, - "nonce", tx.CurrentTx.Nonce(), - "hash", rawTx.Hash(), - "err", err, - ) - } else { - log.Warn( - "Nonce is incorrect, retry sending the transaction with new nonce", - "txId", tx.ID, - "nonce", tx.CurrentTx.Nonce(), - "hash", rawTx.Hash(), - "err", err, - ) - } - continue - } - // handle the list: - // ErrUnderpriced: "transaction underpriced" - // ErrReplaceUnderpriced: "replacement transaction underpriced" - // blob tx err at https://github.com/ethereum/go-ethereum/blob/ - // 20d3e0ac06ef2ad2f5f6500402edc5b6f0bf5b7c/core/txpool/blobpool/blobpool.go#L1157` - if strings.Contains(err.Error(), "transaction underpriced") { - if strings.Contains(err.Error(), "new tx blob gas fee cap") { - s.AdjustBlobGasFee(originalTx) - } else { - s.AdjustGasFee(originalTx) - } - log.Warn( - "Replacement transaction underpriced", - "txId", tx.ID, - "nonce", tx.CurrentTx.Nonce(), - "hash", rawTx.Hash(), - "err", err, - ) - continue - } - log.Error( - "Failed to send transaction", - "txId", tx.ID, - "nonce", tx.CurrentTx.Nonce(), - "hash", rawTx.Hash(), - "err", err, - ) - return err - } - - metrics.TxSenderSentCounter.Inc(1) - break - } - s.nonce++ - return nil -} - -// loop is the main event loop of the transaction sender. -func (s *Sender) loop() { - defer s.wg.Done() - - chainHeadFetchTicker := time.NewTicker(chainHeadFetchInterval) - defer chainHeadFetchTicker.Stop() - - unconfirmedTxsCheckTicker := time.NewTicker(unconfirmedTxsCheckInternal) - defer unconfirmedTxsCheckTicker.Stop() - - for { - select { - case <-s.ctx.Done(): - return - case <-s.stopCh: - return - case <-unconfirmedTxsCheckTicker.C: - s.resendUnconfirmedTxs() - case <-chainHeadFetchTicker.C: - newHead, err := s.client.HeaderByNumber(s.ctx, nil) - if err != nil { - log.Error("Failed to get the latest header", "err", err) - continue - } - if s.head.Hash() == newHead.Hash() { - continue - } - s.head = newHead - // Update the gas tip and gas fee - if err = s.updateGasTipGasFee(newHead); err != nil { - log.Warn("Failed to update gas tip and gas fee", "err", err) - } - // Check the unconfirmed transactions - s.checkPendingTransactionsConfirmation() - } - } -} - -// resendUnconfirmedTxs resends all unconfirmed transactions. -func (s *Sender) resendUnconfirmedTxs() { - for id, unconfirmedTx := range s.unconfirmedTxs.Items() { - if unconfirmedTx.Err == nil { - continue - } - unconfirmedTx.Retrys++ - if s.MaxRetrys != 0 && unconfirmedTx.Retrys >= s.MaxRetrys { - s.releaseUnconfirmedTx(id) - continue - } - if err := s.send(unconfirmedTx, true); err != nil { - metrics.TxSenderUnconfirmedCounter.Inc(1) - log.Warn( - "Failed to resend the transaction", - "txId", id, - "nonce", unconfirmedTx.CurrentTx.Nonce(), - "hash", unconfirmedTx.CurrentTx.Hash(), - "retrys", unconfirmedTx.Retrys, - "err", err, - ) - } - } -} - -// checkPendingTransactionsConfirmation checks the confirmation of the pending transactions. -func (s *Sender) checkPendingTransactionsConfirmation() { - for id, pendingTx := range s.unconfirmedTxs.Items() { - if pendingTx.Err != nil { - continue - } - if pendingTx.Receipt == nil { - // Ignore the transaction if it is pending. - tx, isPending, err := s.client.TransactionByHash(s.ctx, pendingTx.CurrentTx.Hash()) - if err != nil { - log.Warn( - "Failed to fetch transaction", - "txId", pendingTx.ID, - "nonce", pendingTx.CurrentTx.Nonce(), - "hash", pendingTx.CurrentTx.Hash(), - "err", err, - ) - continue - } - if isPending { - // If the transaction is in mempool for too long, replace it. - if time.Since(tx.Time()) > s.MaxWaitingTime { - pendingTx.Err = errTimeoutInMempool - } - continue - } - // Get the transaction receipt. - receipt, err := s.client.TransactionReceipt(s.ctx, pendingTx.CurrentTx.Hash()) - if err != nil { - if err.Error() == "not found" { - pendingTx.Err = err - s.releaseUnconfirmedTx(id) - } - log.Warn("Failed to get the transaction receipt", "hash", pendingTx.CurrentTx.Hash(), "err", err) - continue - } - - // Record the gas fee metrics. - if receipt.BlobGasUsed == 0 { - metrics.TxSenderGasPriceGauge.Update(receipt.EffectiveGasPrice.Int64()) - } else { - metrics.TxSenderBlobGasPriceGauge.Update(receipt.BlobGasPrice.Int64()) - } - - metrics.TxSenderTxIncludedTimeGauge.Update(int64(time.Since(pendingTx.CreatedAt).Seconds())) - - pendingTx.Receipt = receipt - if receipt.Status != types.ReceiptStatusSuccessful { - pendingTx.Err = fmt.Errorf("transaction status is failed, hash: %s", receipt.TxHash) - metrics.TxSenderConfirmedFailedCounter.Inc(1) - s.releaseUnconfirmedTx(id) - continue - } - } - pendingTx.confirmations = s.head.Number.Uint64() - pendingTx.Receipt.BlockNumber.Uint64() - if pendingTx.confirmations >= s.ConfirmationDepth { - metrics.TxSenderConfirmedSuccessfulCounter.Inc(1) - s.releaseUnconfirmedTx(id) - } - } -} - -// releaseUnconfirmedTx releases the unconfirmed transaction by the transaction ID. -func (s *Sender) releaseUnconfirmedTx(txID string) { - txConfirm, _ := s.unconfirmedTxs.Get(txID) - confirmCh, _ := s.txToConfirmCh.Get(txID) - select { - case confirmCh <- txConfirm: - default: - } - // Remove the transaction from the unconfirmed transactions - s.unconfirmedTxs.Remove(txID) - s.txToConfirmCh.Remove(txID) -} diff --git a/pkg/sender/sender_test.go b/pkg/sender/sender_test.go deleted file mode 100644 index e68689d0e..000000000 --- a/pkg/sender/sender_test.go +++ /dev/null @@ -1,232 +0,0 @@ -package sender_test - -import ( - "context" - "math/big" - "os" - "runtime" - "testing" - "time" - - "github.com/ethereum/go-ethereum/common" - "github.com/ethereum/go-ethereum/core/types" - "github.com/ethereum/go-ethereum/crypto" - "github.com/holiman/uint256" - "github.com/stretchr/testify/suite" - "golang.org/x/sync/errgroup" - - "github.com/taikoxyz/taiko-client/internal/testutils" - "github.com/taikoxyz/taiko-client/internal/utils" - "github.com/taikoxyz/taiko-client/pkg/sender" -) - -type SenderTestSuite struct { - testutils.ClientTestSuite - sender *sender.Sender -} - -func (s *SenderTestSuite) TestSendTransaction() { - var ( - opts = s.sender.GetOpts(context.Background()) - client = s.RPCClient.L1 - eg errgroup.Group - ) - eg.SetLimit(runtime.NumCPU()) - for i := 0; i < 8; i++ { - i := i - eg.Go(func() error { - to := common.BigToAddress(big.NewInt(int64(i))) - tx := types.NewTx(&types.DynamicFeeTx{ - ChainID: client.ChainID, - To: &to, - GasFeeCap: opts.GasFeeCap, - GasTipCap: opts.GasTipCap, - Gas: 21000000, - Value: big.NewInt(1), - Data: nil, - }) - - _, err := s.sender.SendTransaction(tx) - return err - }) - } - s.Nil(eg.Wait()) - - for _, confirmCh := range s.sender.TxToConfirmChannels() { - confirm := <-confirmCh - s.Nil(confirm.Err) - } -} - -func (s *SenderTestSuite) TestSendRawTransaction() { - nonce, err := s.RPCClient.L1.NonceAt(context.Background(), s.sender.Address(), nil) - s.Nil(err) - - var eg errgroup.Group - eg.SetLimit(runtime.NumCPU()) - for i := 0; i < 5; i++ { - i := i - eg.Go(func() error { - addr := common.BigToAddress(big.NewInt(int64(i))) - _, err := s.sender.SendRawTransaction( - context.Background(), - nonce+uint64(i), - &addr, - big.NewInt(1), - nil, - nil, - ) - return err - }) - } - s.Nil(eg.Wait()) - - for _, confirmCh := range s.sender.TxToConfirmChannels() { - confirm := <-confirmCh - s.Nil(confirm.Err) - } -} - -// Test touch max gas price and replacement. -func (s *SenderTestSuite) TestReplacement() { - send := s.sender - client := s.RPCClient.L1 - opts := send.GetOpts(context.Background()) - - // Let max gas price be 2 times of the gas fee cap. - send.MaxGasFee = opts.GasFeeCap.Uint64() * 2 - - nonce, err := client.NonceAt(context.Background(), opts.From, nil) - s.Nil(err) - - pendingNonce, err := client.PendingNonceAt(context.Background(), opts.From) - s.Nil(err) - // Run test only if mempool has no pending transactions. - if pendingNonce > nonce { - return - } - - nonce++ - baseTx := &types.DynamicFeeTx{ - ChainID: client.ChainID, - To: &common.Address{}, - GasFeeCap: big.NewInt(int64(send.MaxGasFee - 1)), - GasTipCap: big.NewInt(int64(send.MaxGasFee - 1)), - Nonce: nonce, - Gas: 21000, - Value: big.NewInt(1), - Data: nil, - } - rawTx, err := opts.Signer(opts.From, types.NewTx(baseTx)) - s.Nil(err) - err = client.SendTransaction(context.Background(), rawTx) - s.Nil(err) - - ctx := context.Background() - // Replace the transaction with a higher nonce. - _, err = send.SendRawTransaction(ctx, nonce, &common.Address{}, big.NewInt(1), nil, nil) - s.Nil(err) - - time.Sleep(time.Second * 6) - // Send a transaction with a next nonce and let all the transactions be confirmed. - _, err = send.SendRawTransaction(ctx, nonce-1, &common.Address{}, big.NewInt(1), nil, nil) - s.Nil(err) - - for _, confirmCh := range send.TxToConfirmChannels() { - confirm := <-confirmCh - // Check the replaced transaction's gasFeeTap touch the max gas price. - if confirm.CurrentTx.Nonce() == nonce { - s.Equal(send.MaxGasFee, confirm.CurrentTx.GasFeeCap().Uint64()) - } - s.Nil(confirm.Err) - } - - _, err = client.TransactionReceipt(context.Background(), rawTx.Hash()) - s.Equal("not found", err.Error()) -} - -// Test nonce too low. -func (s *SenderTestSuite) TestNonceTooLow() { - client := s.RPCClient.L1 - send := s.sender - opts := s.sender.GetOpts(context.Background()) - - nonce, err := client.NonceAt(context.Background(), opts.From, nil) - s.Nil(err) - pendingNonce, err := client.PendingNonceAt(context.Background(), opts.From) - s.Nil(err) - // Run test only if mempool has no pending transactions. - if pendingNonce > nonce { - return - } - - txID, err := send.SendRawTransaction( - context.Background(), - nonce-3, - &common.Address{}, - big.NewInt(1), - nil, - nil, - ) - s.Nil(err) - confirm := <-send.TxToConfirmChannel(txID) - s.Nil(confirm.Err) - s.Equal(nonce, confirm.CurrentTx.Nonce()) -} - -func (s *SenderTestSuite) TestAdjustGas() { - send := s.sender - dynamicTx := &types.DynamicFeeTx{} - blobTx := &types.BlobTx{} - - for _, val := range []uint64{1, 20, 50, 100, 200, 1000, 10000, 20000} { - expectGasFeeCap := val + val*(send.GasGrowthRate)/100 - expectGasTipCap := val + val*(send.GasGrowthRate)/100 - expectGasTipCap = utils.Min(expectGasFeeCap, utils.Min(expectGasTipCap, send.MaxGasFee)) - - dynamicTx.GasFeeCap = new(big.Int).SetUint64(val) - dynamicTx.GasTipCap = new(big.Int).SetUint64(val) - send.AdjustGasFee(dynamicTx) - s.Equal(expectGasFeeCap, dynamicTx.GasFeeCap.Uint64(), "val: %d", val) - s.Equal(expectGasTipCap, dynamicTx.GasTipCap.Uint64(), "val: %d", val) - - blobTx.GasFeeCap = uint256.NewInt(val) - blobTx.GasTipCap = uint256.NewInt(val) - send.AdjustGasFee(blobTx) - s.Equal(expectGasFeeCap, blobTx.GasFeeCap.Uint64(), "val: %d", val) - s.Equal(expectGasTipCap, blobTx.GasTipCap.Uint64(), "val: %d", val) - - expectGasTipCap = utils.Max(val*(send.GasGrowthRate+100)/100, val+1) - blobTx.BlobFeeCap = uint256.NewInt(val) - send.AdjustBlobGasFee(blobTx) - s.Equal(expectGasTipCap, blobTx.BlobFeeCap.Uint64(), "val: %d", val) - } -} - -func (s *SenderTestSuite) SetupTest() { - s.ClientTestSuite.SetupTest() - s.SetL1Automine(true) - - ctx := context.Background() - priv, err := crypto.ToECDSA(common.FromHex(os.Getenv("L1_PROPOSER_PRIVATE_KEY"))) - s.Nil(err) - - s.sender, err = sender.NewSender(ctx, &sender.Config{ - MaxGasFee: 20000000000, - GasGrowthRate: 50, - MaxRetrys: 0, - GasLimit: 2000000, - MaxWaitingTime: time.Second * 10, - }, s.RPCClient.L1, priv) - s.Nil(err) -} - -func (s *SenderTestSuite) TearDownTest() { - s.SetL1Automine(false) - s.sender.Close() - s.ClientTestSuite.TearDownTest() -} - -func TestSenderTestSuite(t *testing.T) { - suite.Run(t, new(SenderTestSuite)) -} diff --git a/proposer/config.go b/proposer/config.go index a3fc9562f..65fc0c9a0 100644 --- a/proposer/config.go +++ b/proposer/config.go @@ -8,38 +8,39 @@ import ( "strings" "time" + "github.com/ethereum-optimism/optimism/op-service/txmgr" "github.com/ethereum/go-ethereum/common" "github.com/ethereum/go-ethereum/crypto" "github.com/urfave/cli/v2" "github.com/taikoxyz/taiko-client/cmd/flags" + pkgFlags "github.com/taikoxyz/taiko-client/pkg/flags" "github.com/taikoxyz/taiko-client/pkg/rpc" ) // Config contains all configurations to initialize a Taiko proposer. type Config struct { *rpc.ClientConfig - AssignmentHookAddress common.Address - L1ProposerPrivKey *ecdsa.PrivateKey - L2SuggestedFeeRecipient common.Address - ExtraData string - ProposeInterval time.Duration - LocalAddresses []common.Address - LocalAddressesOnly bool - ProposeEmptyBlocksInterval time.Duration - MaxProposedTxListsPerEpoch uint64 - ProposeBlockTxGasLimit uint64 - ProposeBlockTxReplacementMultiplier uint64 - WaitReceiptTimeout time.Duration - ProposeBlockTxGasTipCap *big.Int - ProverEndpoints []*url.URL - OptimisticTierFee *big.Int - SgxTierFee *big.Int - TierFeePriceBump *big.Int - MaxTierFeePriceBumps uint64 - IncludeParentMetaHash bool - BlobAllowed bool - L1BlockBuilderTip *big.Int + AssignmentHookAddress common.Address + L1ProposerPrivKey *ecdsa.PrivateKey + L2SuggestedFeeRecipient common.Address + ExtraData string + ProposeInterval time.Duration + LocalAddresses []common.Address + LocalAddressesOnly bool + ProposeEmptyBlocksInterval time.Duration + MaxProposedTxListsPerEpoch uint64 + ProposeBlockTxGasLimit uint64 + WaitReceiptTimeout time.Duration + ProverEndpoints []*url.URL + OptimisticTierFee *big.Int + SgxTierFee *big.Int + TierFeePriceBump *big.Int + MaxTierFeePriceBumps uint64 + IncludeParentMetaHash bool + BlobAllowed bool + TxmgrConfigs *txmgr.CLIConfig + L1BlockBuilderTip *big.Int } // NewConfigFromCliContext initializes a Config instance from @@ -67,19 +68,6 @@ func NewConfigFromCliContext(c *cli.Context) (*Config, error) { } } - proposeBlockTxReplacementMultiplier := c.Uint64(flags.ProposeBlockTxReplacementMultiplier.Name) - if proposeBlockTxReplacementMultiplier == 0 { - return nil, fmt.Errorf( - "invalid --proposeBlockTxReplacementMultiplier value: %d", - proposeBlockTxReplacementMultiplier, - ) - } - - var proposeBlockTxGasTipCap *big.Int - if c.IsSet(flags.ProposeBlockTxGasTipCap.Name) { - proposeBlockTxGasTipCap = new(big.Int).SetUint64(c.Uint64(flags.ProposeBlockTxGasTipCap.Name)) - } - var proverEndpoints []*url.URL for _, e := range strings.Split(c.String(flags.ProverEndpoints.Name), ",") { endpoint, err := url.Parse(e) @@ -98,26 +86,29 @@ func NewConfigFromCliContext(c *cli.Context) (*Config, error) { TaikoTokenAddress: common.HexToAddress(c.String(flags.TaikoTokenAddress.Name)), Timeout: c.Duration(flags.RPCTimeout.Name), }, - AssignmentHookAddress: common.HexToAddress(c.String(flags.ProposerAssignmentHookAddress.Name)), - L1ProposerPrivKey: l1ProposerPrivKey, - L2SuggestedFeeRecipient: common.HexToAddress(l2SuggestedFeeRecipient), - ExtraData: c.String(flags.ExtraData.Name), - ProposeInterval: c.Duration(flags.ProposeInterval.Name), - LocalAddresses: localAddresses, - LocalAddressesOnly: c.Bool(flags.TxPoolLocalsOnly.Name), - ProposeEmptyBlocksInterval: c.Duration(flags.ProposeEmptyBlocksInterval.Name), - MaxProposedTxListsPerEpoch: c.Uint64(flags.MaxProposedTxListsPerEpoch.Name), - ProposeBlockTxGasLimit: c.Uint64(flags.ProposeBlockTxGasLimit.Name), - ProposeBlockTxReplacementMultiplier: proposeBlockTxReplacementMultiplier, - WaitReceiptTimeout: c.Duration(flags.WaitReceiptTimeout.Name), - ProposeBlockTxGasTipCap: proposeBlockTxGasTipCap, - ProverEndpoints: proverEndpoints, - OptimisticTierFee: new(big.Int).SetUint64(c.Uint64(flags.OptimisticTierFee.Name)), - SgxTierFee: new(big.Int).SetUint64(c.Uint64(flags.SgxTierFee.Name)), - TierFeePriceBump: new(big.Int).SetUint64(c.Uint64(flags.TierFeePriceBump.Name)), - MaxTierFeePriceBumps: c.Uint64(flags.MaxTierFeePriceBumps.Name), - IncludeParentMetaHash: c.Bool(flags.ProposeBlockIncludeParentMetaHash.Name), - BlobAllowed: c.Bool(flags.BlobAllowed.Name), - L1BlockBuilderTip: new(big.Int).SetUint64(c.Uint64(flags.L1BlockBuilderTip.Name)), + AssignmentHookAddress: common.HexToAddress(c.String(flags.ProposerAssignmentHookAddress.Name)), + L1ProposerPrivKey: l1ProposerPrivKey, + L2SuggestedFeeRecipient: common.HexToAddress(l2SuggestedFeeRecipient), + ExtraData: c.String(flags.ExtraData.Name), + ProposeInterval: c.Duration(flags.ProposeInterval.Name), + LocalAddresses: localAddresses, + LocalAddressesOnly: c.Bool(flags.TxPoolLocalsOnly.Name), + ProposeEmptyBlocksInterval: c.Duration(flags.ProposeEmptyBlocksInterval.Name), + MaxProposedTxListsPerEpoch: c.Uint64(flags.MaxProposedTxListsPerEpoch.Name), + ProposeBlockTxGasLimit: c.Uint64(flags.TxGasLimit.Name), + WaitReceiptTimeout: c.Duration(flags.WaitReceiptTimeout.Name), + ProverEndpoints: proverEndpoints, + OptimisticTierFee: new(big.Int).SetUint64(c.Uint64(flags.OptimisticTierFee.Name)), + SgxTierFee: new(big.Int).SetUint64(c.Uint64(flags.SgxTierFee.Name)), + TierFeePriceBump: new(big.Int).SetUint64(c.Uint64(flags.TierFeePriceBump.Name)), + MaxTierFeePriceBumps: c.Uint64(flags.MaxTierFeePriceBumps.Name), + IncludeParentMetaHash: c.Bool(flags.ProposeBlockIncludeParentMetaHash.Name), + BlobAllowed: c.Bool(flags.BlobAllowed.Name), + L1BlockBuilderTip: new(big.Int).SetUint64(c.Uint64(flags.L1BlockBuilderTip.Name)), + TxmgrConfigs: pkgFlags.InitTxmgrConfigsFromCli( + c.String(flags.L1WSEndpoint.Name), + l1ProposerPrivKey, + c, + ), }, nil } diff --git a/proposer/config_test.go b/proposer/config_test.go index d55cf5afc..e2c9fa858 100644 --- a/proposer/config_test.go +++ b/proposer/config_test.go @@ -46,7 +46,6 @@ func (s *ProposerTestSuite) TestNewConfigFromCliContext() { s.Equal(float64(10), c.ProposeInterval.Seconds()) s.Equal(1, len(c.LocalAddresses)) s.Equal(goldenTouchAddress, c.LocalAddresses[0]) - s.Equal(uint64(5), c.ProposeBlockTxReplacementMultiplier) s.Equal(5*time.Second, c.Timeout) s.Equal(10*time.Second, c.WaitReceiptTimeout) s.Equal(uint64(tierFee), c.OptimisticTierFee.Uint64()) @@ -74,11 +73,9 @@ func (s *ProposerTestSuite) TestNewConfigFromCliContext() { "--" + flags.L2SuggestedFeeRecipient.Name, goldenTouchAddress.Hex(), "--" + flags.ProposeInterval.Name, proposeInterval, "--" + flags.TxPoolLocals.Name, goldenTouchAddress.Hex(), - "--" + flags.ProposeBlockTxReplacementMultiplier.Name, "5", "--" + flags.RPCTimeout.Name, rpcTimeout, "--" + flags.WaitReceiptTimeout.Name, "10s", - "--" + flags.ProposeBlockTxGasTipCap.Name, "100000", - "--" + flags.ProposeBlockTxGasLimit.Name, "100000", + "--" + flags.TxGasLimit.Name, "100000", "--" + flags.ProverEndpoints.Name, proverEndpoints, "--" + flags.OptimisticTierFee.Name, fmt.Sprint(tierFee), "--" + flags.SgxTierFee.Name, fmt.Sprint(tierFee), @@ -125,23 +122,6 @@ func (s *ProposerTestSuite) TestNewConfigFromCliContextTxPoolLocalsErr() { }), "invalid account in --txpool.locals") } -func (s *ProposerTestSuite) TestNewConfigFromCliContextReplMultErr() { - goldenTouchAddress, err := s.RPCClient.TaikoL2.GOLDENTOUCHADDRESS(nil) - s.Nil(err) - - app := s.SetupApp() - - s.ErrorContains(app.Run([]string{ - "TestNewConfigFromCliContextReplMultErr", - "--" + flags.L1ProposerPrivKey.Name, encoding.GoldenTouchPrivKey, - "--" + flags.L2SuggestedFeeRecipient.Name, goldenTouchAddress.Hex(), - "--" + flags.ProposeInterval.Name, proposeInterval, - "--" + flags.ProposeEmptyBlocksInterval.Name, proposeInterval, - "--" + flags.TxPoolLocals.Name, goldenTouchAddress.Hex(), - "--" + flags.ProposeBlockTxReplacementMultiplier.Name, "0", - }), "invalid --proposeBlockTxReplacementMultiplier value") -} - func (s *ProposerTestSuite) SetupApp() *cli.App { app := cli.NewApp() app.Flags = []cli.Flag{ @@ -158,16 +138,14 @@ func (s *ProposerTestSuite) SetupApp() *cli.App { &cli.StringFlag{Name: flags.ProverEndpoints.Name}, &cli.Uint64Flag{Name: flags.OptimisticTierFee.Name}, &cli.Uint64Flag{Name: flags.SgxTierFee.Name}, - &cli.Uint64Flag{Name: flags.ProposeBlockTxReplacementMultiplier.Name}, &cli.DurationFlag{Name: flags.RPCTimeout.Name}, &cli.DurationFlag{Name: flags.WaitReceiptTimeout.Name}, - &cli.Uint64Flag{Name: flags.ProposeBlockTxGasTipCap.Name}, - &cli.Uint64Flag{Name: flags.ProposeBlockTxGasLimit.Name}, &cli.Uint64Flag{Name: flags.TierFeePriceBump.Name}, &cli.Uint64Flag{Name: flags.MaxTierFeePriceBumps.Name}, &cli.BoolFlag{Name: flags.ProposeBlockIncludeParentMetaHash.Name}, &cli.StringFlag{Name: flags.ProposerAssignmentHookAddress.Name}, } + app.Flags = append(app.Flags, flags.TxmgrFlags...) app.Action = func(ctx *cli.Context) error { _, err := NewConfigFromCliContext(ctx) return err diff --git a/proposer/proposer.go b/proposer/proposer.go index 49547c941..52c26e6c5 100644 --- a/proposer/proposer.go +++ b/proposer/proposer.go @@ -9,6 +9,8 @@ import ( "sync" "time" + "github.com/ethereum-optimism/optimism/op-service/txmgr" + txmgrMetrics "github.com/ethereum-optimism/optimism/op-service/txmgr/metrics" "github.com/ethereum/go-ethereum/accounts/abi/bind" "github.com/ethereum/go-ethereum/common" "github.com/ethereum/go-ethereum/core/types" @@ -21,7 +23,6 @@ import ( "github.com/taikoxyz/taiko-client/internal/metrics" "github.com/taikoxyz/taiko-client/internal/utils" "github.com/taikoxyz/taiko-client/pkg/rpc" - "github.com/taikoxyz/taiko-client/pkg/sender" selector "github.com/taikoxyz/taiko-client/proposer/prover_selector" builder "github.com/taikoxyz/taiko-client/proposer/transaction_builder" "github.com/urfave/cli/v2" @@ -35,10 +36,12 @@ var ( // Proposer keep proposing new transactions from L2 execution engine's tx pool at a fixed interval. type Proposer struct { + // configurations + *Config + // RPC clients rpc *rpc.Client - *Config // Private keys and account addresses proposerAddress common.Address @@ -60,7 +63,7 @@ type Proposer struct { CustomProposeOpHook func() error AfterCommitHook func() error - sender *sender.Sender + txmgr *txmgr.SimpleTxManager ctx context.Context wg sync.WaitGroup @@ -103,12 +106,12 @@ func (p *Proposer) InitFromConfig(ctx context.Context, cfg *Config) (err error) return err } - if p.sender, err = sender.NewSender(ctx, &sender.Config{ - MaxGasFee: 20000000000, - GasGrowthRate: 20, - GasLimit: cfg.ProposeBlockTxGasLimit, - MaxWaitingTime: time.Second * 30, - }, p.rpc.L1, cfg.L1ProposerPrivKey); err != nil { + if p.txmgr, err = txmgr.NewSimpleTxManager( + "proposer", + log.Root(), + new(txmgrMetrics.NoopTxMetrics), + *cfg.TxmgrConfigs, + ); err != nil { return err } @@ -135,6 +138,7 @@ func (p *Proposer) InitFromConfig(ctx context.Context, cfg *Config) (err error) cfg.TaikoL1Address, cfg.L2SuggestedFeeRecipient, cfg.AssignmentHookAddress, + cfg.ProposeBlockTxGasLimit, cfg.ExtraData, ) } else { @@ -143,7 +147,9 @@ func (p *Proposer) InitFromConfig(ctx context.Context, cfg *Config) (err error) p.proverSelector, p.Config.L1BlockBuilderTip, cfg.L2SuggestedFeeRecipient, + cfg.TaikoL1Address, cfg.AssignmentHookAddress, + cfg.ProposeBlockTxGasLimit, cfg.ExtraData, ) } @@ -204,7 +210,6 @@ func (p *Proposer) eventLoop() { // Close closes the proposer instance. func (p *Proposer) Close(_ context.Context) { - p.sender.Close() p.wg.Wait() } @@ -268,13 +273,6 @@ func (p *Proposer) ProposeOp(ctx context.Context) error { return errNoNewTxs } - // Wait for all transactions to be confirmed, if there is any. - defer func() { - if err := p.waitConfimations(); err != nil { - log.Error("Failed to wait proposer transactions confirmations", "error", err) - } - }() - // Propose all L2 transactions lists. for i, txs := range txLists { if i >= int(p.MaxProposedTxListsPerEpoch) { @@ -294,26 +292,6 @@ func (p *Proposer) ProposeOp(ctx context.Context) error { return nil } -// waitConfimations waits for all current proposer transactions to be confirmed. -func (p *Proposer) waitConfimations() error { - // Wait for all transactions to be confirmed. - for _, confirmCh := range p.sender.TxToConfirmChannels() { - confirm := <-confirmCh - if confirm.Err != nil { - log.Error("ProposeTxList error", "txId", confirm.ID, "error", confirm.Err) - return confirm.Err - } - } - - if p.AfterCommitHook != nil { - if err := p.AfterCommitHook(); err != nil { - log.Error("Run AfterCommitHook error", "error", err) - } - } - - return nil -} - // ProposeTxList proposes the given transactions list to TaikoL1 smart contract. func (p *Proposer) ProposeTxList( ctx context.Context, @@ -325,10 +303,9 @@ func (p *Proposer) ProposeTxList( return err } - tx, err := p.txBuilder.Build( + txCandidate, err := p.txBuilder.Build( ctx, p.tierFees, - p.sender.GetOpts(p.ctx), p.IncludeParentMetaHash, compressedTxListBytes, ) @@ -337,11 +314,16 @@ func (p *Proposer) ProposeTxList( return err } - if _, err = p.sender.SendTransaction(tx); err != nil { + receipt, err := p.txmgr.Send(p.ctx, *txCandidate) + if err != nil { log.Warn("Failed to send TaikoL1.proposeBlock transaction", "error", encoding.TryParsingCustomError(err)) return err } + if receipt.Status != types.ReceiptStatusSuccessful { + return fmt.Errorf("failed to propose block: %s", receipt.TxHash.Hex()) + } + log.Info("📝 Propose transactions succeeded", "txs", txNum) metrics.ProposerProposedTxListsCounter.Inc(1) @@ -359,13 +341,6 @@ func (p *Proposer) ProposeEmptyBlockOp(ctx context.Context) error { if err = p.ProposeTxList(ctx, emptyTxListBytes, 0); err != nil { return err } - for _, confirmCh := range p.sender.TxToConfirmChannels() { - confirm := <-confirmCh - if confirm.Err != nil { - log.Error("ProposeEmptyBlockOp error", "td_id", confirm.ID, "error", confirm.Err) - return confirm.Err - } - } return nil } @@ -392,11 +367,6 @@ func (p *Proposer) Name() string { return "proposer" } -// GetSender returns the sender instance. -func (p *Proposer) GetSender() *sender.Sender { - return p.sender -} - // initTierFees initializes the proving fees for every proof tier configured in the protocol for the proposer. func (p *Proposer) initTierFees() error { for _, tier := range p.tiers { diff --git a/proposer/proposer_test.go b/proposer/proposer_test.go index 21f7e8f11..76d867782 100644 --- a/proposer/proposer_test.go +++ b/proposer/proposer_test.go @@ -7,10 +7,10 @@ import ( "testing" "time" + "github.com/ethereum-optimism/optimism/op-service/txmgr" "github.com/ethereum/go-ethereum/common" "github.com/ethereum/go-ethereum/core/types" "github.com/ethereum/go-ethereum/crypto" - "github.com/ethereum/go-ethereum/rlp" "github.com/stretchr/testify/suite" "github.com/taikoxyz/taiko-client/bindings" @@ -42,20 +42,34 @@ func (s *ProposerTestSuite) SetupTest() { TaikoL2Address: common.HexToAddress(os.Getenv("TAIKO_L2_ADDRESS")), TaikoTokenAddress: common.HexToAddress(os.Getenv("TAIKO_TOKEN_ADDRESS")), }, - AssignmentHookAddress: common.HexToAddress(os.Getenv("ASSIGNMENT_HOOK_ADDRESS")), - L1ProposerPrivKey: l1ProposerPrivKey, - L2SuggestedFeeRecipient: common.HexToAddress(os.Getenv("L2_SUGGESTED_FEE_RECIPIENT")), - ProposeInterval: 1024 * time.Hour, - MaxProposedTxListsPerEpoch: 1, - ProposeBlockTxReplacementMultiplier: 2, - WaitReceiptTimeout: 12 * time.Second, - ProverEndpoints: s.ProverEndpoints, - OptimisticTierFee: common.Big256, - SgxTierFee: common.Big256, - TierFeePriceBump: common.Big2, - MaxTierFeePriceBumps: 3, - ExtraData: "test", - L1BlockBuilderTip: common.Big0, + AssignmentHookAddress: common.HexToAddress(os.Getenv("ASSIGNMENT_HOOK_ADDRESS")), + L1ProposerPrivKey: l1ProposerPrivKey, + L2SuggestedFeeRecipient: common.HexToAddress(os.Getenv("L2_SUGGESTED_FEE_RECIPIENT")), + ProposeInterval: 1024 * time.Hour, + MaxProposedTxListsPerEpoch: 1, + WaitReceiptTimeout: 12 * time.Second, + ProverEndpoints: s.ProverEndpoints, + OptimisticTierFee: common.Big256, + SgxTierFee: common.Big256, + TierFeePriceBump: common.Big2, + MaxTierFeePriceBumps: 3, + ExtraData: "test", + L1BlockBuilderTip: common.Big0, + TxmgrConfigs: &txmgr.CLIConfig{ + L1RPCURL: os.Getenv("L1_NODE_WS_ENDPOINT"), + NumConfirmations: 1, + SafeAbortNonceTooLowCount: txmgr.DefaultBatcherFlagValues.SafeAbortNonceTooLowCount, + PrivateKey: common.Bytes2Hex(crypto.FromECDSA(l1ProposerPrivKey)), + FeeLimitMultiplier: txmgr.DefaultBatcherFlagValues.FeeLimitMultiplier, + FeeLimitThresholdGwei: txmgr.DefaultBatcherFlagValues.FeeLimitThresholdGwei, + MinBaseFeeGwei: txmgr.DefaultBatcherFlagValues.MinBaseFeeGwei, + MinTipCapGwei: txmgr.DefaultBatcherFlagValues.MinTipCapGwei, + ResubmissionTimeout: txmgr.DefaultBatcherFlagValues.ResubmissionTimeout, + ReceiptQueryInterval: 1 * time.Second, + NetworkTimeout: txmgr.DefaultBatcherFlagValues.NetworkTimeout, + TxSendTimeout: txmgr.DefaultBatcherFlagValues.TxSendTimeout, + TxNotInMempoolTimeout: txmgr.DefaultBatcherFlagValues.TxNotInMempoolTimeout, + }, })) s.p = p @@ -149,54 +163,6 @@ func (s *ProposerTestSuite) TestCustomProposeOpHook() { s.True(flag) } -func (s *ProposerTestSuite) TestSendProposeBlockTx() { - sender := s.p.GetSender() - s.SetL1Automine(false) - defer s.SetL1Automine(true) - - s.Nil(sender.SetNonce(nil, true)) - - nonce, err := s.RPCClient.L1.PendingNonceAt(context.Background(), s.p.proposerAddress) - s.Nil(err) - - txID, err := sender.SendRawTransaction( - context.Background(), - nonce, - &common.Address{}, - common.Big1, - nil, - nil, - ) - s.Nil(err) - tx := sender.GetUnconfirmedTx(txID) - - encoded, err := rlp.EncodeToBytes([]types.Transaction{}) - s.Nil(err) - - newTx, err := s.p.txBuilder.Build( - context.Background(), - s.p.tierFees, - sender.GetOpts(context.Background()), - false, - encoded, - ) - - s.Nil(err) - - txID, err = sender.SendRawTransaction( - context.Background(), - nonce, - newTx.To(), - newTx.Value(), - newTx.Data(), - nil, - ) - s.Nil(err) - newTx = sender.GetUnconfirmedTx(txID) - - s.Greater(newTx.GasTipCap().Uint64(), tx.GasTipCap().Uint64()) -} - func (s *ProposerTestSuite) TestAssignProverSuccessFirstRound() { s.SetL1Automine(false) defer s.SetL1Automine(true) diff --git a/proposer/transaction_builder/blob.go b/proposer/transaction_builder/blob.go index d64454ec8..c073e9224 100644 --- a/proposer/transaction_builder/blob.go +++ b/proposer/transaction_builder/blob.go @@ -4,10 +4,9 @@ import ( "context" "math/big" - "github.com/ethereum/go-ethereum/accounts/abi/bind" + "github.com/ethereum-optimism/optimism/op-service/eth" + "github.com/ethereum-optimism/optimism/op-service/txmgr" "github.com/ethereum/go-ethereum/common" - "github.com/ethereum/go-ethereum/core/types" - "github.com/ethereum/go-ethereum/log" "github.com/taikoxyz/taiko-client/bindings/encoding" "github.com/taikoxyz/taiko-client/pkg/rpc" selector "github.com/taikoxyz/taiko-client/proposer/prover_selector" @@ -22,6 +21,7 @@ type BlobTransactionBuilder struct { taikoL1Address common.Address l2SuggestedFeeRecipient common.Address assignmentHookAddress common.Address + gasLimit uint64 extraData string } @@ -33,6 +33,7 @@ func NewBlobTransactionBuilder( taikoL1Address common.Address, l2SuggestedFeeRecipient common.Address, assignmentHookAddress common.Address, + gasLimit uint64, extraData string, ) *BlobTransactionBuilder { return &BlobTransactionBuilder{ @@ -42,6 +43,7 @@ func NewBlobTransactionBuilder( taikoL1Address, l2SuggestedFeeRecipient, assignmentHookAddress, + gasLimit, extraData, } } @@ -50,16 +52,20 @@ func NewBlobTransactionBuilder( func (b *BlobTransactionBuilder) Build( ctx context.Context, tierFees []encoding.TierFee, - opts *bind.TransactOpts, includeParentMetaHash bool, txListBytes []byte, -) (*types.Transaction, error) { +) (*txmgr.TxCandidate, error) { // Make a sidecar then calculate the blob hash. sideCar, err := rpc.MakeSidecar(txListBytes) if err != nil { return nil, err } + var blob *eth.Blob + if err := blob.FromData(txListBytes); err != nil { + return nil, err + } + // Try to assign a prover. assignment, assignedProver, maxFee, err := b.proverSelector.AssignProver( ctx, @@ -70,9 +76,6 @@ func (b *BlobTransactionBuilder) Build( return nil, err } - // Set the ETHs that the current proposer needs to pay to the prover. - opts.Value = maxFee - // If the current proposer wants to include the parent meta hash, then fetch it from the protocol. var parentMetaHash = [32]byte{} if includeParentMetaHash { @@ -103,20 +106,16 @@ func (b *BlobTransactionBuilder) Build( } // Send the transaction to the L1 node. - rawTx, err := b.rpc.TaikoL1.ProposeBlock( - opts, - encodedParams, - nil, - ) + data, err := encoding.TaikoL1ABI.Pack("proposeBlock", encodedParams, nil) if err != nil { return nil, encoding.TryParsingCustomError(err) } - tx, err := b.rpc.L1.TransactBlobTx(opts, b.taikoL1Address, rawTx.Data(), sideCar) - if err != nil { - log.Debug("Failed to transact blob tx", "value", maxFee, "blobGasFeeCap", tx.BlobGasFeeCap(), "err", err) - return nil, err - } - - return tx, nil + return &txmgr.TxCandidate{ + TxData: data, + Blobs: []*eth.Blob{blob}, + To: &b.taikoL1Address, + GasLimit: b.gasLimit, + Value: maxFee, + }, nil } diff --git a/proposer/transaction_builder/calldata.go b/proposer/transaction_builder/calldata.go index 78949f725..a46855b5c 100644 --- a/proposer/transaction_builder/calldata.go +++ b/proposer/transaction_builder/calldata.go @@ -4,9 +4,8 @@ import ( "context" "math/big" - "github.com/ethereum/go-ethereum/accounts/abi/bind" + "github.com/ethereum-optimism/optimism/op-service/txmgr" "github.com/ethereum/go-ethereum/common" - "github.com/ethereum/go-ethereum/core/types" "github.com/ethereum/go-ethereum/crypto" "github.com/taikoxyz/taiko-client/bindings/encoding" @@ -21,7 +20,9 @@ type CalldataTransactionBuilder struct { proverSelector selector.ProverSelector l1BlockBuilderTip *big.Int l2SuggestedFeeRecipient common.Address + taikoL1Address common.Address assignmentHookAddress common.Address + gasLimit uint64 extraData string } @@ -31,7 +32,9 @@ func NewCalldataTransactionBuilder( proverSelector selector.ProverSelector, l1BlockBuilderTip *big.Int, l2SuggestedFeeRecipient common.Address, + taikoL1Address common.Address, assignmentHookAddress common.Address, + gasLimit uint64, extraData string, ) *CalldataTransactionBuilder { return &CalldataTransactionBuilder{ @@ -39,7 +42,9 @@ func NewCalldataTransactionBuilder( proverSelector, l1BlockBuilderTip, l2SuggestedFeeRecipient, + taikoL1Address, assignmentHookAddress, + gasLimit, extraData, } } @@ -48,10 +53,9 @@ func NewCalldataTransactionBuilder( func (b *CalldataTransactionBuilder) Build( ctx context.Context, tierFees []encoding.TierFee, - opts *bind.TransactOpts, includeParentMetaHash bool, txListBytes []byte, -) (*types.Transaction, error) { +) (*txmgr.TxCandidate, error) { // Try to assign a prover. assignment, assignedProver, maxFee, err := b.proverSelector.AssignProver( ctx, @@ -62,9 +66,6 @@ func (b *CalldataTransactionBuilder) Build( return nil, err } - // Set the ETHs that the current proposer needs to pay to the prover. - opts.Value = maxFee - // If the current proposer wants to include the parent meta hash, then fetch it from the protocol. var parentMetaHash = [32]byte{} if includeParentMetaHash { @@ -95,10 +96,16 @@ func (b *CalldataTransactionBuilder) Build( } // Send the transaction to the L1 node. - tx, err := b.rpc.TaikoL1.ProposeBlock(opts, encodedParams, txListBytes) + data, err := encoding.TaikoL1ABI.Pack("proposeBlock", encodedParams, txListBytes) if err != nil { return nil, encoding.TryParsingCustomError(err) } - return tx, nil + return &txmgr.TxCandidate{ + TxData: data, + Blobs: nil, + To: &b.taikoL1Address, + GasLimit: b.gasLimit, + Value: maxFee, + }, nil } diff --git a/proposer/transaction_builder/calldata_test.go b/proposer/transaction_builder/calldata_test.go index ad045add5..c63824728 100644 --- a/proposer/transaction_builder/calldata_test.go +++ b/proposer/transaction_builder/calldata_test.go @@ -4,7 +4,6 @@ import ( "context" "github.com/ethereum/go-ethereum/common" - "github.com/ethereum/go-ethereum/core/types" "github.com/taikoxyz/taiko-client/bindings/encoding" ) @@ -13,7 +12,7 @@ func (s *TransactionBuilderTestSuite) TestBuildCalldata() { {Tier: encoding.TierOptimisticID, Fee: common.Big256}, {Tier: encoding.TierSgxID, Fee: common.Big256}, {Tier: encoding.TierSgxAndZkVMID, Fee: common.Big257}, - }, s.sender.GetOpts(context.Background()), false, []byte{1}) + }, false, []byte{1}) s.Nil(err) - s.Equal(types.DynamicFeeTxType, int(tx.Type())) + s.Nil(tx.Blobs) } diff --git a/proposer/transaction_builder/common_test.go b/proposer/transaction_builder/common_test.go index e48eda4e8..839fbe79a 100644 --- a/proposer/transaction_builder/common_test.go +++ b/proposer/transaction_builder/common_test.go @@ -8,12 +8,10 @@ import ( "time" "github.com/ethereum/go-ethereum/common" - "github.com/ethereum/go-ethereum/crypto" "github.com/stretchr/testify/suite" "github.com/taikoxyz/taiko-client/bindings/encoding" "github.com/taikoxyz/taiko-client/internal/testutils" - "github.com/taikoxyz/taiko-client/pkg/sender" selector "github.com/taikoxyz/taiko-client/proposer/prover_selector" ) @@ -21,7 +19,6 @@ type TransactionBuilderTestSuite struct { testutils.ClientTestSuite calldataTxBuilder *CalldataTransactionBuilder blobTxBuiler *BlobTransactionBuilder - sender *sender.Sender } func (s *TransactionBuilderTestSuite) SetupTest() { @@ -47,8 +44,10 @@ func (s *TransactionBuilderTestSuite) SetupTest() { s.RPCClient, proverSelector, common.Big0, + common.HexToAddress(os.Getenv("TAIKO_L2_ADDRESS")), common.HexToAddress(os.Getenv("TAIKO_L1_ADDRESS")), common.HexToAddress(os.Getenv("ASSIGNMENT_HOOK_ADDRESS")), + 0, "test", ) s.blobTxBuiler = NewBlobTransactionBuilder( @@ -58,20 +57,9 @@ func (s *TransactionBuilderTestSuite) SetupTest() { common.HexToAddress(os.Getenv("TAIKO_L1_ADDRESS")), common.HexToAddress(os.Getenv("TAIKO_L2_ADDRESS")), common.HexToAddress(os.Getenv("ASSIGNMENT_HOOK_ADDRESS")), + 0, "test", ) - - l1ProposerPrivKey, err := crypto.ToECDSA(common.FromHex(os.Getenv("L1_PROPOSER_PRIVATE_KEY"))) - s.Nil(err) - - s.sender, err = sender.NewSender(context.Background(), &sender.Config{ - MaxGasFee: 20000000000, - GasGrowthRate: 50, - MaxRetrys: 0, - GasLimit: 2000000, - MaxWaitingTime: time.Second * 10, - }, s.RPCClient.L1, l1ProposerPrivKey) - s.Nil(err) } func (s *TransactionBuilderTestSuite) TestGetParentMetaHash() { diff --git a/proposer/transaction_builder/interface.go b/proposer/transaction_builder/interface.go index 42ebc8a8a..4d870d64d 100644 --- a/proposer/transaction_builder/interface.go +++ b/proposer/transaction_builder/interface.go @@ -3,8 +3,7 @@ package builder import ( "context" - "github.com/ethereum/go-ethereum/accounts/abi/bind" - "github.com/ethereum/go-ethereum/core/types" + "github.com/ethereum-optimism/optimism/op-service/txmgr" "github.com/taikoxyz/taiko-client/bindings/encoding" ) @@ -13,8 +12,7 @@ type ProposeBlockTransactionBuilder interface { Build( ctx context.Context, tierFees []encoding.TierFee, - opts *bind.TransactOpts, includeParentMetaHash bool, txListBytes []byte, - ) (*types.Transaction, error) + ) (*txmgr.TxCandidate, error) } diff --git a/prover/config.go b/prover/config.go index 9bc7110d1..e6dedd799 100644 --- a/prover/config.go +++ b/prover/config.go @@ -8,11 +8,13 @@ import ( "net/url" "time" + "github.com/ethereum-optimism/optimism/op-service/txmgr" "github.com/ethereum/go-ethereum/common" "github.com/ethereum/go-ethereum/crypto" "github.com/urfave/cli/v2" "github.com/taikoxyz/taiko-client/cmd/flags" + pkgFlags "github.com/taikoxyz/taiko-client/pkg/flags" ) // Config contains the configurations to initialize a Taiko prover. @@ -31,7 +33,6 @@ type Config struct { Dummy bool GuardianProverAddress common.Address GuardianProofSubmissionDelay time.Duration - ProofSubmissionMaxRetry uint64 Graffiti string BackOffMaxRetrys uint64 BackOffRetryInterval time.Duration @@ -41,8 +42,6 @@ type Config struct { RPCTimeout time.Duration WaitReceiptTimeout time.Duration ProveBlockGasLimit *uint64 - ProveBlockTxReplacementGasGrowthRate uint64 - ProveBlockMaxTxGasFeeCap *big.Int HTTPServerPort uint64 Capacity uint64 MinOptimisticTierFee *big.Int @@ -59,6 +58,7 @@ type Config struct { L1NodeVersion string L2NodeVersion string BlockConfirmations uint64 + TxmgrConfigs *txmgr.CLIConfig } // NewConfigFromCliContext creates a new config instance from command line flags. @@ -78,24 +78,11 @@ func NewConfigFromCliContext(c *cli.Context) (*Config, error) { } var proveBlockTxGasLimit *uint64 - if c.IsSet(flags.ProveBlockTxGasLimit.Name) { - gasLimit := c.Uint64(flags.ProveBlockTxGasLimit.Name) + if c.IsSet(flags.TxGasLimit.Name) { + gasLimit := c.Uint64(flags.TxGasLimit.Name) proveBlockTxGasLimit = &gasLimit } - proveBlockTxReplacementMultiplier := c.Uint64(flags.TxReplacementGasGrowthRate.Name) - if proveBlockTxReplacementMultiplier == 0 { - return nil, fmt.Errorf( - "invalid --proveBlockTxReplacementMultiplier value: %d", - proveBlockTxReplacementMultiplier, - ) - } - - var proveBlockMaxTxGasTipCap *big.Int - if c.IsSet(flags.ProveBlockMaxTxGasFeeCap.Name) { - proveBlockMaxTxGasTipCap = new(big.Int).SetUint64(c.Uint64(flags.ProveBlockMaxTxGasFeeCap.Name)) - } - var allowance = common.Big0 if c.IsSet(flags.Allowance.Name) { amt, ok := new(big.Int).SetString(c.String(flags.Allowance.Name), 10) @@ -156,7 +143,6 @@ func NewConfigFromCliContext(c *cli.Context) (*Config, error) { GuardianProverAddress: common.HexToAddress(c.String(flags.GuardianProver.Name)), GuardianProofSubmissionDelay: c.Duration(flags.GuardianProofSubmissionDelay.Name), GuardianProverHealthCheckServerEndpoint: guardianProverHealthCheckServerEndpoint, - ProofSubmissionMaxRetry: c.Uint64(flags.ProofSubmissionMaxRetry.Name), Graffiti: c.String(flags.Graffiti.Name), BackOffMaxRetrys: c.Uint64(flags.BackOffMaxRetrys.Name), BackOffRetryInterval: c.Duration(flags.BackOffRetryInterval.Name), @@ -167,8 +153,6 @@ func NewConfigFromCliContext(c *cli.Context) (*Config, error) { WaitReceiptTimeout: c.Duration(flags.WaitReceiptTimeout.Name), ProveBlockGasLimit: proveBlockTxGasLimit, Capacity: c.Uint64(flags.ProverCapacity.Name), - ProveBlockTxReplacementGasGrowthRate: proveBlockTxReplacementMultiplier, - ProveBlockMaxTxGasFeeCap: proveBlockMaxTxGasTipCap, HTTPServerPort: c.Uint64(flags.ProverHTTPServerPort.Name), MinOptimisticTierFee: new(big.Int).SetUint64(c.Uint64(flags.MinOptimisticTierFee.Name)), MinSgxTierFee: new(big.Int).SetUint64(c.Uint64(flags.MinSgxTierFee.Name)), @@ -182,5 +166,10 @@ func NewConfigFromCliContext(c *cli.Context) (*Config, error) { L1NodeVersion: c.String(flags.L1NodeVersion.Name), L2NodeVersion: c.String(flags.L2NodeVersion.Name), BlockConfirmations: c.Uint64(flags.BlockConfirmations.Name), + TxmgrConfigs: pkgFlags.InitTxmgrConfigsFromCli( + c.String(flags.L1HTTPEndpoint.Name), + l1ProverPrivKey, + c, + ), }, nil } diff --git a/prover/config_test.go b/prover/config_test.go index 95c29f189..a6214060d 100644 --- a/prover/config_test.go +++ b/prover/config_test.go @@ -51,8 +51,6 @@ func (s *ProverTestSuite) TestNewConfigFromCliContextGuardianProver() { s.Equal(uint64(8), c.Capacity) s.Equal(uint64(minTierFee), c.MinOptimisticTierFee.Uint64()) s.Equal(uint64(minTierFee), c.MinSgxTierFee.Uint64()) - s.Equal(uint64(3), c.ProveBlockTxReplacementGasGrowthRate) - s.Equal(uint64(256), c.ProveBlockMaxTxGasFeeCap.Uint64()) s.Equal(c.L1NodeVersion, l1NodeVersion) s.Equal(c.L2NodeVersion, l2NodeVersion) s.Nil(new(Prover).InitFromCli(context.Background(), ctx)) @@ -76,15 +74,13 @@ func (s *ProverTestSuite) TestNewConfigFromCliContextGuardianProver() { "--" + flags.L1ProverPrivKey.Name, os.Getenv("L1_PROVER_PRIVATE_KEY"), "--" + flags.StartingBlockID.Name, "0", "--" + flags.RPCTimeout.Name, "5s", - "--" + flags.ProveBlockTxGasLimit.Name, "100000", + "--" + flags.TxGasLimit.Name, "100000", "--" + flags.Dummy.Name, "--" + flags.MinOptimisticTierFee.Name, fmt.Sprint(minTierFee), "--" + flags.MinSgxTierFee.Name, fmt.Sprint(minTierFee), "--" + flags.ProverCapacity.Name, "8", "--" + flags.GuardianProver.Name, os.Getenv("GUARDIAN_PROVER_CONTRACT_ADDRESS"), "--" + flags.ProverAssignmentHookAddress.Name, os.Getenv("ASSIGNMENT_HOOK_ADDRESS"), - "--" + flags.TxReplacementGasGrowthRate.Name, "3", - "--" + flags.ProveBlockMaxTxGasFeeCap.Name, "256", "--" + flags.Graffiti.Name, "", "--" + flags.ProveUnassignedBlocks.Name, "--" + flags.MaxProposedIn.Name, "100", @@ -119,13 +115,10 @@ func (s *ProverTestSuite) SetupApp() *cli.App { &cli.StringFlag{Name: flags.GuardianProver.Name}, &cli.StringFlag{Name: flags.Graffiti.Name}, &cli.BoolFlag{Name: flags.ProveUnassignedBlocks.Name}, - &cli.Uint64Flag{Name: flags.TxReplacementGasGrowthRate.Name}, - &cli.Uint64Flag{Name: flags.ProveBlockMaxTxGasFeeCap.Name}, &cli.DurationFlag{Name: flags.RPCTimeout.Name}, &cli.Uint64Flag{Name: flags.ProverCapacity.Name}, &cli.Uint64Flag{Name: flags.MinOptimisticTierFee.Name}, &cli.Uint64Flag{Name: flags.MinSgxTierFee.Name}, - &cli.Uint64Flag{Name: flags.ProveBlockTxGasLimit.Name}, &cli.Uint64Flag{Name: flags.MaxProposedIn.Name}, &cli.StringFlag{Name: flags.ProverAssignmentHookAddress.Name}, &cli.StringFlag{Name: flags.Allowance.Name}, @@ -133,6 +126,7 @@ func (s *ProverTestSuite) SetupApp() *cli.App { &cli.StringFlag{Name: flags.L1NodeVersion.Name}, &cli.StringFlag{Name: flags.L2NodeVersion.Name}, } + app.Flags = append(app.Flags, flags.TxmgrFlags...) app.Action = func(ctx *cli.Context) error { _, err := NewConfigFromCliContext(ctx) s.NotNil(err) diff --git a/prover/init.go b/prover/init.go index 4b218c15a..4a1857e74 100644 --- a/prover/init.go +++ b/prover/init.go @@ -5,13 +5,14 @@ import ( "fmt" "math/big" + "github.com/ethereum-optimism/optimism/op-service/txmgr" "github.com/ethereum/go-ethereum" "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/log" "github.com/taikoxyz/taiko-client/bindings/encoding" - "github.com/taikoxyz/taiko-client/pkg/sender" handler "github.com/taikoxyz/taiko-client/prover/event_handler" proofProducer "github.com/taikoxyz/taiko-client/prover/proof_producer" proofSubmitter "github.com/taikoxyz/taiko-client/prover/proof_submitter" @@ -51,31 +52,26 @@ func (p *Prover) setApprovalAmount(ctx context.Context, contract common.Address) return nil } - opts := p.txSender.GetOpts(ctx) - log.Info("Approving the contract for taiko token", "allowance", p.cfg.Allowance.String(), "contract", contract) - - tx, err := p.rpc.TaikoToken.Approve( - opts, - contract, - p.cfg.Allowance, - ) + data, err := encoding.TaikoTokenABI.Pack("approve", contract, p.cfg.Allowance) if err != nil { return err } - id, err := p.txSender.SendTransaction(tx) + receipt, err := p.txmgr.Send(ctx, txmgr.TxCandidate{ + TxData: data, + To: &p.cfg.TaikoTokenAddress, + }) if err != nil { return err } - confirm := <-p.txSender.TxToConfirmChannel(id) - if confirm.Err != nil { - return confirm.Err + if receipt.Status != types.ReceiptStatusSuccessful { + return fmt.Errorf("failed to approve allowance for contract (%s): %s", contract, receipt.TxHash.Hex()) } log.Info( "Approved the contract for taiko token", - "txHash", confirm.Receipt.TxHash.Hex(), + "txHash", receipt.TxHash.Hex(), "contract", contract, ) @@ -95,7 +91,7 @@ func (p *Prover) setApprovalAmount(ctx context.Context, contract common.Address) // initProofSubmitters initializes the proof submitters from the given tiers in protocol. func (p *Prover) initProofSubmitters( - sender *sender.Sender, + txmgr *txmgr.SimpleTxManager, txBuilder *transaction.ProveBlockTxBuilder, ) error { for _, tier := range p.sharedState.GetTiers() { @@ -127,7 +123,7 @@ func (p *Prover) initProofSubmitters( p.proofGenerationCh, p.cfg.TaikoL2Address, p.cfg.Graffiti, - sender, + txmgr, txBuilder, ); err != nil { return err diff --git a/prover/proof_submitter/proof_contester.go b/prover/proof_submitter/proof_contester.go index f0fd853ea..bb3834541 100644 --- a/prover/proof_submitter/proof_contester.go +++ b/prover/proof_submitter/proof_contester.go @@ -5,6 +5,7 @@ import ( "math/big" "strings" + "github.com/ethereum-optimism/optimism/op-service/txmgr" "github.com/ethereum/go-ethereum/accounts/abi/bind" "github.com/ethereum/go-ethereum/common" "github.com/ethereum/go-ethereum/log" @@ -12,7 +13,6 @@ import ( "github.com/taikoxyz/taiko-client/bindings" "github.com/taikoxyz/taiko-client/bindings/encoding" "github.com/taikoxyz/taiko-client/pkg/rpc" - "github.com/taikoxyz/taiko-client/pkg/sender" proofProducer "github.com/taikoxyz/taiko-client/prover/proof_producer" "github.com/taikoxyz/taiko-client/prover/proof_submitter/transaction" ) @@ -30,14 +30,14 @@ type ProofContester struct { // NewProofContester creates a new ProofContester instance. func NewProofContester( rpcClient *rpc.Client, - txSender *sender.Sender, + txmgr *txmgr.SimpleTxManager, graffiti string, builder *transaction.ProveBlockTxBuilder, ) *ProofContester { return &ProofContester{ rpc: rpcClient, txBuilder: builder, - sender: transaction.NewSender(rpcClient, txSender), + sender: transaction.NewSender(rpcClient, txmgr, 0), // TODO graffiti: rpc.StringToBytes32(graffiti), } } diff --git a/prover/proof_submitter/proof_submitter.go b/prover/proof_submitter/proof_submitter.go index 6d413e916..5387b3109 100644 --- a/prover/proof_submitter/proof_submitter.go +++ b/prover/proof_submitter/proof_submitter.go @@ -5,6 +5,7 @@ import ( "errors" "fmt" + "github.com/ethereum-optimism/optimism/op-service/txmgr" "github.com/ethereum/go-ethereum/common" "github.com/ethereum/go-ethereum/log" @@ -12,7 +13,6 @@ import ( "github.com/taikoxyz/taiko-client/bindings/encoding" "github.com/taikoxyz/taiko-client/internal/metrics" "github.com/taikoxyz/taiko-client/pkg/rpc" - "github.com/taikoxyz/taiko-client/pkg/sender" validator "github.com/taikoxyz/taiko-client/prover/anchor_tx_validator" proofProducer "github.com/taikoxyz/taiko-client/prover/proof_producer" "github.com/taikoxyz/taiko-client/prover/proof_submitter/transaction" @@ -41,7 +41,7 @@ func NewProofSubmitter( resultCh chan *proofProducer.ProofWithHeader, taikoL2Address common.Address, graffiti string, - txSender *sender.Sender, + txmgr *txmgr.SimpleTxManager, builder *transaction.ProveBlockTxBuilder, ) (*ProofSubmitter, error) { anchorValidator, err := validator.New(taikoL2Address, rpcClient.L2.ChainID, rpcClient) @@ -55,8 +55,8 @@ func NewProofSubmitter( resultCh: resultCh, anchorValidator: anchorValidator, txBuilder: builder, - sender: transaction.NewSender(rpcClient, txSender), - proverAddress: txSender.Address(), + sender: transaction.NewSender(rpcClient, txmgr, 0), + proverAddress: txmgr.From(), taikoL2Address: taikoL2Address, graffiti: rpc.StringToBytes32(graffiti), }, nil diff --git a/prover/proof_submitter/proof_submitter_test.go b/prover/proof_submitter/proof_submitter_test.go index 5a0da5163..19ae88d5b 100644 --- a/prover/proof_submitter/proof_submitter_test.go +++ b/prover/proof_submitter/proof_submitter_test.go @@ -7,9 +7,12 @@ import ( "testing" "time" + "github.com/ethereum-optimism/optimism/op-service/txmgr" + "github.com/ethereum-optimism/optimism/op-service/txmgr/metrics" "github.com/ethereum/go-ethereum/common" "github.com/ethereum/go-ethereum/core/types" "github.com/ethereum/go-ethereum/crypto" + "github.com/ethereum/go-ethereum/log" "github.com/stretchr/testify/suite" "github.com/taikoxyz/taiko-client/bindings" @@ -19,7 +22,6 @@ import ( "github.com/taikoxyz/taiko-client/driver/state" "github.com/taikoxyz/taiko-client/internal/testutils" "github.com/taikoxyz/taiko-client/pkg/rpc" - "github.com/taikoxyz/taiko-client/pkg/sender" "github.com/taikoxyz/taiko-client/proposer" producer "github.com/taikoxyz/taiko-client/prover/proof_producer" "github.com/taikoxyz/taiko-client/prover/proof_submitter/transaction" @@ -37,15 +39,38 @@ type ProofSubmitterTestSuite struct { func (s *ProofSubmitterTestSuite) SetupTest() { s.ClientTestSuite.SetupTest() - l1ProverPrivKey, err := crypto.ToECDSA(common.FromHex(os.Getenv("L1_PROVER_PRIVATE_KEY"))) - s.Nil(err) - s.proofCh = make(chan *producer.ProofWithHeader, 1024) - sender, err := sender.NewSender(context.Background(), &sender.Config{}, s.RPCClient.L1, l1ProverPrivKey) + builder := transaction.NewProveBlockTxBuilder( + s.RPCClient, + common.HexToAddress(os.Getenv("TAIKO_L1_ADDRESS")), + common.HexToAddress(os.Getenv("GUARDIAN_PROVER_CONTRACT_ADDRESS")), + ) + + l1ProverPrivKey, err := crypto.ToECDSA(common.FromHex(os.Getenv("L1_PROVER_PRIVATE_KEY"))) s.Nil(err) - builder := transaction.NewProveBlockTxBuilder(s.RPCClient) + txMgr, err := txmgr.NewSimpleTxManager( + "proofSubmitterTestSuite", + log.Root(), + new(metrics.NoopTxMetrics), + txmgr.CLIConfig{ + L1RPCURL: os.Getenv("L1_NODE_WS_ENDPOINT"), + NumConfirmations: 1, + SafeAbortNonceTooLowCount: txmgr.DefaultBatcherFlagValues.SafeAbortNonceTooLowCount, + PrivateKey: common.Bytes2Hex(crypto.FromECDSA(l1ProverPrivKey)), + FeeLimitMultiplier: txmgr.DefaultBatcherFlagValues.FeeLimitMultiplier, + FeeLimitThresholdGwei: txmgr.DefaultBatcherFlagValues.FeeLimitThresholdGwei, + MinBaseFeeGwei: txmgr.DefaultBatcherFlagValues.MinBaseFeeGwei, + MinTipCapGwei: txmgr.DefaultBatcherFlagValues.MinTipCapGwei, + ResubmissionTimeout: txmgr.DefaultBatcherFlagValues.ResubmissionTimeout, + ReceiptQueryInterval: 1 * time.Second, + NetworkTimeout: txmgr.DefaultBatcherFlagValues.NetworkTimeout, + TxSendTimeout: txmgr.DefaultBatcherFlagValues.TxSendTimeout, + TxNotInMempoolTimeout: txmgr.DefaultBatcherFlagValues.TxNotInMempoolTimeout, + }, + ) + s.Nil(err) s.submitter, err = NewProofSubmitter( s.RPCClient, @@ -53,13 +78,13 @@ func (s *ProofSubmitterTestSuite) SetupTest() { s.proofCh, common.HexToAddress(os.Getenv("TAIKO_L2_ADDRESS")), "test", - sender, + txMgr, builder, ) s.Nil(err) s.contester = NewProofContester( s.RPCClient, - sender, + txMgr, "test", builder, ) @@ -105,6 +130,21 @@ func (s *ProofSubmitterTestSuite) SetupTest() { MaxTierFeePriceBumps: 3, TierFeePriceBump: common.Big2, L1BlockBuilderTip: common.Big0, + TxmgrConfigs: &txmgr.CLIConfig{ + L1RPCURL: os.Getenv("L1_NODE_WS_ENDPOINT"), + NumConfirmations: 1, + SafeAbortNonceTooLowCount: txmgr.DefaultBatcherFlagValues.SafeAbortNonceTooLowCount, + PrivateKey: common.Bytes2Hex(crypto.FromECDSA(l1ProposerPrivKey)), + FeeLimitMultiplier: txmgr.DefaultBatcherFlagValues.FeeLimitMultiplier, + FeeLimitThresholdGwei: txmgr.DefaultBatcherFlagValues.FeeLimitThresholdGwei, + MinBaseFeeGwei: txmgr.DefaultBatcherFlagValues.MinBaseFeeGwei, + MinTipCapGwei: txmgr.DefaultBatcherFlagValues.MinTipCapGwei, + ResubmissionTimeout: txmgr.DefaultBatcherFlagValues.ResubmissionTimeout, + ReceiptQueryInterval: 1 * time.Second, + NetworkTimeout: txmgr.DefaultBatcherFlagValues.NetworkTimeout, + TxSendTimeout: txmgr.DefaultBatcherFlagValues.TxSendTimeout, + TxNotInMempoolTimeout: txmgr.DefaultBatcherFlagValues.TxNotInMempoolTimeout, + }, })) s.proposer = prop diff --git a/prover/proof_submitter/transaction/builder.go b/prover/proof_submitter/transaction/builder.go index 3c76c042d..13a2b388c 100644 --- a/prover/proof_submitter/transaction/builder.go +++ b/prover/proof_submitter/transaction/builder.go @@ -4,8 +4,9 @@ import ( "errors" "math/big" + "github.com/ethereum-optimism/optimism/op-service/txmgr" "github.com/ethereum/go-ethereum/accounts/abi/bind" - "github.com/ethereum/go-ethereum/core/types" + "github.com/ethereum/go-ethereum/common" "github.com/ethereum/go-ethereum/log" "github.com/taikoxyz/taiko-client/bindings" @@ -18,18 +19,22 @@ var ( ) // TxBuilder will build a transaction with the given nonce. -type TxBuilder func(txOpts *bind.TransactOpts) (*types.Transaction, error) +type TxBuilder func(txOpts *bind.TransactOpts) (*txmgr.TxCandidate, error) // ProveBlockTxBuilder is responsible for building ProveBlock transactions. type ProveBlockTxBuilder struct { - rpc *rpc.Client + rpc *rpc.Client + taikoL1Address common.Address + guardianProverAddress common.Address } // NewProveBlockTxBuilder creates a new ProveBlockTxBuilder instance. func NewProveBlockTxBuilder( rpc *rpc.Client, + taikoL1Address common.Address, + guardianProverAddress common.Address, ) *ProveBlockTxBuilder { - return &ProveBlockTxBuilder{rpc: rpc} + return &ProveBlockTxBuilder{rpc, taikoL1Address, guardianProverAddress} } // Build creates a new TaikoL1.ProveBlock transaction with the given nonce. @@ -40,35 +45,37 @@ func (a *ProveBlockTxBuilder) Build( tierProof *bindings.TaikoDataTierProof, guardian bool, ) TxBuilder { - return func(txOpts *bind.TransactOpts) (*types.Transaction, error) { + return func(txOpts *bind.TransactOpts) (*txmgr.TxCandidate, error) { var ( - tx *types.Transaction - err error + data []byte + to common.Address + err error ) log.Info( "Build proof submission transaction", "blockID", blockID, "gasLimit", txOpts.GasLimit, - "nonce", txOpts.Nonce, - "gasTipCap", txOpts.GasTipCap, - "gasFeeCap", txOpts.GasFeeCap, "guardian", guardian, ) if !guardian { + to = a.taikoL1Address + input, err := encoding.EncodeProveBlockInput(meta, transition, tierProof) if err != nil { return nil, err } - if tx, err = a.rpc.TaikoL1.ProveBlock(txOpts, blockID.Uint64(), input); err != nil { + if data, err = encoding.TaikoL1ABI.Pack("proveBlock", blockID.Uint64(), input); err != nil { if isSubmitProofTxErrorRetryable(err, blockID) { return nil, err } return nil, ErrUnretryableSubmission } } else { - if tx, err = a.rpc.GuardianProver.Approve(txOpts, *meta, *transition, *tierProof); err != nil { + to = a.guardianProverAddress + + if data, err = encoding.GuardianProverABI.Pack("approve", *meta, *transition, *tierProof); err != nil { if isSubmitProofTxErrorRetryable(err, blockID) { return nil, err } @@ -76,6 +83,12 @@ func (a *ProveBlockTxBuilder) Build( } } - return tx, nil + return &txmgr.TxCandidate{ + TxData: data, + To: &to, + Blobs: nil, + GasLimit: txOpts.GasLimit, + Value: txOpts.Value, + }, nil } } diff --git a/prover/proof_submitter/transaction/builder_test.go b/prover/proof_submitter/transaction/builder_test.go index 1b847b3c2..389504209 100644 --- a/prover/proof_submitter/transaction/builder_test.go +++ b/prover/proof_submitter/transaction/builder_test.go @@ -1,8 +1,7 @@ package transaction import ( - "context" - + "github.com/ethereum/go-ethereum/accounts/abi/bind" "github.com/ethereum/go-ethereum/common" "github.com/taikoxyz/taiko-client/bindings" @@ -15,15 +14,6 @@ func (s *TransactionTestSuite) TestBuildTxs() { &bindings.TaikoDataTransition{}, &bindings.TaikoDataTierProof{}, false, - )(s.sender.innerSender.GetOpts(context.Background())) - s.NotNil(err) - - _, err = s.builder.Build( - common.Big256, - &bindings.TaikoDataBlockMetadata{}, - &bindings.TaikoDataTransition{}, - &bindings.TaikoDataTierProof{}, - true, - )(s.sender.innerSender.GetOpts(context.Background())) - s.NotNil(err) + )(&bind.TransactOpts{Nonce: common.Big0, GasLimit: 0, GasTipCap: common.Big0}) + s.Nil(err) } diff --git a/prover/proof_submitter/transaction/sender.go b/prover/proof_submitter/transaction/sender.go index eda4ae085..322496dee 100644 --- a/prover/proof_submitter/transaction/sender.go +++ b/prover/proof_submitter/transaction/sender.go @@ -2,32 +2,37 @@ package transaction import ( "context" + "fmt" "math/big" "strings" + "github.com/ethereum-optimism/optimism/op-service/txmgr" "github.com/ethereum/go-ethereum/accounts/abi/bind" + "github.com/ethereum/go-ethereum/core/types" "github.com/ethereum/go-ethereum/log" "github.com/taikoxyz/taiko-client/internal/metrics" "github.com/taikoxyz/taiko-client/pkg/rpc" - "github.com/taikoxyz/taiko-client/pkg/sender" producer "github.com/taikoxyz/taiko-client/prover/proof_producer" ) // Sender is responsible for sending proof submission transactions with a backoff policy. type Sender struct { - rpc *rpc.Client - innerSender *sender.Sender + rpc *rpc.Client + txmgr *txmgr.SimpleTxManager + gasLimit uint64 } // NewSender creates a new Sener instance. func NewSender( cli *rpc.Client, - txSender *sender.Sender, + txmgr *txmgr.SimpleTxManager, + gasLimit uint64, ) *Sender { return &Sender{ - rpc: cli, - innerSender: txSender, + rpc: cli, + txmgr: txmgr, + gasLimit: gasLimit, } } @@ -44,26 +49,19 @@ func (s *Sender) Send( } // Assemble the TaikoL1.proveBlock transaction. - tx, err := buildTx(s.innerSender.GetOpts(ctx)) + txCandidate, err := buildTx(&bind.TransactOpts{GasLimit: s.gasLimit}) if err != nil { return err } // Send the transaction. - id, err := s.innerSender.SendTransaction(tx) + receipt, err := s.txmgr.Send(ctx, *txCandidate) if err != nil { return err } - // Waiting for the transaction to be confirmed. - confirmationResult := <-s.innerSender.TxToConfirmChannel(id) - if confirmationResult.Err != nil { - log.Warn( - "Failed to send TaikoL1.proveBlock transaction", - "blockID", proofWithHeader.BlockID, - "error", confirmationResult.Err, - ) - return confirmationResult.Err + if receipt.Status != types.ReceiptStatusSuccessful { + return fmt.Errorf("failed to submit proof: %s", receipt.TxHash) } log.Info( @@ -72,7 +70,7 @@ func (s *Sender) Send( "parentHash", proofWithHeader.Header.ParentHash, "hash", proofWithHeader.Header.Hash(), "stateRoot", proofWithHeader.Opts.StateRoot, - "txHash", confirmationResult.CurrentTx.Hash(), + "txHash", receipt.TxHash, "tier", proofWithHeader.Tier, "isContest", len(proofWithHeader.Proof) == 0, ) diff --git a/prover/proof_submitter/transaction/sender_test.go b/prover/proof_submitter/transaction/sender_test.go index 0ea7686f2..82d816ad3 100644 --- a/prover/proof_submitter/transaction/sender_test.go +++ b/prover/proof_submitter/transaction/sender_test.go @@ -6,16 +6,19 @@ import ( "math/big" "os" "testing" + "time" + "github.com/ethereum-optimism/optimism/op-service/txmgr" + "github.com/ethereum-optimism/optimism/op-service/txmgr/metrics" "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/crypto" + "github.com/ethereum/go-ethereum/log" "github.com/stretchr/testify/suite" "github.com/taikoxyz/taiko-client/bindings" "github.com/taikoxyz/taiko-client/internal/testutils" - "github.com/taikoxyz/taiko-client/pkg/sender" producer "github.com/taikoxyz/taiko-client/prover/proof_producer" ) @@ -33,15 +36,38 @@ type TransactionTestSuite struct { func (s *TransactionTestSuite) SetupTest() { s.ClientTestSuite.SetupTest() + s.builder = NewProveBlockTxBuilder( + s.RPCClient, + common.HexToAddress(os.Getenv("TAIKO_L1_ADDRESS")), + common.HexToAddress(os.Getenv("GUARDIAN_PROVER_CONTRACT_ADDRESS")), + ) + l1ProverPrivKey, err := crypto.ToECDSA(common.FromHex(os.Getenv("L1_PROVER_PRIVATE_KEY"))) s.Nil(err) - txSender, err := sender.NewSender(context.Background(), &sender.Config{}, s.RPCClient.L1, l1ProverPrivKey) + txmgr, err := txmgr.NewSimpleTxManager( + "transactionTestSuite", + log.Root(), + new(metrics.NoopTxMetrics), + txmgr.CLIConfig{ + L1RPCURL: os.Getenv("L1_NODE_WS_ENDPOINT"), + NumConfirmations: 1, + SafeAbortNonceTooLowCount: txmgr.DefaultBatcherFlagValues.SafeAbortNonceTooLowCount, + PrivateKey: common.Bytes2Hex(crypto.FromECDSA(l1ProverPrivKey)), + FeeLimitMultiplier: txmgr.DefaultBatcherFlagValues.FeeLimitMultiplier, + FeeLimitThresholdGwei: txmgr.DefaultBatcherFlagValues.FeeLimitThresholdGwei, + MinBaseFeeGwei: txmgr.DefaultBatcherFlagValues.MinBaseFeeGwei, + MinTipCapGwei: txmgr.DefaultBatcherFlagValues.MinTipCapGwei, + ResubmissionTimeout: txmgr.DefaultBatcherFlagValues.ResubmissionTimeout, + ReceiptQueryInterval: 1 * time.Second, + NetworkTimeout: txmgr.DefaultBatcherFlagValues.NetworkTimeout, + TxSendTimeout: txmgr.DefaultBatcherFlagValues.TxSendTimeout, + TxNotInMempoolTimeout: txmgr.DefaultBatcherFlagValues.TxNotInMempoolTimeout, + }, + ) s.Nil(err) - s.sender = NewSender(s.RPCClient, txSender) - - s.builder = NewProveBlockTxBuilder(s.RPCClient) + s.sender = NewSender(s.RPCClient, txmgr, 0) } func (s *TransactionTestSuite) TestIsSubmitProofTxErrorRetryable() { @@ -65,7 +91,7 @@ func (s *TransactionTestSuite) TestSendTxWithBackoff() { Header: &types.Header{}, Opts: &producer.ProofRequestOptions{EventL1Hash: l1Head.Hash()}, }, - func(*bind.TransactOpts) (*types.Transaction, error) { return nil, errors.New("L1_TEST") }, + func(*bind.TransactOpts) (*txmgr.TxCandidate, error) { return nil, errors.New("L1_TEST") }, )) s.Nil(s.sender.Send( @@ -76,7 +102,7 @@ func (s *TransactionTestSuite) TestSendTxWithBackoff() { Header: &types.Header{}, Opts: &producer.ProofRequestOptions{EventL1Hash: l1Head.Hash()}, }, - func(*bind.TransactOpts) (*types.Transaction, error) { + func(*bind.TransactOpts) (*txmgr.TxCandidate, error) { height, err := s.RPCClient.L1.BlockNumber(context.Background()) s.Nil(err) @@ -90,7 +116,15 @@ func (s *TransactionTestSuite) TestSendTxWithBackoff() { height-- } - return block.Transactions()[0], nil + tx := block.Transactions()[0] + + return &txmgr.TxCandidate{ + TxData: tx.Data(), + Blobs: nil, + To: tx.To(), + GasLimit: tx.Gas(), + Value: tx.Value(), + }, nil }, )) } diff --git a/prover/prover.go b/prover/prover.go index 6fd8af26e..228415002 100644 --- a/prover/prover.go +++ b/prover/prover.go @@ -10,6 +10,8 @@ import ( "time" "github.com/cenkalti/backoff/v4" + "github.com/ethereum-optimism/optimism/op-service/txmgr" + "github.com/ethereum-optimism/optimism/op-service/txmgr/metrics" "github.com/ethereum/go-ethereum/accounts/abi/bind" "github.com/ethereum/go-ethereum/common" "github.com/ethereum/go-ethereum/log" @@ -20,7 +22,6 @@ import ( "github.com/taikoxyz/taiko-client/internal/version" eventIterator "github.com/taikoxyz/taiko-client/pkg/chain_iterator/event_iterator" "github.com/taikoxyz/taiko-client/pkg/rpc" - "github.com/taikoxyz/taiko-client/pkg/sender" handler "github.com/taikoxyz/taiko-client/prover/event_handler" guardianProverHeartbeater "github.com/taikoxyz/taiko-client/prover/guardian_prover_heartbeater" proofProducer "github.com/taikoxyz/taiko-client/prover/proof_producer" @@ -36,8 +37,6 @@ type Prover struct { cfg *Config backoff backoff.BackOffContext - txSender *sender.Sender - // Clients rpc *rpc.Client @@ -71,6 +70,9 @@ type Prover struct { proofContestCh chan *proofProducer.ContestRequestBody proofGenerationCh chan *proofProducer.ProofWithHeader + // Transactions manager + txmgr *txmgr.SimpleTxManager + ctx context.Context wg sync.WaitGroup } @@ -139,37 +141,26 @@ func InitFromConfig(ctx context.Context, p *Prover, cfg *Config) (err error) { } p.sharedState.SetTiers(tiers) - senderCfg := &sender.Config{ - ConfirmationDepth: 0, - MaxRetrys: p.cfg.ProofSubmissionMaxRetry, - GasGrowthRate: p.cfg.ProveBlockTxReplacementGasGrowthRate, - } - if p.cfg.ProveBlockGasLimit != nil { - senderCfg.GasLimit = *p.cfg.ProveBlockGasLimit - } - if p.cfg.ProveBlockMaxTxGasFeeCap != nil { - senderCfg.MaxGasFee = p.cfg.ProveBlockMaxTxGasFeeCap.Uint64() - } - // For guardian provers we always simply keep retrying for each its proof submission. - if p.IsGuardianProver() && senderCfg.MaxRetrys != 0 { - senderCfg.MaxRetrys = 0 - } + txBuilder := transaction.NewProveBlockTxBuilder(p.rpc, p.cfg.TaikoL1Address, p.cfg.GuardianProverAddress) - p.txSender, err = sender.NewSender(p.ctx, senderCfg, p.rpc.L1, p.cfg.L1ProverPrivKey) - if err != nil { + if p.txmgr, err = txmgr.NewSimpleTxManager( + "prover", + log.Root(), + new(metrics.NoopTxMetrics), + *cfg.TxmgrConfigs, + ); err != nil { return err } - txBuilder := transaction.NewProveBlockTxBuilder(p.rpc) // Proof submitters - if err := p.initProofSubmitters(p.txSender, txBuilder); err != nil { + if err := p.initProofSubmitters(p.txmgr, txBuilder); err != nil { return err } // Proof contester p.proofContester = proofSubmitter.NewProofContester( p.rpc, - p.txSender, + p.txmgr, p.cfg.Graffiti, txBuilder, ) @@ -444,7 +435,7 @@ func (p *Prover) IsGuardianProver() bool { // ProverAddress returns the current prover account address. func (p *Prover) ProverAddress() common.Address { - return p.txSender.Address() + return p.txmgr.From() } // withRetry retries the given function with prover backoff policy. diff --git a/prover/prover_test.go b/prover/prover_test.go index db76e6d73..31382fee2 100644 --- a/prover/prover_test.go +++ b/prover/prover_test.go @@ -10,6 +10,7 @@ import ( "testing" "time" + "github.com/ethereum-optimism/optimism/op-service/txmgr" "github.com/ethereum/go-ethereum/accounts/abi/bind" "github.com/ethereum/go-ethereum/common" "github.com/ethereum/go-ethereum/core/types" @@ -25,6 +26,7 @@ import ( "github.com/taikoxyz/taiko-client/proposer" guardianProverHeartbeater "github.com/taikoxyz/taiko-client/prover/guardian_prover_heartbeater" producer "github.com/taikoxyz/taiko-client/prover/proof_producer" + "github.com/taikoxyz/taiko-client/prover/proof_submitter/transaction" ) type ProverTestSuite struct { @@ -90,6 +92,21 @@ func (s *ProverTestSuite) SetupTest() { MaxTierFeePriceBumps: 3, TierFeePriceBump: common.Big2, L1BlockBuilderTip: common.Big0, + TxmgrConfigs: &txmgr.CLIConfig{ + L1RPCURL: os.Getenv("L1_NODE_WS_ENDPOINT"), + NumConfirmations: 1, + SafeAbortNonceTooLowCount: txmgr.DefaultBatcherFlagValues.SafeAbortNonceTooLowCount, + PrivateKey: common.Bytes2Hex(crypto.FromECDSA(l1ProposerPrivKey)), + FeeLimitMultiplier: txmgr.DefaultBatcherFlagValues.FeeLimitMultiplier, + FeeLimitThresholdGwei: txmgr.DefaultBatcherFlagValues.FeeLimitThresholdGwei, + MinBaseFeeGwei: txmgr.DefaultBatcherFlagValues.MinBaseFeeGwei, + MinTipCapGwei: txmgr.DefaultBatcherFlagValues.MinTipCapGwei, + ResubmissionTimeout: txmgr.DefaultBatcherFlagValues.ResubmissionTimeout, + ReceiptQueryInterval: 1 * time.Second, + NetworkTimeout: txmgr.DefaultBatcherFlagValues.NetworkTimeout, + TxSendTimeout: txmgr.DefaultBatcherFlagValues.TxSendTimeout, + TxNotInMempoolTimeout: txmgr.DefaultBatcherFlagValues.TxNotInMempoolTimeout, + }, })) s.proposer = prop @@ -106,23 +123,37 @@ func (s *ProverTestSuite) TestInitError() { s.Nil(err) p := new(Prover) - // Error should be "context canceled", instead is "Dial ethclient error:" + s.ErrorContains(InitFromConfig(ctx, p, &Config{ - L1WsEndpoint: os.Getenv("L1_NODE_WS_ENDPOINT"), - L1HttpEndpoint: os.Getenv("L1_NODE_HTTP_ENDPOINT"), - L2WsEndpoint: os.Getenv("L2_EXECUTION_ENGINE_WS_ENDPOINT"), - L2HttpEndpoint: os.Getenv("L2_EXECUTION_ENGINE_HTTP_ENDPOINT"), - TaikoL1Address: common.HexToAddress(os.Getenv("TAIKO_L1_ADDRESS")), - TaikoL2Address: common.HexToAddress(os.Getenv("TAIKO_L2_ADDRESS")), - TaikoTokenAddress: common.HexToAddress(os.Getenv("TAIKO_TOKEN_ADDRESS")), - AssignmentHookAddress: common.HexToAddress(os.Getenv("ASSIGNMENT_HOOK_CONTRACT_ADDRESS")), - L1ProverPrivKey: l1ProverPrivKey, - Dummy: true, - ProveUnassignedBlocks: true, - ProveBlockTxReplacementGasGrowthRate: 2, - RPCTimeout: 10 * time.Minute, - BackOffRetryInterval: 3 * time.Second, - BackOffMaxRetrys: 12, + L1WsEndpoint: os.Getenv("L1_NODE_WS_ENDPOINT"), + L1HttpEndpoint: os.Getenv("L1_NODE_HTTP_ENDPOINT"), + L2WsEndpoint: os.Getenv("L2_EXECUTION_ENGINE_WS_ENDPOINT"), + L2HttpEndpoint: os.Getenv("L2_EXECUTION_ENGINE_HTTP_ENDPOINT"), + TaikoL1Address: common.HexToAddress(os.Getenv("TAIKO_L1_ADDRESS")), + TaikoL2Address: common.HexToAddress(os.Getenv("TAIKO_L2_ADDRESS")), + TaikoTokenAddress: common.HexToAddress(os.Getenv("TAIKO_TOKEN_ADDRESS")), + AssignmentHookAddress: common.HexToAddress(os.Getenv("ASSIGNMENT_HOOK_CONTRACT_ADDRESS")), + L1ProverPrivKey: l1ProverPrivKey, + Dummy: true, + ProveUnassignedBlocks: true, + RPCTimeout: 10 * time.Minute, + BackOffRetryInterval: 3 * time.Second, + BackOffMaxRetrys: 12, + TxmgrConfigs: &txmgr.CLIConfig{ + L1RPCURL: os.Getenv("L1_NODE_WS_ENDPOINT"), + NumConfirmations: 1, + SafeAbortNonceTooLowCount: txmgr.DefaultBatcherFlagValues.SafeAbortNonceTooLowCount, + PrivateKey: common.Bytes2Hex(crypto.FromECDSA(l1ProverPrivKey)), + FeeLimitMultiplier: txmgr.DefaultBatcherFlagValues.FeeLimitMultiplier, + FeeLimitThresholdGwei: txmgr.DefaultBatcherFlagValues.FeeLimitThresholdGwei, + MinBaseFeeGwei: txmgr.DefaultBatcherFlagValues.MinBaseFeeGwei, + MinTipCapGwei: txmgr.DefaultBatcherFlagValues.MinTipCapGwei, + ResubmissionTimeout: txmgr.DefaultBatcherFlagValues.ResubmissionTimeout, + ReceiptQueryInterval: 1 * time.Second, + NetworkTimeout: txmgr.DefaultBatcherFlagValues.NetworkTimeout, + TxSendTimeout: txmgr.DefaultBatcherFlagValues.TxSendTimeout, + TxNotInMempoolTimeout: txmgr.DefaultBatcherFlagValues.TxNotInMempoolTimeout, + }, }), "dial tcp:") } @@ -268,11 +299,17 @@ func (s *ProverTestSuite) TestContestWrongBlocks() { s.p.cfg.GuardianProverAddress = common.HexToAddress(os.Getenv("GUARDIAN_PROVER_CONTRACT_ADDRESS")) s.True(s.p.IsGuardianProver()) + txBuilder := transaction.NewProveBlockTxBuilder(s.p.rpc, s.p.cfg.TaikoL1Address, s.p.cfg.GuardianProverAddress) + s.p.proofSubmitters = nil + s.Nil(s.p.initProofSubmitters(s.p.txmgr, txBuilder)) + s.p.rpc.GuardianProver, err = bindings.NewGuardianProver(s.p.cfg.GuardianProverAddress, s.p.rpc.L1) s.Nil(err) - approvedSink := make(chan *bindings.GuardianProverApproved) - approvedSub, err := s.p.rpc.GuardianProver.WatchApproved(nil, approvedSink, [](*big.Int){}) + approvedSink := make(chan *bindings.GuardianProverGuardianApproval) + approvedSub, err := s.p.rpc.GuardianProver.WatchGuardianApproval( + nil, approvedSink, []common.Address{}, [](*big.Int){}, + ) s.Nil(err) defer func() { approvedSub.Unsubscribe() @@ -283,7 +320,7 @@ func (s *ProverTestSuite) TestContestWrongBlocks() { s.Nil(s.p.selectSubmitter(encoding.TierGuardianID).SubmitProof(context.Background(), <-s.p.proofGenerationCh)) approvedEvent := <-approvedSink - s.Equal(header.Number.Uint64(), approvedEvent.OperationId.Uint64()) + s.Equal(header.Number.Uint64(), approvedEvent.BlockId.Uint64()) } func (s *ProverTestSuite) TestProveExpiredUnassignedBlock() { @@ -477,6 +514,21 @@ func (s *ProverTestSuite) initProver( BackOffMaxRetrys: 12, L1NodeVersion: "1.0.0", L2NodeVersion: "0.1.0", + TxmgrConfigs: &txmgr.CLIConfig{ + L1RPCURL: os.Getenv("L1_NODE_WS_ENDPOINT"), + NumConfirmations: 1, + SafeAbortNonceTooLowCount: txmgr.DefaultBatcherFlagValues.SafeAbortNonceTooLowCount, + PrivateKey: common.Bytes2Hex(crypto.FromECDSA(key)), + FeeLimitMultiplier: txmgr.DefaultBatcherFlagValues.FeeLimitMultiplier, + FeeLimitThresholdGwei: txmgr.DefaultBatcherFlagValues.FeeLimitThresholdGwei, + MinBaseFeeGwei: txmgr.DefaultBatcherFlagValues.MinBaseFeeGwei, + MinTipCapGwei: txmgr.DefaultBatcherFlagValues.MinTipCapGwei, + ResubmissionTimeout: txmgr.DefaultBatcherFlagValues.ResubmissionTimeout, + ReceiptQueryInterval: 1 * time.Second, + NetworkTimeout: txmgr.DefaultBatcherFlagValues.NetworkTimeout, + TxSendTimeout: txmgr.DefaultBatcherFlagValues.TxSendTimeout, + TxNotInMempoolTimeout: txmgr.DefaultBatcherFlagValues.TxNotInMempoolTimeout, + }, })) p.server = s.NewTestProverServer( key,