diff --git a/buf.gen.yaml b/buf.gen.yaml deleted file mode 100644 index 6275bdee31..0000000000 --- a/buf.gen.yaml +++ /dev/null @@ -1,6 +0,0 @@ -version: v1 -plugins: - - plugin: buf.build/protocolbuffers/go:v1.31.0 - out: pb - opt: paths=source_relative - diff --git a/eth/tracers/firehose.go b/eth/tracers/firehose.go index 645e6405ef..573c99c727 100644 --- a/eth/tracers/firehose.go +++ b/eth/tracers/firehose.go @@ -29,9 +29,9 @@ import ( "github.com/ethereum/go-ethereum/internal/version" "github.com/ethereum/go-ethereum/log" "github.com/ethereum/go-ethereum/params" - pbeth "github.com/ethereum/go-ethereum/pb/sf/ethereum/type/v2" "github.com/ethereum/go-ethereum/rlp" "github.com/holiman/uint256" + pbeth "github.com/streamingfast/firehose-ethereum/types/pb/sf/ethereum/type/v2" "golang.org/x/exp/maps" "google.golang.org/protobuf/proto" "google.golang.org/protobuf/types/known/timestamppb" @@ -158,6 +158,7 @@ type Firehose struct { blockReorderOrdinal bool blockReorderOrdinalSnapshot uint64 blockReorderOrdinalOnce sync.Once + blockIsGenesis bool // Transaction state evm *tracing.VMContext @@ -279,6 +280,7 @@ func (f *Firehose) resetBlock() { f.blockReorderOrdinal = false f.blockReorderOrdinalSnapshot = 0 f.blockReorderOrdinalOnce = sync.Once{} + f.blockIsGenesis = false } // resetTransaction resets the transaction state and the call state in one shot @@ -536,7 +538,7 @@ func (f *Firehose) OnSystemCallEnd() { } func (f *Firehose) OnTxStart(evm *tracing.VMContext, tx *types.Transaction, from common.Address) { - firehoseInfo("trx start (tracer=%s hash=%s type=%d gas=%d isolated=%t input=%s)", f.tracerID, tx.Hash(), tx.Type(), tx.Gas(), f.transactionIsolated, inputView(tx.Data())) + firehoseInfo("trx start (tracer=%s hash=%s %s type=%d gas=%d isolated=%t input=%s)", f.tracerID, tx.Hash(), fromToTxView(&from, tx), tx.Type(), tx.Gas(), f.transactionIsolated, inputView(tx.Data())) f.ensureInBlockAndNotInTrxAndNotInCall() @@ -557,12 +559,7 @@ func (f *Firehose) OnTxStart(evm *tracing.VMContext, tx *types.Transaction, from func (f *Firehose) onTxStart(tx *types.Transaction, hash common.Hash, from, to common.Address) { v, r, s := tx.RawSignatureValues() - var blobGas *uint64 - if tx.Type() == types.BlobTxType { - blobGas = ptr(tx.BlobGas()) - } - - f.transaction = &pbeth.TransactionTrace{ + trx := &pbeth.TransactionTrace{ BeginOrdinal: f.blockOrdinal.Next(), Hash: hash.Bytes(), From: from.Bytes(), @@ -579,14 +576,23 @@ func (f *Firehose) onTxStart(tx *types.Transaction, hash common.Hash, from, to c AccessList: newAccessListFromChain(tx.AccessList()), MaxFeePerGas: maxFeePerGas(tx), MaxPriorityFeePerGas: maxPriorityFeePerGas(tx), - BlobGas: blobGas, - BlobGasFeeCap: firehoseBigIntFromNative(tx.BlobGasFeeCap()), - BlobHashes: newBlobHashesFromChain(tx.BlobHashes()), } + + switch tx.Type() { + case types.BlobTxType: + trx.BlobGas = ptr(tx.BlobGas()) + trx.BlobGasFeeCap = firehoseBigIntFromNative(tx.BlobGasFeeCap()) + trx.BlobHashes = newBlobHashesFromChain(tx.BlobHashes()) + + case types.SetCodeTxType: + trx.SetCodeAuthorizations = newSetCodeAuthorizationsFromChain(tx.SetCodeAuthorizations()) + } + + f.transaction = trx } func (f *Firehose) OnTxEnd(receipt *types.Receipt, err error) { - firehoseInfo("trx ending (tracer=%s, isolated=%t, error=%s)", f.tracerID, f.transactionIsolated, errorView(err)) + firehoseInfo("trx ending (tracer=%s, isolated=%t, err=%s)", f.tracerID, f.transactionIsolated, errorView(err)) f.ensureInBlockAndInTrx() trxTrace := f.completeTransaction(receipt) @@ -613,7 +619,7 @@ func (f *Firehose) OnTxEnd(receipt *types.Receipt, err error) { } func (f *Firehose) completeTransaction(receipt *types.Receipt) *pbeth.TransactionTrace { - firehoseInfo("completing transaction (call_count=%d receipt=%s)", len(f.transaction.Calls), (*receiptView)(receipt)) + firehoseInfo("completing transaction (call_count=%d receipt=%s)", len(f.transaction.Calls), receiptView(receipt)) // Sorting needs to happen first, before we populate the state reverted slices.SortFunc(f.transaction.Calls, func(i, j *pbeth.Call) int { @@ -622,6 +628,10 @@ func (f *Firehose) completeTransaction(receipt *types.Receipt) *pbeth.Transactio rootCall := f.transaction.Calls[0] + // Can be done prior moving last deferred call state to the root call as we are only interested from the initial + // deferred state that already been transferred into the root call (in `onCallStart(...)`). + f.discardUncommittedSetCodeAuthorization(rootCall) + if !f.deferredCallState.IsEmpty() { f.deferredCallState.MaybePopulateCallAndReset("root", rootCall) } @@ -686,6 +696,39 @@ func (f *Firehose) populateStateReverted() { } } +// discardUncommittedSetCodeAuthorization set `discarded = true` for all the SetCodeAuthorization element +// that don't have a corresponding NonceChange coming from the root call of the transaction, which +// means they weren't committed to the state. +// +// Indeed, EIP-7702 states that are invalid SetCodeAuthorization is simply discard and it's not recorded +// to chain's state. +func (f *Firehose) discardUncommittedSetCodeAuthorization(rootCall *pbeth.Call) { + usedNonceChange := map[int]bool{} + findNonceChange := func(forAddress []byte, nonce uint64) *pbeth.NonceChange { + for i, change := range rootCall.NonceChanges { + if change.OldValue == nonce && change.NewValue == nonce+1 && bytes.Equal(change.Address, forAddress) && usedNonceChange[i] == false { + usedNonceChange[i] = true + return change + } + } + + return nil + } + + for _, auth := range f.transaction.SetCodeAuthorizations { + if len(auth.Authority) == 0 { + // Nothing to check, authority is empty, it's not a valid authorization + auth.Discarded = true + continue + } + + if findNonceChange(auth.Authority, auth.Nonce) == nil { + firehoseDebug("discarded set code authorization, no corresponding nonce change found (address=%s nonce=%d)", hex.EncodeToString(auth.Authority), auth.Nonce) + auth.Discarded = true + } + } +} + func (f *Firehose) removeLogBlockIndexOnStateRevertedCalls() { for _, call := range f.transaction.Calls { if call.StateReverted { @@ -995,7 +1038,7 @@ func (f *Firehose) captureInterpreterStep(activeCall *pbeth.Call, pc uint64, op } func (f *Firehose) callStart(source string, callType pbeth.CallType, from common.Address, to common.Address, input []byte, gas uint64, value *big.Int) { - firehoseDebug("call start (source=%s index=%d type=%s input=%s)", source, f.callStack.NextIndex(), callType, inputView(input)) + firehoseDebug("call start (source=%s index=%d type=%s ref=%s input=%s)", source, f.callStack.NextIndex(), callType, fromToView(&from, &to), inputView(input)) f.ensureInBlockAndInTrx() if *f.applyBackwardCompatibility { @@ -1018,6 +1061,18 @@ func (f *Firehose) callStart(source string, callType pbeth.CallType, from common GasLimit: gas, } + if f.blockRules.IsPrague && !f.inSystemCall && !f.blockIsGenesis && callType != pbeth.CallType_CREATE { + firehoseTrace("call resolving delegation (from=%s)", from) + + code := f.evm.StateDB.GetCode(to) + if len(code) != 0 { + if target, ok := types.ParseDelegation(code); ok { + firehoseDebug("call resolved delegation (from=%s, delegates_to=%s)", from, target) + call.AddressDelegatesTo = target.Bytes() + } + } + } + if *f.applyBackwardCompatibility { // Known Firehose issue: The BeginOrdinal of the genesis block root call is never actually // incremented and it's always 0. @@ -1174,6 +1229,9 @@ func (f *Firehose) OnGenesisBlock(b *types.Block, alloc types.GenesisAlloc) { f.ensureBlockChainInit() + // Going to be reset in OnBlockEnd + f.blockIsGenesis = true + f.OnBlockStart(tracing.BlockEvent{Block: b, Finalized: nil, Safe: nil}) f.onTxStart(types.NewTx(&types.LegacyTx{}), emptyCommonHash, emptyCommonAddress, emptyCommonAddress) f.OnCallEnter(0, byte(vm.CALL), emptyCommonAddress, emptyCommonAddress, nil, 0, nil) @@ -1260,7 +1318,7 @@ func (f *Firehose) OnBalanceChange(a common.Address, prev, new *big.Int, reason } func (f *Firehose) newBalanceChange(tag string, address common.Address, oldValue, newValue *big.Int, reason pbeth.BalanceChange_Reason) *pbeth.BalanceChange { - firehoseTrace("balance changed (tag=%s before=%d after=%d reason=%s)", tag, oldValue, newValue, reason) + firehoseTrace("balance changed (tag=%s address=%s before=%d after=%d reason=%s)", tag, shortAddressView(&address), oldValue, newValue, reason) if reason == pbeth.BalanceChange_REASON_UNKNOWN { panic(fmt.Errorf("received unknown balance change reason %s", reason)) @@ -1302,8 +1360,14 @@ func (f *Firehose) OnCodeChange(a common.Address, prevCodeHash common.Hash, prev if f.transaction != nil { activeCall := f.callStack.Peek() + + // Since EIP-7702 and the introduction of the `SetCode` transaction, a traced `StateDB.SetCode(...)` call + // is now happening within the "bootstrap" transaction phase which happens before any call is made. So + // in the event there is no active call, we push the code change to the deferred state and will be applied + // on the root call when it's finally created. if activeCall == nil { - f.panicInvalidState("caller expected to be in call state but we were not, this is a bug", 0) + f.deferredCallState.codeChanges = append(f.deferredCallState.codeChanges, f.newCodeChange(a, prevCodeHash, prev, codeHash, code)) + return } // Geth 1.14.12 introduced a new behavior where a code change is emitted when a contract @@ -1325,28 +1389,25 @@ func (f *Firehose) OnCodeChange(a common.Address, prevCodeHash common.Hash, prev return } - activeCall.CodeChanges = append(activeCall.CodeChanges, &pbeth.CodeChange{ - Address: a.Bytes(), - OldHash: prevCodeHash.Bytes(), - OldCode: prev, - NewHash: codeHash.Bytes(), - NewCode: code, - Ordinal: f.blockOrdinal.Next(), - }) + activeCall.CodeChanges = append(activeCall.CodeChanges, f.newCodeChange(a, prevCodeHash, prev, codeHash, code)) } else { - f.block.CodeChanges = append(f.block.CodeChanges, &pbeth.CodeChange{ - Address: a.Bytes(), - OldHash: prevCodeHash.Bytes(), - OldCode: prev, - NewHash: codeHash.Bytes(), - NewCode: code, - Ordinal: f.blockOrdinal.Next(), - }) + f.block.CodeChanges = append(f.block.CodeChanges, f.newCodeChange(a, prevCodeHash, prev, codeHash, code)) + } +} + +func (f *Firehose) newCodeChange(addr common.Address, prevCodeHash common.Hash, prev []byte, codeHash common.Hash, code []byte) *pbeth.CodeChange { + return &pbeth.CodeChange{ + Address: addr.Bytes(), + OldHash: prevCodeHash.Bytes(), + OldCode: prev, + NewHash: codeHash.Bytes(), + NewCode: code, + Ordinal: f.blockOrdinal.Next(), } } func (f *Firehose) OnStorageChange(a common.Address, k, prev, new common.Hash) { - firehoseTrace("storage changed (key=%s, before=%s after=%s)", k, prev, new) + firehoseTrace("storage changed (address=%s key=%s, before=%s after=%s)", shortAddressView(&a), k, prev, new) f.ensureInBlockAndInTrxAndInCall() @@ -1609,7 +1670,7 @@ func (f *Firehose) printBlockToFirehose(block *pbeth.Block, finalityStatus *Fina } // **Important* The final space in the Sprintf template is mandatory! - f.outputBuffer.WriteString(fmt.Sprintf("FIRE BLOCK %d %s %d %s %d %d ", block.Number, hex.EncodeToString(block.Hash), previousNum, previousHash, libNum, block.Time().UnixNano())) + f.outputBuffer.WriteString(fmt.Sprintf("FIRE BLOCK %d %s %d %s %d %d ", block.Number, hex.EncodeToString(block.Hash), previousNum, previousHash, libNum, block.MustTime().UnixNano())) encoder := base64.NewEncoder(base64.StdEncoding, f.outputBuffer) if _, err = encoder.Write(marshalled); err != nil { @@ -1860,6 +1921,37 @@ func newBlobHashesFromChain(blobHashes []common.Hash) (out [][]byte) { return } +func newSetCodeAuthorizationsFromChain(authorizations []types.SetCodeAuthorization) (out []*pbeth.SetCodeAuthorization) { + if len(authorizations) == 0 { + return nil + } + + out = make([]*pbeth.SetCodeAuthorization, len(authorizations)) + for i, authorization := range authorizations { + pbAuthorization := &pbeth.SetCodeAuthorization{ + ChainId: authorization.ChainID.Bytes(), + Nonce: authorization.Nonce, + V: uint32(authorization.V), + R: normalizeSignaturePoint(authorization.R.Bytes()), + S: normalizeSignaturePoint(authorization.S.Bytes()), + } + + authority, err := authorization.Authority() + if err != nil { + // The node skips invalid authorizations, we do the same, at transaction's end, we will + // also remove authorizations that didn't result into a code change. + firehoseDebug("failed to compute authority for authorization at index %d (err=%s)", i, errorView(err)) + pbAuthorization.Discarded = true + } else { + pbAuthorization.Authority = authority.Bytes() + } + + out[i] = pbAuthorization + } + + return +} + var balanceChangeReasonToPb = map[tracing.BalanceChangeReason]pbeth.BalanceChange_Reason{ tracing.BalanceIncreaseRewardMineUncle: pbeth.BalanceChange_REASON_REWARD_MINE_UNCLE, tracing.BalanceIncreaseRewardMineBlock: pbeth.BalanceChange_REASON_REWARD_MINE_BLOCK, @@ -2113,6 +2205,7 @@ type DeferredCallState struct { balanceChanges []*pbeth.BalanceChange gasChanges []*pbeth.GasChange nonceChanges []*pbeth.NonceChange + codeChanges []*pbeth.CodeChange } func NewDeferredCallState() *DeferredCallState { @@ -2133,6 +2226,7 @@ func (d *DeferredCallState) MaybePopulateCallAndReset(source string, call *pbeth call.BalanceChanges = append(call.BalanceChanges, d.balanceChanges...) call.GasChanges = append(call.GasChanges, d.gasChanges...) call.NonceChanges = append(call.NonceChanges, d.nonceChanges...) + call.CodeChanges = append(call.CodeChanges, d.codeChanges...) d.Reset() @@ -2140,7 +2234,7 @@ func (d *DeferredCallState) MaybePopulateCallAndReset(source string, call *pbeth } func (d *DeferredCallState) IsEmpty() bool { - return len(d.accountCreations) == 0 && len(d.balanceChanges) == 0 && len(d.gasChanges) == 0 && len(d.nonceChanges) == 0 + return len(d.accountCreations) == 0 && len(d.balanceChanges) == 0 && len(d.gasChanges) == 0 && len(d.nonceChanges) == 0 && len(d.codeChanges) == 0 } func (d *DeferredCallState) Reset() { @@ -2148,8 +2242,10 @@ func (d *DeferredCallState) Reset() { d.balanceChanges = nil d.gasChanges = nil d.nonceChanges = nil + d.codeChanges = nil } +//go:inline func errorView(err error) _errorView { return _errorView{err} } @@ -2163,7 +2259,57 @@ func (e _errorView) String() string { return "" } - return e.err.Error() + return `"` + e.err.Error() + `"` +} + +//go:inline +func fromToTxView(from *common.Address, tx *types.Transaction) _fromToView { + return _fromToView{from, tx.To()} +} + +//go:inline +func fromToView(from *common.Address, to *common.Address) _fromToView { + return _fromToView{from, to} +} + +type _fromToView struct { + // from is actually always set + from *common.Address + to *common.Address +} + +func (b _fromToView) String() string { + if b.from == nil && b.to == nil { + return "" + } + + to := "" + if b.to != nil { + to = shortenAddress(b.to) + } + + return fmt.Sprintf("(%s -> %s)", shortenAddress(b.from), to) +} + +//go:inline +func shortAddressView(addr *common.Address) *_shortAddressView { + return (*_shortAddressView)(addr) +} + +type _shortAddressView common.Address + +func (a *_shortAddressView) String() string { + if a == nil { + return "" + } + + return shortenAddress((*common.Address)(a)) +} + +func shortenAddress(addr *common.Address) string { + full := addr.String() + + return full[:6] + ".." + full[len(full)-4:] } type inputView []byte @@ -2199,9 +2345,14 @@ func (b outputView) String() string { return fmt.Sprintf("%d bytes", len(b)) } -type receiptView types.Receipt +//go:inline +func receiptView(receipt *types.Receipt) *_receiptView { + return (*_receiptView)(receipt) +} -func (r *receiptView) String() string { +type _receiptView types.Receipt + +func (r *_receiptView) String() string { if r == nil { return "" } diff --git a/eth/tracers/firehose_test.go b/eth/tracers/firehose_test.go index 57dc9bcefb..c908ed2cdd 100644 --- a/eth/tracers/firehose_test.go +++ b/eth/tracers/firehose_test.go @@ -14,7 +14,7 @@ import ( "github.com/ethereum/go-ethereum/core/types" "github.com/ethereum/go-ethereum/core/vm" "github.com/ethereum/go-ethereum/params" - pbeth "github.com/ethereum/go-ethereum/pb/sf/ethereum/type/v2" + pbeth "github.com/streamingfast/firehose-ethereum/types/pb/sf/ethereum/type/v2" "github.com/stretchr/testify/assert" "github.com/stretchr/testify/require" "golang.org/x/exp/maps" diff --git a/eth/tracers/internal/tracetest/firehose/firehose_test.go b/eth/tracers/internal/tracetest/firehose/firehose_test.go index 8edad349b7..81341b2dc0 100644 --- a/eth/tracers/internal/tracetest/firehose/firehose_test.go +++ b/eth/tracers/internal/tracetest/firehose/firehose_test.go @@ -1,18 +1,23 @@ package firehose_test import ( - "encoding/json" "math/big" "path/filepath" "strings" "testing" "github.com/ethereum/go-ethereum/common" + "github.com/ethereum/go-ethereum/consensus/beacon" + "github.com/ethereum/go-ethereum/consensus/ethash" "github.com/ethereum/go-ethereum/core" + "github.com/ethereum/go-ethereum/core/rawdb" "github.com/ethereum/go-ethereum/core/types" "github.com/ethereum/go-ethereum/core/vm" - "github.com/ethereum/go-ethereum/eth/tracers" + "github.com/ethereum/go-ethereum/core/vm/program" + "github.com/ethereum/go-ethereum/crypto" + "github.com/ethereum/go-ethereum/params" "github.com/ethereum/go-ethereum/trie" + "github.com/holiman/uint256" "github.com/stretchr/testify/require" ) @@ -28,18 +33,10 @@ func TestFirehoseChain(t *testing.T) { BaseFee: big.NewInt(8), } - tracer, err := tracers.NewFirehoseFromRawJSON(json.RawMessage(`{ - "applyBackwardsCompatibility": true, - "_private": { - "flushToTestBuffer": true, - "ignoreGenesisBlock": true - } - }`)) - require.NoError(t, err) + tracer, tracingHooks, onClose := newFirehoseTestTracer(t) + defer onClose() - hooks := tracers.NewTracingHooksFromFirehose(tracer) - - genesis, blockchain := newBlockchain(t, types.GenesisAlloc{}, context, hooks) + genesis, blockchain := newBlockchain(t, types.GenesisAlloc{}, context, tracingHooks) block := types.NewBlock(&types.Header{ ParentHash: genesis.ToBlock().Hash(), @@ -81,15 +78,10 @@ func TestFirehosePrestate(t *testing.T) { name := filepath.Base(folder) t.Run(name, func(t *testing.T) { - tracer, err := tracers.NewFirehoseFromRawJSON(json.RawMessage(`{ - "applyBackwardsCompatibility": true, - "_private": { - "flushToTestBuffer": true - } - }`)) - require.NoError(t, err) + tracer, tracingHooks, onClose := newFirehoseTestTracer(t) + defer onClose() - runPrestateBlock(t, filepath.Join(folder, "prestate.json"), tracers.NewTracingHooksFromFirehose(tracer)) + runPrestateBlock(t, filepath.Join(folder, "prestate.json"), tracingHooks) genesisLine, blockLines, unknownLines := readTracerFirehoseLines(t, tracer) require.Len(t, unknownLines, 0, "Lines:\n%s", strings.Join(slicesMap(unknownLines, func(l unknownLine) string { return "- '" + string(l) + "'" }), "\n")) @@ -99,3 +91,127 @@ func TestFirehosePrestate(t *testing.T) { } } + +func TestFirehose_EIP7702(t *testing.T) { + // Copied from ./core/blockchain_test.go#L4180 (TestEIP7702) + + var ( + config = *params.MergedTestChainConfig + signer = types.LatestSigner(&config) + engine = beacon.New(ethash.NewFaker()) + key1, _ = crypto.HexToECDSA("b71c71a67e1177ad4e901695e1b4b9ee17ae16c6668d313eac2f96dbcda3f291") + key2, _ = crypto.HexToECDSA("8a1f9a8f95be41cd7ccb6168179afb4504aefe388d1e14474d32c45c72ce7b7a") + addr1 = crypto.PubkeyToAddress(key1.PublicKey) + addr2 = crypto.PubkeyToAddress(key2.PublicKey) + aa = common.HexToAddress("0x000000000000000000000000000000000000aaaa") + bb = common.HexToAddress("0x000000000000000000000000000000000000bbbb") + cc = common.HexToAddress("0x000000000000000000000000000000000000cccc") + funds = new(big.Int).Mul(common.Big1, big.NewInt(params.Ether)) + ) + + gspec := &core.Genesis{ + Config: &config, + Alloc: types.GenesisAlloc{ + addr1: {Balance: funds}, + addr2: {Balance: funds}, + aa: { // The address 0xAAAA calls into addr2 + Code: program.New().Call(nil, addr2, 1, 0, 0, 0, 0).Bytes(), + Nonce: 0, + Balance: big.NewInt(0), + }, + bb: { // The address 0xBBBB sstores 42 into slot 42. + Code: program.New().Sstore(0x42, 0x42).Bytes(), + Nonce: 0, + Balance: big.NewInt(0), + }, + cc: { // The address 0xCCCC sstores 42 into slot 42. + Code: program.New().Sstore(0x42, 0x42).Bytes(), + Nonce: 0, + Balance: big.NewInt(0), + }, + }, + } + + // Sign authorization tuples. + // The way the auths are combined, it becomes + // 1. tx -> addr1 which is delegated to 0xaaaa + // 2. addr1:0xaaaa calls into addr2:0xbbbb + // 3. addr2:0xbbbb writes to storage + auth1, _ := types.SignSetCode(key1, types.SetCodeAuthorization{ + ChainID: *uint256.MustFromBig(gspec.Config.ChainID), + Address: aa, + Nonce: 1, + }) + auth2OverwrittenLaterInList, _ := types.SignSetCode(key2, types.SetCodeAuthorization{ + Address: cc, + Nonce: 0, + }) + auth3InvalidAuthority := auth2OverwrittenLaterInList + auth3InvalidAuthority.V = 4 + auth4, _ := types.SignSetCode(key2, types.SetCodeAuthorization{ + Address: bb, + Nonce: 1, + }) + auth5InvalidNonce, _ := types.SignSetCode(key2, types.SetCodeAuthorization{ + Address: bb, + Nonce: 1, + }) + + auth1Reset, _ := types.SignSetCode(key1, types.SetCodeAuthorization{ + ChainID: *uint256.MustFromBig(gspec.Config.ChainID), + Address: common.Address{}, + Nonce: 4, + }) + + _, blocks, _ := core.GenerateChainWithGenesis(gspec, engine, 3, func(i int, b *core.BlockGen) { + b.SetCoinbase(aa) + + if i == 0 { + txdata := &types.SetCodeTx{ + ChainID: uint256.MustFromBig(gspec.Config.ChainID), + Nonce: 0, + To: addr1, + Gas: 500000, + GasFeeCap: uint256.MustFromBig(newGwei(5)), + GasTipCap: uint256.NewInt(2), + AuthList: []types.SetCodeAuthorization{auth1, auth2OverwrittenLaterInList, auth3InvalidAuthority, auth4, auth5InvalidNonce}, + } + tx := types.MustSignNewTx(key1, signer, txdata) + b.AddTx(tx) + } else if i == 1 { + txdata := &types.LegacyTx{ + Nonce: 2, + To: &addr1, + Value: big.NewInt(0), + Gas: 500000, + GasPrice: newGwei(500), + } + tx := types.MustSignNewTx(key1, signer, txdata) + b.AddTx(tx) + } else if i == 2 { + txdata := &types.SetCodeTx{ + ChainID: uint256.MustFromBig(gspec.Config.ChainID), + Nonce: 3, + To: addr1, + Gas: 500000, + GasFeeCap: uint256.MustFromBig(newGwei(5)), + GasTipCap: uint256.NewInt(2), + AuthList: []types.SetCodeAuthorization{auth1Reset}, + } + tx := types.MustSignNewTx(key1, signer, txdata) + b.AddTx(tx) + } + }) + + tracer, tracingHooks, onClose := newFirehoseTestTracer(t) + defer onClose() + + chain, err := core.NewBlockChain(rawdb.NewMemoryDatabase(), nil, gspec, nil, engine, vm.Config{Tracer: tracingHooks}, nil) + require.NoError(t, err, "failed to create tester chain") + + defer chain.Stop() + n, err := chain.InsertChain(blocks) + require.NoError(t, err, "failed to insert chain block %d", n) + + assertBlockEquals(t, tracer, filepath.Join("testdata", "TestEIP7702"), len(blocks)) +} diff --git a/eth/tracers/internal/tracetest/firehose/helpers_test.go b/eth/tracers/internal/tracetest/firehose/helpers_test.go index ee3cf653dc..627a1badc1 100644 --- a/eth/tracers/internal/tracetest/firehose/helpers_test.go +++ b/eth/tracers/internal/tracetest/firehose/helpers_test.go @@ -4,12 +4,16 @@ import ( "bytes" "encoding/base64" "fmt" + "math/big" "os" "path/filepath" + "strings" "testing" + "github.com/ethereum/go-ethereum/core/tracing" "github.com/ethereum/go-ethereum/eth/tracers" - pbeth "github.com/ethereum/go-ethereum/pb/sf/ethereum/type/v2" + "github.com/ethereum/go-ethereum/params" + pbeth "github.com/streamingfast/firehose-ethereum/types/pb/sf/ethereum/type/v2" "github.com/stretchr/testify/assert" "github.com/stretchr/testify/require" "google.golang.org/protobuf/encoding/protojson" @@ -24,6 +28,27 @@ type firehoseInitLine struct { type firehoseBlockLines []firehoseBlockLine +func newFirehoseTestTracer(t *testing.T) (*tracers.Firehose, *tracing.Hooks, func()) { + t.Helper() + + tracer, err := tracers.NewFirehoseFromRawJSON([]byte(`{ + "applyBackwardsCompatibility": true, + "_private": { + "flushToTestBuffer": true, + "ignoreGenesisBlock": true + } + }`)) + require.NoError(t, err) + + hooks := tracers.NewTracingHooksFromFirehose(tracer) + + return tracer, hooks, func() { + if hooks.OnClose != nil { + hooks.OnClose() + } + } +} + func (lines firehoseBlockLines) assertEquals(t *testing.T, goldenDir string, expected ...firehoseBlockLineParams) { actualParams := slicesMap(lines, func(l firehoseBlockLine) firehoseBlockLineParams { return l.Params }) require.Equal(t, expected, actualParams, "Actual lines block params do not match expected lines block params") @@ -102,6 +127,16 @@ type firehoseBlockLineParams struct { type unknownLine string +// assertBlockEquals reads the tracer output and compares it to the golden files in the given directory. +func assertBlockEquals(t *testing.T, tracer *tracers.Firehose, goldenDir string, expectedBlockCount int) { + t.Helper() + + genesisLine, blockLines, unknownLines := readTracerFirehoseLines(t, tracer) + require.Len(t, unknownLines, 0, "Lines:\n%s", strings.Join(slicesMap(unknownLines, func(l unknownLine) string { return "- '" + string(l) + "'" }), "\n")) + require.NotNil(t, genesisLine) + blockLines.assertOnlyBlockEquals(t, goldenDir, expectedBlockCount) +} + func readTracerFirehoseLines(t *testing.T, tracer *tracers.Firehose) (genesisLine *firehoseInitLine, blockLines firehoseBlockLines, unknownLines []unknownLine) { t.Helper() @@ -157,3 +192,7 @@ func readTracerFirehoseLines(t *testing.T, tracer *tracers.Firehose) (genesisLin func ptr[T any](v T) *T { return &v } + +func newGwei(n int64) *big.Int { + return new(big.Int).Mul(big.NewInt(n), big.NewInt(params.GWei)) +} diff --git a/eth/tracers/internal/tracetest/firehose/testdata/TestEIP7702/block.1.golden.json b/eth/tracers/internal/tracetest/firehose/testdata/TestEIP7702/block.1.golden.json new file mode 100644 index 0000000000..d330fd9248 --- /dev/null +++ b/eth/tracers/internal/tracetest/firehose/testdata/TestEIP7702/block.1.golden.json @@ -0,0 +1,297 @@ +{ + "hash": "tNKSM8SZPvaEgBA4yUj9YayXYYuXnLCuHx5oWJwVOhw=", + "number": "1", + "size": "1190", + "header": { + "parentHash": "pWIUj7qpHz/G8tLNdaLNz8Jr1TmoyDxTXP9TdFcxi1w=", + "uncleHash": "HcxN6N7HXXqrhbVntszUGtMSRRuUinQT8KFC/UDUk0c=", + "coinbase": "AAAAAAAAAAAAAAAAAAAAAAAAqqo=", + "stateRoot": "wFieFJlWOhntuAXVWTxqg5Uur7kaXrFRERwFB8+qscc=", + "transactionsRoot": "L6HG4v+Zoguv352C8ZdQGQ4tE5BJdzCJVbfWBHMquN0=", + "receiptRoot": "6LQ+xgZZXKAlBStw088D6A2kWiz7g+TtQlAALnPMSi4=", + "logsBloom": "AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA==", + "difficulty": { + "bytes": "AA==" + }, + "number": "1", + "gasLimit": "4712388", + "gasUsed": "142021", + "timestamp": "1970-01-01T00:00:10Z", + "mixHash": "AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA=", + "hash": "tNKSM8SZPvaEgBA4yUj9YayXYYuXnLCuHx5oWJwVOhw=", + "baseFeePerGas": { + "bytes": "NCdwwA==" + }, + "withdrawalsRoot": "VugfFxvMVab/g0XmksD4bltI4BuZbK3AAWIvteNjtCE=", + "blobGasUsed": "0", + "excessBlobGas": "0", + "parentBeaconRoot": "AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA=", + "requestsHash": "47DEQpj8HBSa+/TImW+5JCeuQeRkm5NMpJWZG3hSuFU=" + }, + "transactionTraces": [ + { + "to": "cVYrcZmYc9tbKG35V68ZnslGF/c=", + "gasPrice": { + "bytes": "NCdwwg==" + }, + "gasLimit": "500000", + "r": "E2l+Qpz16QzQhLJM+8gu8vd/lpMS1JAC0/hIlSNzFeg=", + "s": "N9pmx9wBwi0vXsT283fImtj6D4zPzYK3ZFXwBhYmbBA=", + "gasUsed": "142021", + "type": "TRX_TYPE_SET_CODE", + "maxFeePerGas": { + "bytes": "ASoF8gA=" + }, + "maxPriorityFeePerGas": { + "bytes": "Ag==" + }, + "hash": "alLg5Yk4t0M/5q97S3ye+D/U/jP60tAc1kNI8q4G+G0=", + "from": "cVYrcZmYc9tbKG35V68ZnslGF/c=", + "beginOrdinal": "5", + "endOrdinal": "27", + "status": "SUCCEEDED", + "receipt": { + "cumulativeGasUsed": "142021", + "logsBloom": "AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA==" + }, + "calls": [ + { + "index": 1, + "callType": "CALL", + "caller": "cVYrcZmYc9tbKG35V68ZnslGF/c=", + "address": "cVYrcZmYc9tbKG35V68ZnslGF/c=", + "addressDelegatesTo": "AAAAAAAAAAAAAAAAAAAAAAAAqqo=", + "gasLimit": "354000", + "gasConsumed": "31526", + "balanceChanges": [ + { + "address": "cVYrcZmYc9tbKG35V68ZnslGF/c=", + "oldValue": { + "bytes": "DeC2s6dkAAA=" + }, + "newValue": { + "bytes": "Dd8ozD895cA=" + }, + "reason": "REASON_GAS_BUY", + "ordinal": "6" + }, + { + "address": "cVYrcZmYc9tbKG35V68ZnslGF/c=", + "oldValue": { + "bytes": "Dd8ozD895b8=" + }, + "newValue": { + "bytes": "DeBFrisGZrU=" + }, + "reason": "REASON_GAS_REFUND", + "ordinal": "25" + }, + { + "address": "AAAAAAAAAAAAAAAAAAAAAAAAqqo=", + "newValue": { + "bytes": "BFWK" + }, + "reason": "REASON_REWARD_TRANSACTION_FEE", + "ordinal": "26" + } + ], + "nonceChanges": [ + { + "address": "cVYrcZmYc9tbKG35V68ZnslGF/c=", + "newValue": "1", + "ordinal": "8" + }, + { + "address": "cVYrcZmYc9tbKG35V68ZnslGF/c=", + "oldValue": "1", + "newValue": "2", + "ordinal": "9" + }, + { + "address": "cDxLK9cMFp9XFxAcruVDKZ/JRsc=", + "newValue": "1", + "ordinal": "11" + }, + { + "address": "cDxLK9cMFp9XFxAcruVDKZ/JRsc=", + "oldValue": "1", + "newValue": "2", + "ordinal": "13" + } + ], + "codeChanges": [ + { + "address": "cVYrcZmYc9tbKG35V68ZnslGF/c=", + "oldHash": "xdJGAYb3IzySfn2y3McDwOUAtlPKgic7e/rYBF2FpHA=", + "newHash": "6BOVhfT5ksAf8bXRTf8FXcJyKhFA0Cb18MtIsAn1Z9o=", + "newCode": "7wEAAAAAAAAAAAAAAAAAAAAAAAAAqqo=", + "ordinal": "10" + }, + { + "address": "cDxLK9cMFp9XFxAcruVDKZ/JRsc=", + "oldHash": "xdJGAYb3IzySfn2y3McDwOUAtlPKgic7e/rYBF2FpHA=", + "newHash": "2nRj6FdgztYMKwAqS2x5e7pQdCMd4bTSeffx8pbIFmU=", + "newCode": "7wEAAAAAAAAAAAAAAAAAAAAAAAAAzMw=", + "ordinal": "12" + }, + { + "address": "cDxLK9cMFp9XFxAcruVDKZ/JRsc=", + "oldHash": "2nRj6FdgztYMKwAqS2x5e7pQdCMd4bTSeffx8pbIFmU=", + "oldCode": "7wEAAAAAAAAAAAAAAAAAAAAAAAAAzMw=", + "newHash": "0mhxQ0BYDv3haWHrT7NIuLWUSlfUHjFwuLM/8Jt1SXA=", + "newCode": "7wEAAAAAAAAAAAAAAAAAAAAAAAAAu7s=", + "ordinal": "14" + } + ], + "gasChanges": [ + { + "oldValue": "500000", + "newValue": "354000", + "reason": "REASON_INTRINSIC_GAS", + "ordinal": "7" + }, + { + "oldValue": "353880", + "newValue": "351280", + "reason": "REASON_STATE_COLD_ACCESS", + "ordinal": "16" + }, + { + "oldValue": "353980", + "newValue": "5348", + "reason": "REASON_CALL", + "ordinal": "17" + }, + { + "oldValue": "5348", + "newValue": "322474", + "reason": "REASON_REFUND_AFTER_EXECUTION", + "ordinal": "23" + } + ], + "endOrdinal": "24" + }, + { + "index": 2, + "parentIndex": 1, + "depth": 1, + "callType": "CALL", + "caller": "cVYrcZmYc9tbKG35V68ZnslGF/c=", + "address": "cDxLK9cMFp9XFxAcruVDKZ/JRsc=", + "addressDelegatesTo": "AAAAAAAAAAAAAAAAAAAAAAAAu7s=", + "value": { + "bytes": "AQ==" + }, + "gasLimit": "339232", + "gasConsumed": "22106", + "storageChanges": [ + { + "address": "cDxLK9cMFp9XFxAcruVDKZ/JRsc=", + "key": "AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAEI=", + "oldValue": "AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA=", + "newValue": "AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAEI=", + "ordinal": "21" + } + ], + "balanceChanges": [ + { + "address": "cVYrcZmYc9tbKG35V68ZnslGF/c=", + "oldValue": { + "bytes": "Dd8ozD895cA=" + }, + "newValue": { + "bytes": "Dd8ozD895b8=" + }, + "reason": "REASON_TRANSFER", + "ordinal": "19" + }, + { + "address": "cDxLK9cMFp9XFxAcruVDKZ/JRsc=", + "oldValue": { + "bytes": "DeC2s6dkAAA=" + }, + "newValue": { + "bytes": "DeC2s6dkAAE=" + }, + "reason": "REASON_TRANSFER", + "ordinal": "20" + } + ], + "beginOrdinal": "18", + "endOrdinal": "22" + } + ], + "setCodeAuthorizations": [ + { + "chainId": "AQ==", + "nonce": "1", + "v": 1, + "r": "9+Pll/wJfnHtbCaxSyXlOVvIUQ1YuRNq9DnhJxXy1yE=", + "s": "bPfD15Ob/beENz7/wOuwvXVJaRpRPzlePNq/hgJySYc=", + "authority": "cVYrcZmYc9tbKG35V68ZnslGF/c=" + }, + { + "r": "2uP1vwtGC/qSZin0z+PZ2kBZ/xY3445BRUpUUwr4UOc=", + "s": "HhA+a0fj/u82ZZyD9gMoHso5vGditId+wkZrJcpo4UM=", + "authority": "cDxLK9cMFp9XFxAcruVDKZ/JRsc=" + }, + { + "discarded": true, + "v": 4, + "r": "2uP1vwtGC/qSZin0z+PZ2kBZ/xY3445BRUpUUwr4UOc=", + "s": "HhA+a0fj/u82ZZyD9gMoHso5vGditId+wkZrJcpo4UM=" + }, + { + "nonce": "1", + "r": "aZRYP4l48gpWJSypjCxSptjK/kDFXmphIXOrnH6LlKs=", + "s": "HLb0WRaaPuzez2ZbtK39Ch9vZGXNjm5AYg2i8X5MMwg=", + "authority": "cDxLK9cMFp9XFxAcruVDKZ/JRsc=" + }, + { + "discarded": true, + "nonce": "1", + "r": "aZRYP4l48gpWJSypjCxSptjK/kDFXmphIXOrnH6LlKs=", + "s": "HLb0WRaaPuzez2ZbtK39Ch9vZGXNjm5AYg2i8X5MMwg=", + "authority": "cDxLK9cMFp9XFxAcruVDKZ/JRsc=" + } + ] + } + ], + "systemCalls": [ + { + "index": 1, + "callType": "CALL", + "caller": "//////////////////////////4=", + "address": "AA899tcygH7xMZ+3uLuFItC+rAI=", + "gasLimit": "30000000", + "input": "AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA=", + "endOrdinal": "2" + }, + { + "index": 1, + "callType": "CALL", + "caller": "//////////////////////////4=", + "address": "AAD5CCfxxToQy3oCM1sXUyAAKTU=", + "gasLimit": "30000000", + "input": "pWIUj7qpHz/G8tLNdaLNz8Jr1TmoyDxTXP9TdFcxi1w=", + "endOrdinal": "4" + }, + { + "index": 1, + "callType": "CALL", + "caller": "//////////////////////////4=", + "address": "AAAJYe9IDrVegNGa2DV5pkwAcAI=", + "gasLimit": "30000000", + "endOrdinal": "29" + }, + { + "index": 1, + "callType": "CALL", + "caller": "//////////////////////////4=", + "address": "AAC73cfOSIZC+1efiwDzpZAAclE=", + "gasLimit": "30000000", + "endOrdinal": "31" + } + ], + "ver": 3 +} \ No newline at end of file diff --git a/eth/tracers/internal/tracetest/firehose/testdata/TestEIP7702/block.2.golden.json b/eth/tracers/internal/tracetest/firehose/testdata/TestEIP7702/block.2.golden.json new file mode 100644 index 0000000000..a643ce0bbd --- /dev/null +++ b/eth/tracers/internal/tracetest/firehose/testdata/TestEIP7702/block.2.golden.json @@ -0,0 +1,218 @@ +{ + "hash": "Hlau1KLprrOkaDe4TNZdPEoXeJ4UGEL1PwUY/qq+/rk=", + "number": "2", + "size": "717", + "header": { + "parentHash": "tNKSM8SZPvaEgBA4yUj9YayXYYuXnLCuHx5oWJwVOhw=", + "uncleHash": "HcxN6N7HXXqrhbVntszUGtMSRRuUinQT8KFC/UDUk0c=", + "coinbase": "AAAAAAAAAAAAAAAAAAAAAAAAqqo=", + "stateRoot": "C/zDETYPAXEFuq3RDENkXppoaNjfcWKHhIQqZGC0D5c=", + "transactionsRoot": "5SXnkgZs4gKgt8t4GTnSeoV1i17zHn3xbZXSln9fd2E=", + "receiptRoot": "TaaZwIwiwzd65OYkLzazOIYrFN0/DnyXzNqaA/dY3pQ=", + "logsBloom": "AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA==", + "difficulty": { + "bytes": "AA==" + }, + "number": "2", + "gasLimit": "4712388", + "gasUsed": "35126", + "timestamp": "1970-01-01T00:00:20Z", + "mixHash": "AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA=", + "hash": "Hlau1KLprrOkaDe4TNZdPEoXeJ4UGEL1PwUY/qq+/rk=", + "baseFeePerGas": { + "bytes": "LgcbLA==" + }, + "withdrawalsRoot": "VugfFxvMVab/g0XmksD4bltI4BuZbK3AAWIvteNjtCE=", + "blobGasUsed": "0", + "excessBlobGas": "0", + "parentBeaconRoot": "AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA=", + "requestsHash": "47DEQpj8HBSa+/TImW+5JCeuQeRkm5NMpJWZG3hSuFU=" + }, + "transactionTraces": [ + { + "to": "cVYrcZmYc9tbKG35V68ZnslGF/c=", + "nonce": "2", + "gasPrice": { + "bytes": "dGpSiAA=" + }, + "gasLimit": "500000", + "v": "JQ==", + "r": "llnySTXnLA5URm+RriiJTQ4gvkdUifLtVOIyBCpDFTw=", + "s": "SsqOfVDTp1cpwvz0g4nLhIzrWRGwh0Jgz4l9GK/UHbE=", + "gasUsed": "35126", + "hash": "TNmQOfjPE0jeas0eba+xGMaitDgyCOKmvNIBapciCiE=", + "from": "cVYrcZmYc9tbKG35V68ZnslGF/c=", + "beginOrdinal": "5", + "endOrdinal": "21", + "status": "SUCCEEDED", + "receipt": { + "cumulativeGasUsed": "35126", + "logsBloom": "AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA==" + }, + "calls": [ + { + "index": 1, + "callType": "CALL", + "caller": "cVYrcZmYc9tbKG35V68ZnslGF/c=", + "address": "cVYrcZmYc9tbKG35V68ZnslGF/c=", + "addressDelegatesTo": "AAAAAAAAAAAAAAAAAAAAAAAAqqo=", + "gasLimit": "479000", + "gasConsumed": "14126", + "balanceChanges": [ + { + "address": "cVYrcZmYc9tbKG35V68ZnslGF/c=", + "oldValue": { + "bytes": "DeBFrisGZrU=" + }, + "newValue": { + "bytes": "CmgYAUEtZrU=" + }, + "reason": "REASON_GAS_BUY", + "ordinal": "6" + }, + { + "address": "cVYrcZmYc9tbKG35V68ZnslGF/c=", + "oldValue": { + "bytes": "CmgYAUEtZrQ=" + }, + "newValue": { + "bytes": "DaHgOZLVtrQ=" + }, + "reason": "REASON_GAS_REFUND", + "ordinal": "19" + }, + { + "address": "AAAAAAAAAAAAAAAAAAAAAAAAqqo=", + "oldValue": { + "bytes": "BFWK" + }, + "newValue": { + "bytes": "PkzJFSq+Qg==" + }, + "reason": "REASON_REWARD_TRANSACTION_FEE", + "ordinal": "20" + } + ], + "nonceChanges": [ + { + "address": "cVYrcZmYc9tbKG35V68ZnslGF/c=", + "oldValue": "2", + "newValue": "3", + "ordinal": "8" + } + ], + "gasChanges": [ + { + "oldValue": "500000", + "newValue": "479000", + "reason": "REASON_INTRINSIC_GAS", + "ordinal": "7" + }, + { + "oldValue": "478880", + "newValue": "476380", + "reason": "REASON_STATE_COLD_ACCESS", + "ordinal": "10" + }, + { + "oldValue": "476380", + "newValue": "473780", + "reason": "REASON_STATE_COLD_ACCESS", + "ordinal": "11" + }, + { + "oldValue": "478980", + "newValue": "7262", + "reason": "REASON_CALL", + "ordinal": "12" + }, + { + "oldValue": "7262", + "newValue": "464874", + "reason": "REASON_REFUND_AFTER_EXECUTION", + "ordinal": "17" + } + ], + "endOrdinal": "18" + }, + { + "index": 2, + "parentIndex": 1, + "depth": 1, + "callType": "CALL", + "caller": "cVYrcZmYc9tbKG35V68ZnslGF/c=", + "address": "cDxLK9cMFp9XFxAcruVDKZ/JRsc=", + "addressDelegatesTo": "AAAAAAAAAAAAAAAAAAAAAAAAu7s=", + "value": { + "bytes": "AQ==" + }, + "gasLimit": "459818", + "gasConsumed": "2206", + "balanceChanges": [ + { + "address": "cVYrcZmYc9tbKG35V68ZnslGF/c=", + "oldValue": { + "bytes": "CmgYAUEtZrU=" + }, + "newValue": { + "bytes": "CmgYAUEtZrQ=" + }, + "reason": "REASON_TRANSFER", + "ordinal": "14" + }, + { + "address": "cDxLK9cMFp9XFxAcruVDKZ/JRsc=", + "oldValue": { + "bytes": "DeC2s6dkAAE=" + }, + "newValue": { + "bytes": "DeC2s6dkAAI=" + }, + "reason": "REASON_TRANSFER", + "ordinal": "15" + } + ], + "beginOrdinal": "13", + "endOrdinal": "16" + } + ] + } + ], + "systemCalls": [ + { + "index": 1, + "callType": "CALL", + "caller": "//////////////////////////4=", + "address": "AA899tcygH7xMZ+3uLuFItC+rAI=", + "gasLimit": "30000000", + "input": "AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA=", + "endOrdinal": "2" + }, + { + "index": 1, + "callType": "CALL", + "caller": "//////////////////////////4=", + "address": "AAD5CCfxxToQy3oCM1sXUyAAKTU=", + "gasLimit": "30000000", + "input": "tNKSM8SZPvaEgBA4yUj9YayXYYuXnLCuHx5oWJwVOhw=", + "endOrdinal": "4" + }, + { + "index": 1, + "callType": "CALL", + "caller": "//////////////////////////4=", + "address": "AAAJYe9IDrVegNGa2DV5pkwAcAI=", + "gasLimit": "30000000", + "endOrdinal": "23" + }, + { + "index": 1, + "callType": "CALL", + "caller": "//////////////////////////4=", + "address": "AAC73cfOSIZC+1efiwDzpZAAclE=", + "gasLimit": "30000000", + "endOrdinal": "25" + } + ], + "ver": 3 +} \ No newline at end of file diff --git a/eth/tracers/internal/tracetest/firehose/testdata/TestEIP7702/block.3.golden.json b/eth/tracers/internal/tracetest/firehose/testdata/TestEIP7702/block.3.golden.json new file mode 100644 index 0000000000..dabfa0ba69 --- /dev/null +++ b/eth/tracers/internal/tracetest/firehose/testdata/TestEIP7702/block.3.golden.json @@ -0,0 +1,182 @@ +{ + "hash": "nM0MjYrd54p5L0zQNGpHV7fxetFL1VCejCvGELDLop8=", + "number": "3", + "size": "817", + "header": { + "parentHash": "Hlau1KLprrOkaDe4TNZdPEoXeJ4UGEL1PwUY/qq+/rk=", + "uncleHash": "HcxN6N7HXXqrhbVntszUGtMSRRuUinQT8KFC/UDUk0c=", + "coinbase": "AAAAAAAAAAAAAAAAAAAAAAAAqqo=", + "stateRoot": "vWvMYC8Hck2r4d77C3bO7nRWmEtpytSHv092DGpMjeI=", + "transactionsRoot": "Bpo3ARUhIUuu9hH3yrkUNF2s22VFnHRDwdWxzM0pb5U=", + "receiptRoot": "A2x9IEIO284ktQYhSLzoBWO0j9RTL7HAaLLJalMRcBk=", + "logsBloom": "AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA==", + "difficulty": { + "bytes": "AA==" + }, + "number": "3", + "gasLimit": "4712388", + "gasUsed": "36800", + "timestamp": "1970-01-01T00:00:30Z", + "mixHash": "AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA=", + "hash": "nM0MjYrd54p5L0zQNGpHV7fxetFL1VCejCvGELDLop8=", + "baseFeePerGas": { + "bytes": "KFws9Q==" + }, + "withdrawalsRoot": "VugfFxvMVab/g0XmksD4bltI4BuZbK3AAWIvteNjtCE=", + "blobGasUsed": "0", + "excessBlobGas": "0", + "parentBeaconRoot": "AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA=", + "requestsHash": "47DEQpj8HBSa+/TImW+5JCeuQeRkm5NMpJWZG3hSuFU=" + }, + "transactionTraces": [ + { + "to": "cVYrcZmYc9tbKG35V68ZnslGF/c=", + "nonce": "3", + "gasPrice": { + "bytes": "KFws9w==" + }, + "gasLimit": "500000", + "r": "3+bIOst9jVy0xdYLs7dP1KfP1XrtsXepmpY0W3XBKII=", + "s": "UGXb+KJ8dparEBn0Wb2lX5fh1gB2+AiHfowzzmJWOkE=", + "gasUsed": "36800", + "type": "TRX_TYPE_SET_CODE", + "maxFeePerGas": { + "bytes": "ASoF8gA=" + }, + "maxPriorityFeePerGas": { + "bytes": "Ag==" + }, + "hash": "vj4lUeVR72WjVf2OYUmz3Um0SH4d6qCao7cZRbBiaCI=", + "from": "cVYrcZmYc9tbKG35V68ZnslGF/c=", + "beginOrdinal": "5", + "endOrdinal": "15", + "status": "SUCCEEDED", + "receipt": { + "cumulativeGasUsed": "36800", + "logsBloom": "AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA==" + }, + "calls": [ + { + "index": 1, + "callType": "CALL", + "caller": "cVYrcZmYc9tbKG35V68ZnslGF/c=", + "address": "cVYrcZmYc9tbKG35V68ZnslGF/c=", + "gasLimit": "454000", + "balanceChanges": [ + { + "address": "cVYrcZmYc9tbKG35V68ZnslGF/c=", + "oldValue": { + "bytes": "DaHgOZLVtrQ=" + }, + "newValue": { + "bytes": "DaCsTVRHwNQ=" + }, + "reason": "REASON_GAS_BUY", + "ordinal": "6" + }, + { + "address": "cVYrcZmYc9tbKG35V68ZnslGF/c=", + "oldValue": { + "bytes": "DaCsTVRHwNQ=" + }, + "newValue": { + "bytes": "DaHJj9CWBHQ=" + }, + "reason": "REASON_GAS_REFUND", + "ordinal": "13" + }, + { + "address": "AAAAAAAAAAAAAAAAAAAAAAAAqqo=", + "oldValue": { + "bytes": "PkzJFSq+Qg==" + }, + "newValue": { + "bytes": "PkzJFSvdwg==" + }, + "reason": "REASON_REWARD_TRANSACTION_FEE", + "ordinal": "14" + } + ], + "nonceChanges": [ + { + "address": "cVYrcZmYc9tbKG35V68ZnslGF/c=", + "oldValue": "3", + "newValue": "4", + "ordinal": "8" + }, + { + "address": "cVYrcZmYc9tbKG35V68ZnslGF/c=", + "oldValue": "4", + "newValue": "5", + "ordinal": "9" + } + ], + "codeChanges": [ + { + "address": "cVYrcZmYc9tbKG35V68ZnslGF/c=", + "oldHash": "6BOVhfT5ksAf8bXRTf8FXcJyKhFA0Cb18MtIsAn1Z9o=", + "oldCode": "7wEAAAAAAAAAAAAAAAAAAAAAAAAAqqo=", + "newHash": "xdJGAYb3IzySfn2y3McDwOUAtlPKgic7e/rYBF2FpHA=", + "ordinal": "10" + } + ], + "gasChanges": [ + { + "oldValue": "500000", + "newValue": "454000", + "reason": "REASON_INTRINSIC_GAS", + "ordinal": "7" + } + ], + "endOrdinal": "12" + } + ], + "setCodeAuthorizations": [ + { + "chainId": "AQ==", + "nonce": "4", + "r": "8RpcvObxuhW9b2SyJDTKMBtrqfyaAJlzS37bOLPTKIo=", + "s": "NMkyzSai5xkwNV4ttrTli9jZHXeB7hUwej28frcnTDw=", + "authority": "cVYrcZmYc9tbKG35V68ZnslGF/c=" + } + ] + } + ], + "systemCalls": [ + { + "index": 1, + "callType": "CALL", + "caller": "//////////////////////////4=", + "address": "AA899tcygH7xMZ+3uLuFItC+rAI=", + "gasLimit": "30000000", + "input": "AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA=", + "endOrdinal": "2" + }, + { + "index": 1, + "callType": "CALL", + "caller": "//////////////////////////4=", + "address": "AAD5CCfxxToQy3oCM1sXUyAAKTU=", + "gasLimit": "30000000", + "input": "Hlau1KLprrOkaDe4TNZdPEoXeJ4UGEL1PwUY/qq+/rk=", + "endOrdinal": "4" + }, + { + "index": 1, + "callType": "CALL", + "caller": "//////////////////////////4=", + "address": "AAAJYe9IDrVegNGa2DV5pkwAcAI=", + "gasLimit": "30000000", + "endOrdinal": "17" + }, + { + "index": 1, + "callType": "CALL", + "caller": "//////////////////////////4=", + "address": "AAC73cfOSIZC+1efiwDzpZAAclE=", + "gasLimit": "30000000", + "endOrdinal": "19" + } + ], + "ver": 3 +} \ No newline at end of file diff --git a/go.mod b/go.mod index 5d0e830ede..67f927a4cb 100644 --- a/go.mod +++ b/go.mod @@ -58,6 +58,7 @@ require ( github.com/rs/cors v1.7.0 github.com/shirou/gopsutil v3.21.4-0.20210419000835-c7a38de76ee5+incompatible github.com/status-im/keycard-go v0.2.0 + github.com/streamingfast/firehose-ethereum/types v0.0.0-20250219193809-31f4c76a8a5d github.com/stretchr/testify v1.9.0 github.com/supranational/blst v0.3.14 github.com/syndtr/goleveldb v1.0.1-0.20210819022825-2ae1ddf74ef7 diff --git a/go.sum b/go.sum index 7a44c63aeb..9c27763608 100644 --- a/go.sum +++ b/go.sum @@ -493,6 +493,8 @@ github.com/sirupsen/logrus v1.4.2/go.mod h1:tLMulIdttU9McNUspp0xgXVQah82FyeX6Mwd github.com/sirupsen/logrus v1.6.0/go.mod h1:7uNnSEd1DgxDLC74fIahvMZmmYsHGZGEOFrfsX/uA88= 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/streamingfast/firehose-ethereum/types v0.0.0-20250219193809-31f4c76a8a5d h1:8Ki6y+B7HB3Wo8DBUqoIpNxT6mGZ/5joPHRZSvLIFdE= +github.com/streamingfast/firehose-ethereum/types v0.0.0-20250219193809-31f4c76a8a5d/go.mod h1:CG22ObinxSbKIP19bAj0uro0a290kzZTiBbjL8VR0SE= github.com/stretchr/objx v0.1.0/go.mod h1:HFkY916IF+rwdDfMAkV7OtwuqBVzrE8GR6GFx+wExME= github.com/stretchr/objx v0.1.1/go.mod h1:HFkY916IF+rwdDfMAkV7OtwuqBVzrE8GR6GFx+wExME= github.com/stretchr/objx v0.4.0/go.mod h1:YvHI0jy2hoMjB+UWwv71VJQ9isScKT/TqJzVSSt89Yw= diff --git a/pb/sf/ethereum/type/v2/type.go b/pb/sf/ethereum/type/v2/type.go deleted file mode 100644 index 38b6881fc1..0000000000 --- a/pb/sf/ethereum/type/v2/type.go +++ /dev/null @@ -1,27 +0,0 @@ -package pbeth - -import ( - "encoding/hex" - "math/big" - "time" -) - -var b0 = big.NewInt(0) - -func (b *Block) PreviousID() string { - return hex.EncodeToString(b.Header.ParentHash) -} - -func (b *Block) Time() time.Time { - return b.Header.Timestamp.AsTime() -} - -func (m *BigInt) Native() *big.Int { - if m == nil { - return b0 - } - - z := new(big.Int) - z.SetBytes(m.Bytes) - return z -} diff --git a/pb/sf/ethereum/type/v2/type.pb.go b/pb/sf/ethereum/type/v2/type.pb.go deleted file mode 100644 index 6e1e67dd63..0000000000 --- a/pb/sf/ethereum/type/v2/type.pb.go +++ /dev/null @@ -1,3553 +0,0 @@ -// Code generated by protoc-gen-go. DO NOT EDIT. -// versions: -// protoc-gen-go v1.36.4 -// protoc v5.29.3 -// source: sf/ethereum/type/v2/type.proto - -package pbeth - -import ( - protoreflect "google.golang.org/protobuf/reflect/protoreflect" - protoimpl "google.golang.org/protobuf/runtime/protoimpl" - timestamppb "google.golang.org/protobuf/types/known/timestamppb" - reflect "reflect" - sync "sync" - unsafe "unsafe" -) - -const ( - // Verify that this generated code is sufficiently up-to-date. - _ = protoimpl.EnforceVersion(20 - protoimpl.MinVersion) - // Verify that runtime/protoimpl is sufficiently up-to-date. - _ = protoimpl.EnforceVersion(protoimpl.MaxVersion - 20) -) - -type TransactionTraceStatus int32 - -const ( - TransactionTraceStatus_UNKNOWN TransactionTraceStatus = 0 - TransactionTraceStatus_SUCCEEDED TransactionTraceStatus = 1 - TransactionTraceStatus_FAILED TransactionTraceStatus = 2 - TransactionTraceStatus_REVERTED TransactionTraceStatus = 3 -) - -// Enum value maps for TransactionTraceStatus. -var ( - TransactionTraceStatus_name = map[int32]string{ - 0: "UNKNOWN", - 1: "SUCCEEDED", - 2: "FAILED", - 3: "REVERTED", - } - TransactionTraceStatus_value = map[string]int32{ - "UNKNOWN": 0, - "SUCCEEDED": 1, - "FAILED": 2, - "REVERTED": 3, - } -) - -func (x TransactionTraceStatus) Enum() *TransactionTraceStatus { - p := new(TransactionTraceStatus) - *p = x - return p -} - -func (x TransactionTraceStatus) String() string { - return protoimpl.X.EnumStringOf(x.Descriptor(), protoreflect.EnumNumber(x)) -} - -func (TransactionTraceStatus) Descriptor() protoreflect.EnumDescriptor { - return file_sf_ethereum_type_v2_type_proto_enumTypes[0].Descriptor() -} - -func (TransactionTraceStatus) Type() protoreflect.EnumType { - return &file_sf_ethereum_type_v2_type_proto_enumTypes[0] -} - -func (x TransactionTraceStatus) Number() protoreflect.EnumNumber { - return protoreflect.EnumNumber(x) -} - -// Deprecated: Use TransactionTraceStatus.Descriptor instead. -func (TransactionTraceStatus) EnumDescriptor() ([]byte, []int) { - return file_sf_ethereum_type_v2_type_proto_rawDescGZIP(), []int{0} -} - -type CallType int32 - -const ( - CallType_UNSPECIFIED CallType = 0 - CallType_CALL CallType = 1 // direct? what's the name for `Call` alone? - CallType_CALLCODE CallType = 2 - CallType_DELEGATE CallType = 3 - CallType_STATIC CallType = 4 - CallType_CREATE CallType = 5 // create2 ? any other form of calls? -) - -// Enum value maps for CallType. -var ( - CallType_name = map[int32]string{ - 0: "UNSPECIFIED", - 1: "CALL", - 2: "CALLCODE", - 3: "DELEGATE", - 4: "STATIC", - 5: "CREATE", - } - CallType_value = map[string]int32{ - "UNSPECIFIED": 0, - "CALL": 1, - "CALLCODE": 2, - "DELEGATE": 3, - "STATIC": 4, - "CREATE": 5, - } -) - -func (x CallType) Enum() *CallType { - p := new(CallType) - *p = x - return p -} - -func (x CallType) String() string { - return protoimpl.X.EnumStringOf(x.Descriptor(), protoreflect.EnumNumber(x)) -} - -func (CallType) Descriptor() protoreflect.EnumDescriptor { - return file_sf_ethereum_type_v2_type_proto_enumTypes[1].Descriptor() -} - -func (CallType) Type() protoreflect.EnumType { - return &file_sf_ethereum_type_v2_type_proto_enumTypes[1] -} - -func (x CallType) Number() protoreflect.EnumNumber { - return protoreflect.EnumNumber(x) -} - -// Deprecated: Use CallType.Descriptor instead. -func (CallType) EnumDescriptor() ([]byte, []int) { - return file_sf_ethereum_type_v2_type_proto_rawDescGZIP(), []int{1} -} - -type Block_DetailLevel int32 - -const ( - Block_DETAILLEVEL_EXTENDED Block_DetailLevel = 0 - // DETAILLEVEL_TRACE = 1; // TBD - Block_DETAILLEVEL_BASE Block_DetailLevel = 2 -) - -// Enum value maps for Block_DetailLevel. -var ( - Block_DetailLevel_name = map[int32]string{ - 0: "DETAILLEVEL_EXTENDED", - 2: "DETAILLEVEL_BASE", - } - Block_DetailLevel_value = map[string]int32{ - "DETAILLEVEL_EXTENDED": 0, - "DETAILLEVEL_BASE": 2, - } -) - -func (x Block_DetailLevel) Enum() *Block_DetailLevel { - p := new(Block_DetailLevel) - *p = x - return p -} - -func (x Block_DetailLevel) String() string { - return protoimpl.X.EnumStringOf(x.Descriptor(), protoreflect.EnumNumber(x)) -} - -func (Block_DetailLevel) Descriptor() protoreflect.EnumDescriptor { - return file_sf_ethereum_type_v2_type_proto_enumTypes[2].Descriptor() -} - -func (Block_DetailLevel) Type() protoreflect.EnumType { - return &file_sf_ethereum_type_v2_type_proto_enumTypes[2] -} - -func (x Block_DetailLevel) Number() protoreflect.EnumNumber { - return protoreflect.EnumNumber(x) -} - -// Deprecated: Use Block_DetailLevel.Descriptor instead. -func (Block_DetailLevel) EnumDescriptor() ([]byte, []int) { - return file_sf_ethereum_type_v2_type_proto_rawDescGZIP(), []int{0, 0} -} - -type TransactionTrace_Type int32 - -const ( - // All transactions that ever existed prior Berlin fork before EIP-2718 was implemented. - TransactionTrace_TRX_TYPE_LEGACY TransactionTrace_Type = 0 - // Transaction that specicy an access list of contract/storage_keys that is going to be used - // in this transaction. - // - // Added in Berlin fork (EIP-2930). - TransactionTrace_TRX_TYPE_ACCESS_LIST TransactionTrace_Type = 1 - // Transaction that specifis an access list just like TRX_TYPE_ACCESS_LIST but in addition defines the - // max base gas gee and max priority gas fee to pay for this transaction. Transaction's of those type are - // executed against EIP-1559 rules which dictates a dynamic gas cost based on the congestion of the network. - TransactionTrace_TRX_TYPE_DYNAMIC_FEE TransactionTrace_Type = 2 - // Transaction which contain a large amount of data that cannot be accessed by EVM execution, but whose commitment - // can be accessed. The format is intended to be fully compatible with the format that will be used in full sharding. - // - // Transaction that defines specifis an access list just like TRX_TYPE_ACCESS_LIST and enables dynamic fee just like - // TRX_TYPE_DYNAMIC_FEE but in addition defines the fields 'max_fee_per_data_gas' of type 'uint256' and the fields - // 'blob_versioned_hashes' field represents a list of hash outputs from 'kzg_to_versioned_hash'. - // - // Activated in Dencun - TransactionTrace_TRX_TYPE_BLOB TransactionTrace_Type = 3 - // Transaction that sets code to an EOA (Externally Owned Accounts) - // - // Activated in Prague (eip-7702) - TransactionTrace_TRX_TYPE_SET_CODE TransactionTrace_Type = 4 - // Arbitrum-specific transactions - TransactionTrace_TRX_TYPE_ARBITRUM_DEPOSIT TransactionTrace_Type = 100 - TransactionTrace_TRX_TYPE_ARBITRUM_UNSIGNED TransactionTrace_Type = 101 - TransactionTrace_TRX_TYPE_ARBITRUM_CONTRACT TransactionTrace_Type = 102 - TransactionTrace_TRX_TYPE_ARBITRUM_RETRY TransactionTrace_Type = 104 - TransactionTrace_TRX_TYPE_ARBITRUM_SUBMIT_RETRYABLE TransactionTrace_Type = 105 - TransactionTrace_TRX_TYPE_ARBITRUM_INTERNAL TransactionTrace_Type = 106 - TransactionTrace_TRX_TYPE_ARBITRUM_LEGACY TransactionTrace_Type = 120 - // OPTIMISM-specific transactions - TransactionTrace_TRX_TYPE_OPTIMISM_DEPOSIT TransactionTrace_Type = 126 -) - -// Enum value maps for TransactionTrace_Type. -var ( - TransactionTrace_Type_name = map[int32]string{ - 0: "TRX_TYPE_LEGACY", - 1: "TRX_TYPE_ACCESS_LIST", - 2: "TRX_TYPE_DYNAMIC_FEE", - 3: "TRX_TYPE_BLOB", - 4: "TRX_TYPE_SET_CODE", - 100: "TRX_TYPE_ARBITRUM_DEPOSIT", - 101: "TRX_TYPE_ARBITRUM_UNSIGNED", - 102: "TRX_TYPE_ARBITRUM_CONTRACT", - 104: "TRX_TYPE_ARBITRUM_RETRY", - 105: "TRX_TYPE_ARBITRUM_SUBMIT_RETRYABLE", - 106: "TRX_TYPE_ARBITRUM_INTERNAL", - 120: "TRX_TYPE_ARBITRUM_LEGACY", - 126: "TRX_TYPE_OPTIMISM_DEPOSIT", - } - TransactionTrace_Type_value = map[string]int32{ - "TRX_TYPE_LEGACY": 0, - "TRX_TYPE_ACCESS_LIST": 1, - "TRX_TYPE_DYNAMIC_FEE": 2, - "TRX_TYPE_BLOB": 3, - "TRX_TYPE_SET_CODE": 4, - "TRX_TYPE_ARBITRUM_DEPOSIT": 100, - "TRX_TYPE_ARBITRUM_UNSIGNED": 101, - "TRX_TYPE_ARBITRUM_CONTRACT": 102, - "TRX_TYPE_ARBITRUM_RETRY": 104, - "TRX_TYPE_ARBITRUM_SUBMIT_RETRYABLE": 105, - "TRX_TYPE_ARBITRUM_INTERNAL": 106, - "TRX_TYPE_ARBITRUM_LEGACY": 120, - "TRX_TYPE_OPTIMISM_DEPOSIT": 126, - } -) - -func (x TransactionTrace_Type) Enum() *TransactionTrace_Type { - p := new(TransactionTrace_Type) - *p = x - return p -} - -func (x TransactionTrace_Type) String() string { - return protoimpl.X.EnumStringOf(x.Descriptor(), protoreflect.EnumNumber(x)) -} - -func (TransactionTrace_Type) Descriptor() protoreflect.EnumDescriptor { - return file_sf_ethereum_type_v2_type_proto_enumTypes[3].Descriptor() -} - -func (TransactionTrace_Type) Type() protoreflect.EnumType { - return &file_sf_ethereum_type_v2_type_proto_enumTypes[3] -} - -func (x TransactionTrace_Type) Number() protoreflect.EnumNumber { - return protoreflect.EnumNumber(x) -} - -// Deprecated: Use TransactionTrace_Type.Descriptor instead. -func (TransactionTrace_Type) EnumDescriptor() ([]byte, []int) { - return file_sf_ethereum_type_v2_type_proto_rawDescGZIP(), []int{5, 0} -} - -// Obtain all balanche change reasons under deep mind repository: -// -// ```shell -// ack -ho 'BalanceChangeReason\(".*"\)' | grep -Eo '".*"' | sort | uniq -// ``` -type BalanceChange_Reason int32 - -const ( - BalanceChange_REASON_UNKNOWN BalanceChange_Reason = 0 - BalanceChange_REASON_REWARD_MINE_UNCLE BalanceChange_Reason = 1 - BalanceChange_REASON_REWARD_MINE_BLOCK BalanceChange_Reason = 2 - BalanceChange_REASON_DAO_REFUND_CONTRACT BalanceChange_Reason = 3 - BalanceChange_REASON_DAO_ADJUST_BALANCE BalanceChange_Reason = 4 - BalanceChange_REASON_TRANSFER BalanceChange_Reason = 5 - BalanceChange_REASON_GENESIS_BALANCE BalanceChange_Reason = 6 - BalanceChange_REASON_GAS_BUY BalanceChange_Reason = 7 - BalanceChange_REASON_REWARD_TRANSACTION_FEE BalanceChange_Reason = 8 - BalanceChange_REASON_REWARD_FEE_RESET BalanceChange_Reason = 14 - BalanceChange_REASON_GAS_REFUND BalanceChange_Reason = 9 - BalanceChange_REASON_TOUCH_ACCOUNT BalanceChange_Reason = 10 - BalanceChange_REASON_SUICIDE_REFUND BalanceChange_Reason = 11 - BalanceChange_REASON_SUICIDE_WITHDRAW BalanceChange_Reason = 13 - BalanceChange_REASON_CALL_BALANCE_OVERRIDE BalanceChange_Reason = 12 - // Used on chain(s) where some Ether burning happens - BalanceChange_REASON_BURN BalanceChange_Reason = 15 - BalanceChange_REASON_WITHDRAWAL BalanceChange_Reason = 16 - // Rewards for Blob processing on BNB chain added in Tycho hard-fork, refers - // to BNB documentation to check the timestamp at which it was activated. - BalanceChange_REASON_REWARD_BLOB_FEE BalanceChange_Reason = 17 - // USE on optimism chan - BalanceChange_REASON_INCREASE_MINT BalanceChange_Reason = 18 -) - -// Enum value maps for BalanceChange_Reason. -var ( - BalanceChange_Reason_name = map[int32]string{ - 0: "REASON_UNKNOWN", - 1: "REASON_REWARD_MINE_UNCLE", - 2: "REASON_REWARD_MINE_BLOCK", - 3: "REASON_DAO_REFUND_CONTRACT", - 4: "REASON_DAO_ADJUST_BALANCE", - 5: "REASON_TRANSFER", - 6: "REASON_GENESIS_BALANCE", - 7: "REASON_GAS_BUY", - 8: "REASON_REWARD_TRANSACTION_FEE", - 14: "REASON_REWARD_FEE_RESET", - 9: "REASON_GAS_REFUND", - 10: "REASON_TOUCH_ACCOUNT", - 11: "REASON_SUICIDE_REFUND", - 13: "REASON_SUICIDE_WITHDRAW", - 12: "REASON_CALL_BALANCE_OVERRIDE", - 15: "REASON_BURN", - 16: "REASON_WITHDRAWAL", - 17: "REASON_REWARD_BLOB_FEE", - 18: "REASON_INCREASE_MINT", - } - BalanceChange_Reason_value = map[string]int32{ - "REASON_UNKNOWN": 0, - "REASON_REWARD_MINE_UNCLE": 1, - "REASON_REWARD_MINE_BLOCK": 2, - "REASON_DAO_REFUND_CONTRACT": 3, - "REASON_DAO_ADJUST_BALANCE": 4, - "REASON_TRANSFER": 5, - "REASON_GENESIS_BALANCE": 6, - "REASON_GAS_BUY": 7, - "REASON_REWARD_TRANSACTION_FEE": 8, - "REASON_REWARD_FEE_RESET": 14, - "REASON_GAS_REFUND": 9, - "REASON_TOUCH_ACCOUNT": 10, - "REASON_SUICIDE_REFUND": 11, - "REASON_SUICIDE_WITHDRAW": 13, - "REASON_CALL_BALANCE_OVERRIDE": 12, - "REASON_BURN": 15, - "REASON_WITHDRAWAL": 16, - "REASON_REWARD_BLOB_FEE": 17, - "REASON_INCREASE_MINT": 18, - } -) - -func (x BalanceChange_Reason) Enum() *BalanceChange_Reason { - p := new(BalanceChange_Reason) - *p = x - return p -} - -func (x BalanceChange_Reason) String() string { - return protoimpl.X.EnumStringOf(x.Descriptor(), protoreflect.EnumNumber(x)) -} - -func (BalanceChange_Reason) Descriptor() protoreflect.EnumDescriptor { - return file_sf_ethereum_type_v2_type_proto_enumTypes[4].Descriptor() -} - -func (BalanceChange_Reason) Type() protoreflect.EnumType { - return &file_sf_ethereum_type_v2_type_proto_enumTypes[4] -} - -func (x BalanceChange_Reason) Number() protoreflect.EnumNumber { - return protoreflect.EnumNumber(x) -} - -// Deprecated: Use BalanceChange_Reason.Descriptor instead. -func (BalanceChange_Reason) EnumDescriptor() ([]byte, []int) { - return file_sf_ethereum_type_v2_type_proto_rawDescGZIP(), []int{11, 0} -} - -// Obtain all gas change reasons under deep mind repository: -// -// ```shell -// ack -ho 'GasChangeReason\(".*"\)' | grep -Eo '".*"' | sort | uniq -// ``` -type GasChange_Reason int32 - -const ( - GasChange_REASON_UNKNOWN GasChange_Reason = 0 - // REASON_CALL is the amount of gas that will be charged for a 'CALL' opcode executed by the EVM - GasChange_REASON_CALL GasChange_Reason = 1 - // REASON_CALL_CODE is the amount of gas that will be charged for a 'CALLCODE' opcode executed by the EVM - GasChange_REASON_CALL_CODE GasChange_Reason = 2 - // REASON_CALL_DATA_COPY is the amount of gas that will be charged for a 'CALLDATACOPY' opcode executed by the EVM - GasChange_REASON_CALL_DATA_COPY GasChange_Reason = 3 - // REASON_CODE_COPY is the amount of gas that will be charged for a 'CALLDATACOPY' opcode executed by the EVM - GasChange_REASON_CODE_COPY GasChange_Reason = 4 - // REASON_CODE_STORAGE is the amount of gas that will be charged for code storage - GasChange_REASON_CODE_STORAGE GasChange_Reason = 5 - // REASON_CONTRACT_CREATION is the amount of gas that will be charged for a 'CREATE' opcode executed by the EVM and for the gas - // burned for a CREATE, today controlled by EIP150 rules - GasChange_REASON_CONTRACT_CREATION GasChange_Reason = 6 - // REASON_CONTRACT_CREATION2 is the amount of gas that will be charged for a 'CREATE2' opcode executed by the EVM and for the gas - // burned for a CREATE2, today controlled by EIP150 rules - GasChange_REASON_CONTRACT_CREATION2 GasChange_Reason = 7 - // REASON_DELEGATE_CALL is the amount of gas that will be charged for a 'DELEGATECALL' opcode executed by the EVM - GasChange_REASON_DELEGATE_CALL GasChange_Reason = 8 - // REASON_EVENT_LOG is the amount of gas that will be charged for a 'LOG' opcode executed by the EVM - GasChange_REASON_EVENT_LOG GasChange_Reason = 9 - // REASON_EXT_CODE_COPY is the amount of gas that will be charged for a 'LOG' opcode executed by the EVM - GasChange_REASON_EXT_CODE_COPY GasChange_Reason = 10 - // REASON_FAILED_EXECUTION is the burning of the remaining gas when the execution failed without a revert - GasChange_REASON_FAILED_EXECUTION GasChange_Reason = 11 - // REASON_INTRINSIC_GAS is the amount of gas that will be charged for the intrinsic cost of the transaction, there is - // always exactly one of those per transaction - GasChange_REASON_INTRINSIC_GAS GasChange_Reason = 12 - // GasChangePrecompiledContract is the amount of gas that will be charged for a precompiled contract execution - GasChange_REASON_PRECOMPILED_CONTRACT GasChange_Reason = 13 - // REASON_REFUND_AFTER_EXECUTION is the amount of gas that will be refunded to the caller after the execution of the call, - // if there is left over at the end of execution - GasChange_REASON_REFUND_AFTER_EXECUTION GasChange_Reason = 14 - // REASON_RETURN is the amount of gas that will be charged for a 'RETURN' opcode executed by the EVM - GasChange_REASON_RETURN GasChange_Reason = 15 - // REASON_RETURN_DATA_COPY is the amount of gas that will be charged for a 'RETURNDATACOPY' opcode executed by the EVM - GasChange_REASON_RETURN_DATA_COPY GasChange_Reason = 16 - // REASON_REVERT is the amount of gas that will be charged for a 'REVERT' opcode executed by the EVM - GasChange_REASON_REVERT GasChange_Reason = 17 - // REASON_SELF_DESTRUCT is the amount of gas that will be charged for a 'SELFDESTRUCT' opcode executed by the EVM - GasChange_REASON_SELF_DESTRUCT GasChange_Reason = 18 - // REASON_STATIC_CALL is the amount of gas that will be charged for a 'STATICALL' opcode executed by the EVM - GasChange_REASON_STATIC_CALL GasChange_Reason = 19 - // REASON_STATE_COLD_ACCESS is the amount of gas that will be charged for a cold storage access as controlled by EIP2929 rules - // - // Added in Berlin fork (Geth 1.10+) - GasChange_REASON_STATE_COLD_ACCESS GasChange_Reason = 20 - // REASON_TX_INITIAL_BALANCE is the initial balance for the call which will be equal to the gasLimit of the call - // - // Added as new tracing reason in Geth, available only on some chains - GasChange_REASON_TX_INITIAL_BALANCE GasChange_Reason = 21 - // REASON_TX_REFUNDS is the sum of all refunds which happened during the tx execution (e.g. storage slot being cleared) - // this generates an increase in gas. There is only one such gas change per transaction. - // - // Added as new tracing reason in Geth, available only on some chains - GasChange_REASON_TX_REFUNDS GasChange_Reason = 22 - // REASON_TX_LEFT_OVER_RETURNED is the amount of gas left over at the end of transaction's execution that will be returned - // to the chain. This change will always be a negative change as we "drain" left over gas towards 0. If there was no gas - // left at the end of execution, no such even will be emitted. The returned gas's value in Wei is returned to caller. - // There is at most one of such gas change per transaction. - // - // Added as new tracing reason in Geth, available only on some chains - GasChange_REASON_TX_LEFT_OVER_RETURNED GasChange_Reason = 23 - // REASON_CALL_INITIAL_BALANCE is the initial balance for the call which will be equal to the gasLimit of the call. There is only - // one such gas change per call. - // - // Added as new tracing reason in Geth, available only on some chains - GasChange_REASON_CALL_INITIAL_BALANCE GasChange_Reason = 24 - // REASON_CALL_LEFT_OVER_RETURNED is the amount of gas left over that will be returned to the caller, this change will always - // be a negative change as we "drain" left over gas towards 0. If there was no gas left at the end of execution, no such even - // will be emitted. - GasChange_REASON_CALL_LEFT_OVER_RETURNED GasChange_Reason = 25 - GasChange_REASON_WITNESS_CONTRACT_INIT GasChange_Reason = 26 - // GasChangeWitnessContractCreation flags the event of adding to the witness during the contract creation finalization step. - GasChange_REASON_WITNESS_CONTRACT_CREATION GasChange_Reason = 27 - // GasChangeWitnessCodeChunk flags the event of adding one or more contract code chunks to the witness. - GasChange_REASON_WITNESS_CODE_CHUNK GasChange_Reason = 28 - // GasChangeWitnessContractCollisionCheck flags the event of adding to the witness when checking for contract address collision. - GasChange_REASON_WITNESS_CONTRACT_COLLISION_CHECK GasChange_Reason = 29 - // GasChangeTxDataFloor is the amount of extra gas the transaction has to pay to reach the minimum gas requirement for the - // transaction data. This change will always be a negative change. - GasChange_REASON_TX_DATA_FLOOR GasChange_Reason = 30 -) - -// Enum value maps for GasChange_Reason. -var ( - GasChange_Reason_name = map[int32]string{ - 0: "REASON_UNKNOWN", - 1: "REASON_CALL", - 2: "REASON_CALL_CODE", - 3: "REASON_CALL_DATA_COPY", - 4: "REASON_CODE_COPY", - 5: "REASON_CODE_STORAGE", - 6: "REASON_CONTRACT_CREATION", - 7: "REASON_CONTRACT_CREATION2", - 8: "REASON_DELEGATE_CALL", - 9: "REASON_EVENT_LOG", - 10: "REASON_EXT_CODE_COPY", - 11: "REASON_FAILED_EXECUTION", - 12: "REASON_INTRINSIC_GAS", - 13: "REASON_PRECOMPILED_CONTRACT", - 14: "REASON_REFUND_AFTER_EXECUTION", - 15: "REASON_RETURN", - 16: "REASON_RETURN_DATA_COPY", - 17: "REASON_REVERT", - 18: "REASON_SELF_DESTRUCT", - 19: "REASON_STATIC_CALL", - 20: "REASON_STATE_COLD_ACCESS", - 21: "REASON_TX_INITIAL_BALANCE", - 22: "REASON_TX_REFUNDS", - 23: "REASON_TX_LEFT_OVER_RETURNED", - 24: "REASON_CALL_INITIAL_BALANCE", - 25: "REASON_CALL_LEFT_OVER_RETURNED", - 26: "REASON_WITNESS_CONTRACT_INIT", - 27: "REASON_WITNESS_CONTRACT_CREATION", - 28: "REASON_WITNESS_CODE_CHUNK", - 29: "REASON_WITNESS_CONTRACT_COLLISION_CHECK", - 30: "REASON_TX_DATA_FLOOR", - } - GasChange_Reason_value = map[string]int32{ - "REASON_UNKNOWN": 0, - "REASON_CALL": 1, - "REASON_CALL_CODE": 2, - "REASON_CALL_DATA_COPY": 3, - "REASON_CODE_COPY": 4, - "REASON_CODE_STORAGE": 5, - "REASON_CONTRACT_CREATION": 6, - "REASON_CONTRACT_CREATION2": 7, - "REASON_DELEGATE_CALL": 8, - "REASON_EVENT_LOG": 9, - "REASON_EXT_CODE_COPY": 10, - "REASON_FAILED_EXECUTION": 11, - "REASON_INTRINSIC_GAS": 12, - "REASON_PRECOMPILED_CONTRACT": 13, - "REASON_REFUND_AFTER_EXECUTION": 14, - "REASON_RETURN": 15, - "REASON_RETURN_DATA_COPY": 16, - "REASON_REVERT": 17, - "REASON_SELF_DESTRUCT": 18, - "REASON_STATIC_CALL": 19, - "REASON_STATE_COLD_ACCESS": 20, - "REASON_TX_INITIAL_BALANCE": 21, - "REASON_TX_REFUNDS": 22, - "REASON_TX_LEFT_OVER_RETURNED": 23, - "REASON_CALL_INITIAL_BALANCE": 24, - "REASON_CALL_LEFT_OVER_RETURNED": 25, - "REASON_WITNESS_CONTRACT_INIT": 26, - "REASON_WITNESS_CONTRACT_CREATION": 27, - "REASON_WITNESS_CODE_CHUNK": 28, - "REASON_WITNESS_CONTRACT_COLLISION_CHECK": 29, - "REASON_TX_DATA_FLOOR": 30, - } -) - -func (x GasChange_Reason) Enum() *GasChange_Reason { - p := new(GasChange_Reason) - *p = x - return p -} - -func (x GasChange_Reason) String() string { - return protoimpl.X.EnumStringOf(x.Descriptor(), protoreflect.EnumNumber(x)) -} - -func (GasChange_Reason) Descriptor() protoreflect.EnumDescriptor { - return file_sf_ethereum_type_v2_type_proto_enumTypes[5].Descriptor() -} - -func (GasChange_Reason) Type() protoreflect.EnumType { - return &file_sf_ethereum_type_v2_type_proto_enumTypes[5] -} - -func (x GasChange_Reason) Number() protoreflect.EnumNumber { - return protoreflect.EnumNumber(x) -} - -// Deprecated: Use GasChange_Reason.Descriptor instead. -func (GasChange_Reason) EnumDescriptor() ([]byte, []int) { - return file_sf_ethereum_type_v2_type_proto_rawDescGZIP(), []int{15, 0} -} - -// Block is the representation of the tracing of a block in the Ethereum -// blockchain. A block is a collection of [TransactionTrace] that are grouped -// together and processed as an atomic unit. Each [TransactionTrace] is composed -// of a series of [Call] (a.k.a internal transactions) and there is also at -// least one call per transaction a.k.a the root call which essentially has the -// same parameters as the transaction itself (e.g. `from`, `to`, `gas`, `value`, -// etc.). -// -// The exact tracing method used to build the block must be checked against -// [DetailLevel] field. There is two levels of details available, `BASE` and -// `EXTENDED`. The `BASE` level has been extracted using archive node RPC calls -// and will contain only the block header, transaction receipts and event logs. -// Refers to the Firehose service provider to know which blocks are offered on -// each network. -// -// The `EXTENDED` level has been extracted using the Firehose tracer and all -// fields are available in this Protobuf. -// -// The Ethereum block model is used across many chains which means that it -// happen that certain fields are not available in one chain but are available -// in another. Each field should be documented when necesssary if it's available -// on a subset of chains. -// -// One major concept to get about the Block is the concept of 'ordinal'. The -// ordinal is a number that is used to globally order every element of execution -// that happened throughout the processing of the block like -// [TransactionTracer], [Call], [Log], [BalanceChange], [StateChange], etc. -// Element that have a start and end interval, [Transaction] and [Call], will -// have two ordinals: `begin_ordinal` and `end_ordinal`. Element that are -// executed as "point in time" [Log], [BalanceChange], [StateChange], etc. will -// have only one ordinal named `ordinal`. If you take all of the message in the -// Block that have an 'ordinal' field in an array and you sort each element -// against the `ordinal` field, you will get the exact order of execution of -// each element in the block. -// -// All the 'ordinal' fields in a block are globally unique for the given block, -// it is **not** a chain-wide global ordering. Furthermore, caution must be take -// with reverted elements due to execution failure. For anything attached to a -// [Call] that has a `state_reverted` field set to `true`, the `ordinal` field -// is not reliable and should not be used to order the element against other -// elements in the block as those element might have 0 as the ordinal. Only -// successful calls have a reliable `ordinal` field. -type Block struct { - state protoimpl.MessageState `protogen:"open.v1"` - // Hash is the block's hash. - Hash []byte `protobuf:"bytes,2,opt,name=hash,proto3" json:"hash,omitempty"` - // Number is the block's height at which this block was mined. - Number uint64 `protobuf:"varint,3,opt,name=number,proto3" json:"number,omitempty"` - // Size is the size in bytes of the RLP encoding of the block according to Ethereum - // rules. - Size uint64 `protobuf:"varint,4,opt,name=size,proto3" json:"size,omitempty"` - // Header contain's the block's header information like its parent hash, the merkel root hash - // and all other information the form a block. - Header *BlockHeader `protobuf:"bytes,5,opt,name=header,proto3" json:"header,omitempty"` - // Uncles represents block produced with a valid solution but were not actually choosen - // as the canonical block for the given height so they are mostly "forked" blocks. - // - // If the Block has been produced using the Proof of Stake consensus algorithm, this - // field will actually be always empty. - Uncles []*BlockHeader `protobuf:"bytes,6,rep,name=uncles,proto3" json:"uncles,omitempty"` - // TransactionTraces hold the execute trace of all the transactions that were executed - // in this block. In in there that you will find most of the Ethereum data model. - // - // They are ordered by the order of execution of the transaction in the block. - TransactionTraces []*TransactionTrace `protobuf:"bytes,10,rep,name=transaction_traces,json=transactionTraces,proto3" json:"transaction_traces,omitempty"` - // BalanceChanges here is the array of ETH transfer that happened at the block level - // outside of the normal transaction flow of a block. The best example of this is mining - // reward for the block mined, the transfer of ETH to the miner happens outside the normal - // transaction flow of the chain and is recorded as a `BalanceChange` here since we cannot - // attached it to any transaction. - // - // Only available in DetailLevel: EXTENDED - BalanceChanges []*BalanceChange `protobuf:"bytes,11,rep,name=balance_changes,json=balanceChanges,proto3" json:"balance_changes,omitempty"` - // DetailLevel affects the data available in this block. - // - // ## DetailLevel_EXTENDED - // - // Describes the most complete block, with traces, balance changes, storage - // changes. It is extracted during the execution of the block. - // - // ## DetailLevel_BASE - // - // Describes a block that contains only the block header, transaction receipts - // and event logs: everything that can be extracted using the base JSON-RPC - // interface - // (https://ethereum.org/en/developers/docs/apis/json-rpc/#json-rpc-methods) - // Furthermore, the eth_getTransactionReceipt call has been avoided because it - // brings only minimal improvements at the cost of requiring an archive node - // or a full node with complete transaction index. - DetailLevel Block_DetailLevel `protobuf:"varint,12,opt,name=detail_level,json=detailLevel,proto3,enum=sf.ethereum.type.v2.Block_DetailLevel" json:"detail_level,omitempty"` - // CodeChanges here is the array of smart code change that happened that happened at the block level - // outside of the normal transaction flow of a block. Some Ethereum's fork like BSC and Polygon - // has some capabilities to upgrade internal smart contracts used usually to track the validator - // list. - // - // On hard fork, some procedure runs to upgrade the smart contract code to a new version. In those - // network, a `CodeChange` for each modified smart contract on upgrade would be present here. Note - // that this happen rarely, so the vast majority of block will have an empty list here. - // - // Only available in DetailLevel: EXTENDED - CodeChanges []*CodeChange `protobuf:"bytes,20,rep,name=code_changes,json=codeChanges,proto3" json:"code_changes,omitempty"` - // System calls are introduced in Cancun, along with blobs. They are executed outside of transactions but affect the state. - // - // Only available in DetailLevel: EXTENDED - SystemCalls []*Call `protobuf:"bytes,21,rep,name=system_calls,json=systemCalls,proto3" json:"system_calls,omitempty"` - // Ver represents that data model version of the block, it is used internally by Firehose on Ethereum - // as a validation that we are reading the correct version. - Ver int32 `protobuf:"varint,1,opt,name=ver,proto3" json:"ver,omitempty"` - unknownFields protoimpl.UnknownFields - sizeCache protoimpl.SizeCache -} - -func (x *Block) Reset() { - *x = Block{} - mi := &file_sf_ethereum_type_v2_type_proto_msgTypes[0] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) -} - -func (x *Block) String() string { - return protoimpl.X.MessageStringOf(x) -} - -func (*Block) ProtoMessage() {} - -func (x *Block) ProtoReflect() protoreflect.Message { - mi := &file_sf_ethereum_type_v2_type_proto_msgTypes[0] - if x != nil { - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - if ms.LoadMessageInfo() == nil { - ms.StoreMessageInfo(mi) - } - return ms - } - return mi.MessageOf(x) -} - -// Deprecated: Use Block.ProtoReflect.Descriptor instead. -func (*Block) Descriptor() ([]byte, []int) { - return file_sf_ethereum_type_v2_type_proto_rawDescGZIP(), []int{0} -} - -func (x *Block) GetHash() []byte { - if x != nil { - return x.Hash - } - return nil -} - -func (x *Block) GetNumber() uint64 { - if x != nil { - return x.Number - } - return 0 -} - -func (x *Block) GetSize() uint64 { - if x != nil { - return x.Size - } - return 0 -} - -func (x *Block) GetHeader() *BlockHeader { - if x != nil { - return x.Header - } - return nil -} - -func (x *Block) GetUncles() []*BlockHeader { - if x != nil { - return x.Uncles - } - return nil -} - -func (x *Block) GetTransactionTraces() []*TransactionTrace { - if x != nil { - return x.TransactionTraces - } - return nil -} - -func (x *Block) GetBalanceChanges() []*BalanceChange { - if x != nil { - return x.BalanceChanges - } - return nil -} - -func (x *Block) GetDetailLevel() Block_DetailLevel { - if x != nil { - return x.DetailLevel - } - return Block_DETAILLEVEL_EXTENDED -} - -func (x *Block) GetCodeChanges() []*CodeChange { - if x != nil { - return x.CodeChanges - } - return nil -} - -func (x *Block) GetSystemCalls() []*Call { - if x != nil { - return x.SystemCalls - } - return nil -} - -func (x *Block) GetVer() int32 { - if x != nil { - return x.Ver - } - return 0 -} - -type BlockHeader struct { - state protoimpl.MessageState `protogen:"open.v1"` - ParentHash []byte `protobuf:"bytes,1,opt,name=parent_hash,json=parentHash,proto3" json:"parent_hash,omitempty"` - // Uncle hash of the block, some reference it as `sha3Uncles`, but `sha3“ is badly worded, so we prefer `uncle_hash`, also - // referred as `ommers` in EIP specification. - // - // If the Block containing this `BlockHeader` has been produced using the Proof of Stake - // consensus algorithm, this field will actually be constant and set to `0x1dcc4de8dec75d7aab85b567b6ccd41ad312451b948a7413f0a142fd40d49347`. - UncleHash []byte `protobuf:"bytes,2,opt,name=uncle_hash,json=uncleHash,proto3" json:"uncle_hash,omitempty"` - Coinbase []byte `protobuf:"bytes,3,opt,name=coinbase,proto3" json:"coinbase,omitempty"` - StateRoot []byte `protobuf:"bytes,4,opt,name=state_root,json=stateRoot,proto3" json:"state_root,omitempty"` - TransactionsRoot []byte `protobuf:"bytes,5,opt,name=transactions_root,json=transactionsRoot,proto3" json:"transactions_root,omitempty"` - ReceiptRoot []byte `protobuf:"bytes,6,opt,name=receipt_root,json=receiptRoot,proto3" json:"receipt_root,omitempty"` - LogsBloom []byte `protobuf:"bytes,7,opt,name=logs_bloom,json=logsBloom,proto3" json:"logs_bloom,omitempty"` - // Difficulty is the difficulty of the Proof of Work algorithm that was required to compute a solution. - // - // If the Block containing this `BlockHeader` has been produced using the Proof of Stake - // consensus algorithm, this field will actually be constant and set to `0x00`. - Difficulty *BigInt `protobuf:"bytes,8,opt,name=difficulty,proto3" json:"difficulty,omitempty"` - // TotalDifficulty used to be the sum of all previous blocks difficulty including this block difficulty. - // - // # It has been deprecated in geth v1.15.0 but was already removed from the JSON-RPC interface for a while - // - // Deprecated: Marked as deprecated in sf/ethereum/type/v2/type.proto. - TotalDifficulty *BigInt `protobuf:"bytes,17,opt,name=total_difficulty,json=totalDifficulty,proto3" json:"total_difficulty,omitempty"` - Number uint64 `protobuf:"varint,9,opt,name=number,proto3" json:"number,omitempty"` - GasLimit uint64 `protobuf:"varint,10,opt,name=gas_limit,json=gasLimit,proto3" json:"gas_limit,omitempty"` - GasUsed uint64 `protobuf:"varint,11,opt,name=gas_used,json=gasUsed,proto3" json:"gas_used,omitempty"` - Timestamp *timestamppb.Timestamp `protobuf:"bytes,12,opt,name=timestamp,proto3" json:"timestamp,omitempty"` - // ExtraData is free-form bytes included in the block by the "miner". While on Yellow paper of - // Ethereum this value is maxed to 32 bytes, other consensus algorithm like Clique and some other - // forks are using bigger values to carry special consensus data. - // - // If the Block containing this `BlockHeader` has been produced using the Proof of Stake - // consensus algorithm, this field is strictly enforced to be <= 32 bytes. - ExtraData []byte `protobuf:"bytes,13,opt,name=extra_data,json=extraData,proto3" json:"extra_data,omitempty"` - // MixHash is used to prove, when combined with the `nonce` that sufficient amount of computation has been - // achieved and that the solution found is valid. - MixHash []byte `protobuf:"bytes,14,opt,name=mix_hash,json=mixHash,proto3" json:"mix_hash,omitempty"` - // Nonce is used to prove, when combined with the `mix_hash` that sufficient amount of computation has been - // achieved and that the solution found is valid. - // - // If the Block containing this `BlockHeader` has been produced using the Proof of Stake - // consensus algorithm, this field will actually be constant and set to `0`. - Nonce uint64 `protobuf:"varint,15,opt,name=nonce,proto3" json:"nonce,omitempty"` - // Hash is the hash of the block which is actually the computation: - // - // Keccak256(rlp([ - // parent_hash, - // uncle_hash, - // coinbase, - // state_root, - // transactions_root, - // receipt_root, - // logs_bloom, - // difficulty, - // number, - // gas_limit, - // gas_used, - // timestamp, - // extra_data, - // mix_hash, - // nonce, - // base_fee_per_gas (to be included only if London fork is active) - // withdrawals_root (to be included only if Shangai fork is active) - // blob_gas_used (to be included only if Cancun fork is active) - // excess_blob_gas (to be included only if Cancun fork is active) - // parent_beacon_root (to be included only if Cancun fork is active) - // ])) - Hash []byte `protobuf:"bytes,16,opt,name=hash,proto3" json:"hash,omitempty"` - // Base fee per gas according to EIP-1559 (e.g. London Fork) rules, only set if London is present/active on the chain. - BaseFeePerGas *BigInt `protobuf:"bytes,18,opt,name=base_fee_per_gas,json=baseFeePerGas,proto3" json:"base_fee_per_gas,omitempty"` - // Withdrawals root hash according to EIP-4895 (e.g. Shangai Fork) rules, only set if Shangai is present/active on the chain. - // - // Only available in DetailLevel: EXTENDED - WithdrawalsRoot []byte `protobuf:"bytes,19,opt,name=withdrawals_root,json=withdrawalsRoot,proto3" json:"withdrawals_root,omitempty"` - // TxDependency is list of transaction indexes that are dependent on each other in the block - // header. This is metadata only that was used by the internal Polygon parallel execution engine. - // - // This field was available in a few versions on Polygon Mainnet and Polygon Mumbai chains. It was actually - // removed and is not populated anymore. It's now embeded in the `extraData` field, refer to Polygon source - // code to determine how to extract it if you need it. - // - // Only available in DetailLevel: EXTENDED - TxDependency *Uint64NestedArray `protobuf:"bytes,20,opt,name=tx_dependency,json=txDependency,proto3" json:"tx_dependency,omitempty"` - // BlobGasUsed was added by EIP-4844 and is ignored in legacy headers. - BlobGasUsed *uint64 `protobuf:"varint,22,opt,name=blob_gas_used,json=blobGasUsed,proto3,oneof" json:"blob_gas_used,omitempty"` - // ExcessBlobGas was added by EIP-4844 and is ignored in legacy headers. - ExcessBlobGas *uint64 `protobuf:"varint,23,opt,name=excess_blob_gas,json=excessBlobGas,proto3,oneof" json:"excess_blob_gas,omitempty"` - // ParentBeaconRoot was added by EIP-4788 and is ignored in legacy headers. - ParentBeaconRoot []byte `protobuf:"bytes,24,opt,name=parent_beacon_root,json=parentBeaconRoot,proto3" json:"parent_beacon_root,omitempty"` - // RequestsHash was added by EIP-7685 and is ignored in legacy headers. - RequestsHash []byte `protobuf:"bytes,25,opt,name=requests_hash,json=requestsHash,proto3" json:"requests_hash,omitempty"` - unknownFields protoimpl.UnknownFields - sizeCache protoimpl.SizeCache -} - -func (x *BlockHeader) Reset() { - *x = BlockHeader{} - mi := &file_sf_ethereum_type_v2_type_proto_msgTypes[1] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) -} - -func (x *BlockHeader) String() string { - return protoimpl.X.MessageStringOf(x) -} - -func (*BlockHeader) ProtoMessage() {} - -func (x *BlockHeader) ProtoReflect() protoreflect.Message { - mi := &file_sf_ethereum_type_v2_type_proto_msgTypes[1] - if x != nil { - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - if ms.LoadMessageInfo() == nil { - ms.StoreMessageInfo(mi) - } - return ms - } - return mi.MessageOf(x) -} - -// Deprecated: Use BlockHeader.ProtoReflect.Descriptor instead. -func (*BlockHeader) Descriptor() ([]byte, []int) { - return file_sf_ethereum_type_v2_type_proto_rawDescGZIP(), []int{1} -} - -func (x *BlockHeader) GetParentHash() []byte { - if x != nil { - return x.ParentHash - } - return nil -} - -func (x *BlockHeader) GetUncleHash() []byte { - if x != nil { - return x.UncleHash - } - return nil -} - -func (x *BlockHeader) GetCoinbase() []byte { - if x != nil { - return x.Coinbase - } - return nil -} - -func (x *BlockHeader) GetStateRoot() []byte { - if x != nil { - return x.StateRoot - } - return nil -} - -func (x *BlockHeader) GetTransactionsRoot() []byte { - if x != nil { - return x.TransactionsRoot - } - return nil -} - -func (x *BlockHeader) GetReceiptRoot() []byte { - if x != nil { - return x.ReceiptRoot - } - return nil -} - -func (x *BlockHeader) GetLogsBloom() []byte { - if x != nil { - return x.LogsBloom - } - return nil -} - -func (x *BlockHeader) GetDifficulty() *BigInt { - if x != nil { - return x.Difficulty - } - return nil -} - -// Deprecated: Marked as deprecated in sf/ethereum/type/v2/type.proto. -func (x *BlockHeader) GetTotalDifficulty() *BigInt { - if x != nil { - return x.TotalDifficulty - } - return nil -} - -func (x *BlockHeader) GetNumber() uint64 { - if x != nil { - return x.Number - } - return 0 -} - -func (x *BlockHeader) GetGasLimit() uint64 { - if x != nil { - return x.GasLimit - } - return 0 -} - -func (x *BlockHeader) GetGasUsed() uint64 { - if x != nil { - return x.GasUsed - } - return 0 -} - -func (x *BlockHeader) GetTimestamp() *timestamppb.Timestamp { - if x != nil { - return x.Timestamp - } - return nil -} - -func (x *BlockHeader) GetExtraData() []byte { - if x != nil { - return x.ExtraData - } - return nil -} - -func (x *BlockHeader) GetMixHash() []byte { - if x != nil { - return x.MixHash - } - return nil -} - -func (x *BlockHeader) GetNonce() uint64 { - if x != nil { - return x.Nonce - } - return 0 -} - -func (x *BlockHeader) GetHash() []byte { - if x != nil { - return x.Hash - } - return nil -} - -func (x *BlockHeader) GetBaseFeePerGas() *BigInt { - if x != nil { - return x.BaseFeePerGas - } - return nil -} - -func (x *BlockHeader) GetWithdrawalsRoot() []byte { - if x != nil { - return x.WithdrawalsRoot - } - return nil -} - -func (x *BlockHeader) GetTxDependency() *Uint64NestedArray { - if x != nil { - return x.TxDependency - } - return nil -} - -func (x *BlockHeader) GetBlobGasUsed() uint64 { - if x != nil && x.BlobGasUsed != nil { - return *x.BlobGasUsed - } - return 0 -} - -func (x *BlockHeader) GetExcessBlobGas() uint64 { - if x != nil && x.ExcessBlobGas != nil { - return *x.ExcessBlobGas - } - return 0 -} - -func (x *BlockHeader) GetParentBeaconRoot() []byte { - if x != nil { - return x.ParentBeaconRoot - } - return nil -} - -func (x *BlockHeader) GetRequestsHash() []byte { - if x != nil { - return x.RequestsHash - } - return nil -} - -type Uint64NestedArray struct { - state protoimpl.MessageState `protogen:"open.v1"` - Val []*Uint64Array `protobuf:"bytes,1,rep,name=val,proto3" json:"val,omitempty"` - unknownFields protoimpl.UnknownFields - sizeCache protoimpl.SizeCache -} - -func (x *Uint64NestedArray) Reset() { - *x = Uint64NestedArray{} - mi := &file_sf_ethereum_type_v2_type_proto_msgTypes[2] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) -} - -func (x *Uint64NestedArray) String() string { - return protoimpl.X.MessageStringOf(x) -} - -func (*Uint64NestedArray) ProtoMessage() {} - -func (x *Uint64NestedArray) ProtoReflect() protoreflect.Message { - mi := &file_sf_ethereum_type_v2_type_proto_msgTypes[2] - if x != nil { - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - if ms.LoadMessageInfo() == nil { - ms.StoreMessageInfo(mi) - } - return ms - } - return mi.MessageOf(x) -} - -// Deprecated: Use Uint64NestedArray.ProtoReflect.Descriptor instead. -func (*Uint64NestedArray) Descriptor() ([]byte, []int) { - return file_sf_ethereum_type_v2_type_proto_rawDescGZIP(), []int{2} -} - -func (x *Uint64NestedArray) GetVal() []*Uint64Array { - if x != nil { - return x.Val - } - return nil -} - -type Uint64Array struct { - state protoimpl.MessageState `protogen:"open.v1"` - Val []uint64 `protobuf:"varint,1,rep,packed,name=val,proto3" json:"val,omitempty"` - unknownFields protoimpl.UnknownFields - sizeCache protoimpl.SizeCache -} - -func (x *Uint64Array) Reset() { - *x = Uint64Array{} - mi := &file_sf_ethereum_type_v2_type_proto_msgTypes[3] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) -} - -func (x *Uint64Array) String() string { - return protoimpl.X.MessageStringOf(x) -} - -func (*Uint64Array) ProtoMessage() {} - -func (x *Uint64Array) ProtoReflect() protoreflect.Message { - mi := &file_sf_ethereum_type_v2_type_proto_msgTypes[3] - if x != nil { - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - if ms.LoadMessageInfo() == nil { - ms.StoreMessageInfo(mi) - } - return ms - } - return mi.MessageOf(x) -} - -// Deprecated: Use Uint64Array.ProtoReflect.Descriptor instead. -func (*Uint64Array) Descriptor() ([]byte, []int) { - return file_sf_ethereum_type_v2_type_proto_rawDescGZIP(), []int{3} -} - -func (x *Uint64Array) GetVal() []uint64 { - if x != nil { - return x.Val - } - return nil -} - -type BigInt struct { - state protoimpl.MessageState `protogen:"open.v1"` - Bytes []byte `protobuf:"bytes,1,opt,name=bytes,proto3" json:"bytes,omitempty"` - unknownFields protoimpl.UnknownFields - sizeCache protoimpl.SizeCache -} - -func (x *BigInt) Reset() { - *x = BigInt{} - mi := &file_sf_ethereum_type_v2_type_proto_msgTypes[4] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) -} - -func (x *BigInt) String() string { - return protoimpl.X.MessageStringOf(x) -} - -func (*BigInt) ProtoMessage() {} - -func (x *BigInt) ProtoReflect() protoreflect.Message { - mi := &file_sf_ethereum_type_v2_type_proto_msgTypes[4] - if x != nil { - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - if ms.LoadMessageInfo() == nil { - ms.StoreMessageInfo(mi) - } - return ms - } - return mi.MessageOf(x) -} - -// Deprecated: Use BigInt.ProtoReflect.Descriptor instead. -func (*BigInt) Descriptor() ([]byte, []int) { - return file_sf_ethereum_type_v2_type_proto_rawDescGZIP(), []int{4} -} - -func (x *BigInt) GetBytes() []byte { - if x != nil { - return x.Bytes - } - return nil -} - -// TransactionTrace is full trace of execution of the transaction when the -// it actually executed on chain. -// -// It contains all the transaction details like `from`, `to`, `gas`, etc. -// as well as all the internal calls that were made during the transaction. -// -// The `calls` vector contains Call objects which have balance changes, events -// storage changes, etc. -// -// If ordering is important between elements, almost each message like `Log`, -// `Call`, `StorageChange`, etc. have an ordinal field that is represents "execution" -// order of the said element against all other elements in this block. -// -// Due to how the call tree works doing "naively", looping through all calls then -// through a Call's element like `logs` while not yielding the elements in the order -// they were executed on chain. A log in call could have been done before or after -// another in another call depending on the actual call tree. -// -// The `calls` are ordered by creation order and the call tree can be re-computing -// using fields found in `Call` object (parent/child relationship). -// -// Another important thing to note is that even if a transaction succeed, some calls -// within it could have been reverted internally, if this is important to you, you must -// check the field `state_reverted` on the `Call` to determine if it was fully committed -// to the chain or not. -type TransactionTrace struct { - state protoimpl.MessageState `protogen:"open.v1"` - // consensus - To []byte `protobuf:"bytes,1,opt,name=to,proto3" json:"to,omitempty"` - Nonce uint64 `protobuf:"varint,2,opt,name=nonce,proto3" json:"nonce,omitempty"` - // GasPrice represents the effective price that has been paid for each gas unit of this transaction. Over time, the - // Ethereum rules changes regarding GasPrice field here. Before London fork, the GasPrice was always set to the - // fixed gas price. After London fork, this value has different meaning depending on the transaction type (see `Type` field). - // - // In cases where `TransactionTrace.Type == TRX_TYPE_LEGACY || TRX_TYPE_ACCESS_LIST`, then GasPrice has the same meaning - // as before the London fork. - // - // In cases where `TransactionTrace.Type == TRX_TYPE_DYNAMIC_FEE`, then GasPrice is the effective gas price paid - // for the transaction which is equals to `BlockHeader.BaseFeePerGas + TransactionTrace.` - GasPrice *BigInt `protobuf:"bytes,3,opt,name=gas_price,json=gasPrice,proto3" json:"gas_price,omitempty"` - // GasLimit is the maximum of gas unit the sender of the transaction is willing to consume when perform the EVM - // execution of the whole transaction - GasLimit uint64 `protobuf:"varint,4,opt,name=gas_limit,json=gasLimit,proto3" json:"gas_limit,omitempty"` - // Value is the amount of Ether transferred as part of this transaction. - Value *BigInt `protobuf:"bytes,5,opt,name=value,proto3" json:"value,omitempty"` - // Input data the transaction will receive for execution of EVM. - Input []byte `protobuf:"bytes,6,opt,name=input,proto3" json:"input,omitempty"` - // V is the recovery ID value for the signature Y point. - V []byte `protobuf:"bytes,7,opt,name=v,proto3" json:"v,omitempty"` - // R is the signature's X point on the elliptic curve (32 bytes). - R []byte `protobuf:"bytes,8,opt,name=r,proto3" json:"r,omitempty"` - // S is the signature's Y point on the elliptic curve (32 bytes). - S []byte `protobuf:"bytes,9,opt,name=s,proto3" json:"s,omitempty"` - // GasUsed is the total amount of gas unit used for the whole execution of the transaction. - GasUsed uint64 `protobuf:"varint,10,opt,name=gas_used,json=gasUsed,proto3" json:"gas_used,omitempty"` - // Type represents the Ethereum transaction type, available only since EIP-2718 & EIP-2930 activation which happened on Berlin fork. - // The value is always set even for transaction before Berlin fork because those before the fork are still legacy transactions. - Type TransactionTrace_Type `protobuf:"varint,12,opt,name=type,proto3,enum=sf.ethereum.type.v2.TransactionTrace_Type" json:"type,omitempty"` - // AcccessList represents the storage access this transaction has agreed to do in which case those storage - // access cost less gas unit per access. - // - // This will is populated only if `TransactionTrace.Type == TRX_TYPE_ACCESS_LIST || TRX_TYPE_DYNAMIC_FEE` which - // is possible only if Berlin (TRX_TYPE_ACCESS_LIST) nor London (TRX_TYPE_DYNAMIC_FEE) fork are active on the chain. - AccessList []*AccessTuple `protobuf:"bytes,14,rep,name=access_list,json=accessList,proto3" json:"access_list,omitempty"` - // MaxFeePerGas is the maximum fee per gas the user is willing to pay for the transaction gas used. - // - // This will is populated only if `TransactionTrace.Type == TRX_TYPE_DYNAMIC_FEE` which is possible only - // if Londong fork is active on the chain. - // - // Only available in DetailLevel: EXTENDED - MaxFeePerGas *BigInt `protobuf:"bytes,11,opt,name=max_fee_per_gas,json=maxFeePerGas,proto3" json:"max_fee_per_gas,omitempty"` - // MaxPriorityFeePerGas is priority fee per gas the user to pay in extra to the miner on top of the block's - // base fee. - // - // This will is populated only if `TransactionTrace.Type == TRX_TYPE_DYNAMIC_FEE` which is possible only - // if London fork is active on the chain. - // - // Only available in DetailLevel: EXTENDED - MaxPriorityFeePerGas *BigInt `protobuf:"bytes,13,opt,name=max_priority_fee_per_gas,json=maxPriorityFeePerGas,proto3" json:"max_priority_fee_per_gas,omitempty"` - // meta - Index uint32 `protobuf:"varint,20,opt,name=index,proto3" json:"index,omitempty"` - Hash []byte `protobuf:"bytes,21,opt,name=hash,proto3" json:"hash,omitempty"` - From []byte `protobuf:"bytes,22,opt,name=from,proto3" json:"from,omitempty"` - // Only available in DetailLevel: EXTENDED - ReturnData []byte `protobuf:"bytes,23,opt,name=return_data,json=returnData,proto3" json:"return_data,omitempty"` - // Only available in DetailLevel: EXTENDED - PublicKey []byte `protobuf:"bytes,24,opt,name=public_key,json=publicKey,proto3" json:"public_key,omitempty"` - // The block's global ordinal when the transaction started executing, refer to - // [Block] documentation for further information about ordinals and total ordering. - BeginOrdinal uint64 `protobuf:"varint,25,opt,name=begin_ordinal,json=beginOrdinal,proto3" json:"begin_ordinal,omitempty"` - // The block's global ordinal when the transaction finished executing, refer to - // [Block] documentation for further information about ordinals and total ordering. - EndOrdinal uint64 `protobuf:"varint,26,opt,name=end_ordinal,json=endOrdinal,proto3" json:"end_ordinal,omitempty"` - // TransactionTraceStatus is the status of the transaction execution and will let you know if the transaction - // was successful or not. - // - // ## Explanation relevant only for blocks with `DetailLevel: EXTENDED` - // - // A successful transaction has been recorded to the blockchain's state for calls in it that were successful. - // This means it's possible only a subset of the calls were properly recorded, refer to [calls[].state_reverted] field - // to determine which calls were reverted. - // - // A quirks of the Ethereum protocol is that a transaction `FAILED` or `REVERTED` still affects the blockchain's - // state for **some** of the state changes. Indeed, in those cases, the transactions fees are still paid to the miner - // which means there is a balance change for the transaction's emitter (e.g. `from`) to pay the gas fees, an optional - // balance change for gas refunded to the transaction's emitter (e.g. `from`) and a balance change for the miner who - // received the transaction fees. There is also a nonce change for the transaction's emitter (e.g. `from`). - // - // This means that to properly record the state changes for a transaction, you need to conditionally procees the - // transaction's status. - // - // For a `SUCCEEDED` transaction, you iterate over the `calls` array and record the state changes for each call for - // which `state_reverted == false` (if a transaction succeeded, the call at #0 will always `state_reverted == false` - // because it aligns with the transaction). - // - // For a `FAILED` or `REVERTED` transaction, you iterate over the root call (e.g. at #0, will always exist) for - // balance changes you process those where `reason` is either `REASON_GAS_BUY`, `REASON_GAS_REFUND` or - // `REASON_REWARD_TRANSACTION_FEE` and for nonce change, still on the root call, you pick the nonce change which the - // smallest ordinal (if more than one). - Status TransactionTraceStatus `protobuf:"varint,30,opt,name=status,proto3,enum=sf.ethereum.type.v2.TransactionTraceStatus" json:"status,omitempty"` - Receipt *TransactionReceipt `protobuf:"bytes,31,opt,name=receipt,proto3" json:"receipt,omitempty"` - // Only available in DetailLevel: EXTENDED - Calls []*Call `protobuf:"bytes,32,rep,name=calls,proto3" json:"calls,omitempty"` - // BlobGas is the amount of gas the transaction is going to pay for the blobs, this is a computed value - // equivalent to `self.blob_gas_fee_cap * len(self.blob_hashes)` and provided in the model for convenience. - // - // This is specified by https://eips.ethereum.org/EIPS/eip-4844 - // - // This will is populated only if `TransactionTrace.Type == TRX_TYPE_BLOB` which is possible only - // if Cancun fork is active on the chain. - BlobGas *uint64 `protobuf:"varint,33,opt,name=blob_gas,json=blobGas,proto3,oneof" json:"blob_gas,omitempty"` - // BlobGasFeeCap is the maximum fee per data gas the user is willing to pay for the data gas used. - // - // This is specified by https://eips.ethereum.org/EIPS/eip-4844 - // - // This will is populated only if `TransactionTrace.Type == TRX_TYPE_BLOB` which is possible only - // if Cancun fork is active on the chain. - BlobGasFeeCap *BigInt `protobuf:"bytes,34,opt,name=blob_gas_fee_cap,json=blobGasFeeCap,proto3,oneof" json:"blob_gas_fee_cap,omitempty"` - // BlobHashes field represents a list of hash outputs from 'kzg_to_versioned_hash' which - // essentially is a version byte + the sha256 hash of the blob commitment (e.g. - // `BLOB_COMMITMENT_VERSION_KZG + sha256(commitment)[1:]`. - // - // This is specified by https://eips.ethereum.org/EIPS/eip-4844 - // - // This will is populated only if `TransactionTrace.Type == TRX_TYPE_BLOB` which is possible only - // if Cancun fork is active on the chain. - BlobHashes [][]byte `protobuf:"bytes,35,rep,name=blob_hashes,json=blobHashes,proto3" json:"blob_hashes,omitempty"` - unknownFields protoimpl.UnknownFields - sizeCache protoimpl.SizeCache -} - -func (x *TransactionTrace) Reset() { - *x = TransactionTrace{} - mi := &file_sf_ethereum_type_v2_type_proto_msgTypes[5] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) -} - -func (x *TransactionTrace) String() string { - return protoimpl.X.MessageStringOf(x) -} - -func (*TransactionTrace) ProtoMessage() {} - -func (x *TransactionTrace) ProtoReflect() protoreflect.Message { - mi := &file_sf_ethereum_type_v2_type_proto_msgTypes[5] - if x != nil { - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - if ms.LoadMessageInfo() == nil { - ms.StoreMessageInfo(mi) - } - return ms - } - return mi.MessageOf(x) -} - -// Deprecated: Use TransactionTrace.ProtoReflect.Descriptor instead. -func (*TransactionTrace) Descriptor() ([]byte, []int) { - return file_sf_ethereum_type_v2_type_proto_rawDescGZIP(), []int{5} -} - -func (x *TransactionTrace) GetTo() []byte { - if x != nil { - return x.To - } - return nil -} - -func (x *TransactionTrace) GetNonce() uint64 { - if x != nil { - return x.Nonce - } - return 0 -} - -func (x *TransactionTrace) GetGasPrice() *BigInt { - if x != nil { - return x.GasPrice - } - return nil -} - -func (x *TransactionTrace) GetGasLimit() uint64 { - if x != nil { - return x.GasLimit - } - return 0 -} - -func (x *TransactionTrace) GetValue() *BigInt { - if x != nil { - return x.Value - } - return nil -} - -func (x *TransactionTrace) GetInput() []byte { - if x != nil { - return x.Input - } - return nil -} - -func (x *TransactionTrace) GetV() []byte { - if x != nil { - return x.V - } - return nil -} - -func (x *TransactionTrace) GetR() []byte { - if x != nil { - return x.R - } - return nil -} - -func (x *TransactionTrace) GetS() []byte { - if x != nil { - return x.S - } - return nil -} - -func (x *TransactionTrace) GetGasUsed() uint64 { - if x != nil { - return x.GasUsed - } - return 0 -} - -func (x *TransactionTrace) GetType() TransactionTrace_Type { - if x != nil { - return x.Type - } - return TransactionTrace_TRX_TYPE_LEGACY -} - -func (x *TransactionTrace) GetAccessList() []*AccessTuple { - if x != nil { - return x.AccessList - } - return nil -} - -func (x *TransactionTrace) GetMaxFeePerGas() *BigInt { - if x != nil { - return x.MaxFeePerGas - } - return nil -} - -func (x *TransactionTrace) GetMaxPriorityFeePerGas() *BigInt { - if x != nil { - return x.MaxPriorityFeePerGas - } - return nil -} - -func (x *TransactionTrace) GetIndex() uint32 { - if x != nil { - return x.Index - } - return 0 -} - -func (x *TransactionTrace) GetHash() []byte { - if x != nil { - return x.Hash - } - return nil -} - -func (x *TransactionTrace) GetFrom() []byte { - if x != nil { - return x.From - } - return nil -} - -func (x *TransactionTrace) GetReturnData() []byte { - if x != nil { - return x.ReturnData - } - return nil -} - -func (x *TransactionTrace) GetPublicKey() []byte { - if x != nil { - return x.PublicKey - } - return nil -} - -func (x *TransactionTrace) GetBeginOrdinal() uint64 { - if x != nil { - return x.BeginOrdinal - } - return 0 -} - -func (x *TransactionTrace) GetEndOrdinal() uint64 { - if x != nil { - return x.EndOrdinal - } - return 0 -} - -func (x *TransactionTrace) GetStatus() TransactionTraceStatus { - if x != nil { - return x.Status - } - return TransactionTraceStatus_UNKNOWN -} - -func (x *TransactionTrace) GetReceipt() *TransactionReceipt { - if x != nil { - return x.Receipt - } - return nil -} - -func (x *TransactionTrace) GetCalls() []*Call { - if x != nil { - return x.Calls - } - return nil -} - -func (x *TransactionTrace) GetBlobGas() uint64 { - if x != nil && x.BlobGas != nil { - return *x.BlobGas - } - return 0 -} - -func (x *TransactionTrace) GetBlobGasFeeCap() *BigInt { - if x != nil { - return x.BlobGasFeeCap - } - return nil -} - -func (x *TransactionTrace) GetBlobHashes() [][]byte { - if x != nil { - return x.BlobHashes - } - return nil -} - -// AccessTuple represents a list of storage keys for a given contract's address and is used -// for AccessList construction. -type AccessTuple struct { - state protoimpl.MessageState `protogen:"open.v1"` - Address []byte `protobuf:"bytes,1,opt,name=address,proto3" json:"address,omitempty"` - StorageKeys [][]byte `protobuf:"bytes,2,rep,name=storage_keys,json=storageKeys,proto3" json:"storage_keys,omitempty"` - unknownFields protoimpl.UnknownFields - sizeCache protoimpl.SizeCache -} - -func (x *AccessTuple) Reset() { - *x = AccessTuple{} - mi := &file_sf_ethereum_type_v2_type_proto_msgTypes[6] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) -} - -func (x *AccessTuple) String() string { - return protoimpl.X.MessageStringOf(x) -} - -func (*AccessTuple) ProtoMessage() {} - -func (x *AccessTuple) ProtoReflect() protoreflect.Message { - mi := &file_sf_ethereum_type_v2_type_proto_msgTypes[6] - if x != nil { - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - if ms.LoadMessageInfo() == nil { - ms.StoreMessageInfo(mi) - } - return ms - } - return mi.MessageOf(x) -} - -// Deprecated: Use AccessTuple.ProtoReflect.Descriptor instead. -func (*AccessTuple) Descriptor() ([]byte, []int) { - return file_sf_ethereum_type_v2_type_proto_rawDescGZIP(), []int{6} -} - -func (x *AccessTuple) GetAddress() []byte { - if x != nil { - return x.Address - } - return nil -} - -func (x *AccessTuple) GetStorageKeys() [][]byte { - if x != nil { - return x.StorageKeys - } - return nil -} - -type TransactionReceipt struct { - state protoimpl.MessageState `protogen:"open.v1"` - // State root is an intermediate state_root hash, computed in-between transactions to make - // **sure** you could build a proof and point to state in the middle of a block. Geth client - // uses `PostState + root + PostStateOrStatus“ while Parity used `status_code, root...“ this piles - // hardforks, see (read the EIPs first): - // - https://github.com/ethereum/EIPs/blob/master/EIPS/eip-658.md - // - // Moreover, the notion of `Outcome“ in parity, which segregates the two concepts, which are - // stored in the same field `status_code“ can be computed based on such a hack of the `state_root` - // field, following `EIP-658`. - // - // Before Byzantinium hard fork, this field is always empty. - StateRoot []byte `protobuf:"bytes,1,opt,name=state_root,json=stateRoot,proto3" json:"state_root,omitempty"` - CumulativeGasUsed uint64 `protobuf:"varint,2,opt,name=cumulative_gas_used,json=cumulativeGasUsed,proto3" json:"cumulative_gas_used,omitempty"` - LogsBloom []byte `protobuf:"bytes,3,opt,name=logs_bloom,json=logsBloom,proto3" json:"logs_bloom,omitempty"` - Logs []*Log `protobuf:"bytes,4,rep,name=logs,proto3" json:"logs,omitempty"` - // BlobGasUsed is the amount of blob gas that has been used within this transaction. At time - // of writing, this is equal to `self.blob_gas_fee_cap * len(self.blob_hashes)`. - // - // This is specified by https://eips.ethereum.org/EIPS/eip-4844 - // - // This will is populated only if `TransactionTrace.Type == TRX_TYPE_BLOB` which is possible only - // if Cancun fork is active on the chain. - BlobGasUsed *uint64 `protobuf:"varint,5,opt,name=blob_gas_used,json=blobGasUsed,proto3,oneof" json:"blob_gas_used,omitempty"` - // BlobGasPrice is the amount to pay per blob item in the transaction. - // - // This is specified by https://eips.ethereum.org/EIPS/eip-4844 - // - // This will is populated only if `TransactionTrace.Type == TRX_TYPE_BLOB` which is possible only - // if Cancun fork is active on the chain. - BlobGasPrice *BigInt `protobuf:"bytes,6,opt,name=blob_gas_price,json=blobGasPrice,proto3,oneof" json:"blob_gas_price,omitempty"` - unknownFields protoimpl.UnknownFields - sizeCache protoimpl.SizeCache -} - -func (x *TransactionReceipt) Reset() { - *x = TransactionReceipt{} - mi := &file_sf_ethereum_type_v2_type_proto_msgTypes[7] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) -} - -func (x *TransactionReceipt) String() string { - return protoimpl.X.MessageStringOf(x) -} - -func (*TransactionReceipt) ProtoMessage() {} - -func (x *TransactionReceipt) ProtoReflect() protoreflect.Message { - mi := &file_sf_ethereum_type_v2_type_proto_msgTypes[7] - if x != nil { - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - if ms.LoadMessageInfo() == nil { - ms.StoreMessageInfo(mi) - } - return ms - } - return mi.MessageOf(x) -} - -// Deprecated: Use TransactionReceipt.ProtoReflect.Descriptor instead. -func (*TransactionReceipt) Descriptor() ([]byte, []int) { - return file_sf_ethereum_type_v2_type_proto_rawDescGZIP(), []int{7} -} - -func (x *TransactionReceipt) GetStateRoot() []byte { - if x != nil { - return x.StateRoot - } - return nil -} - -func (x *TransactionReceipt) GetCumulativeGasUsed() uint64 { - if x != nil { - return x.CumulativeGasUsed - } - return 0 -} - -func (x *TransactionReceipt) GetLogsBloom() []byte { - if x != nil { - return x.LogsBloom - } - return nil -} - -func (x *TransactionReceipt) GetLogs() []*Log { - if x != nil { - return x.Logs - } - return nil -} - -func (x *TransactionReceipt) GetBlobGasUsed() uint64 { - if x != nil && x.BlobGasUsed != nil { - return *x.BlobGasUsed - } - return 0 -} - -func (x *TransactionReceipt) GetBlobGasPrice() *BigInt { - if x != nil { - return x.BlobGasPrice - } - return nil -} - -type Log struct { - state protoimpl.MessageState `protogen:"open.v1"` - Address []byte `protobuf:"bytes,1,opt,name=address,proto3" json:"address,omitempty"` - Topics [][]byte `protobuf:"bytes,2,rep,name=topics,proto3" json:"topics,omitempty"` - Data []byte `protobuf:"bytes,3,opt,name=data,proto3" json:"data,omitempty"` - // Index is the index of the log relative to the transaction. This index - // is always populated regardless of the state revertion of the the call - // that emitted this log. - // - // Only available in DetailLevel: EXTENDED - Index uint32 `protobuf:"varint,4,opt,name=index,proto3" json:"index,omitempty"` - // BlockIndex represents the index of the log relative to the Block. - // - // An **important** notice is that this field will be 0 when the call - // that emitted the log has been reverted by the chain. - // - // Currently, there is two locations where a Log can be obtained: - // - block.transaction_traces[].receipt.logs[] - // - block.transaction_traces[].calls[].logs[] - // - // In the `receipt` case, the logs will be populated only when the call - // that emitted them has not been reverted by the chain and when in this - // position, the `blockIndex` is always populated correctly. - // - // In the case of `calls` case, for `call` where `stateReverted == true`, - // the `blockIndex` value will always be 0. - BlockIndex uint32 `protobuf:"varint,6,opt,name=blockIndex,proto3" json:"blockIndex,omitempty"` - // The block's global ordinal when the log was recorded, refer to [Block] - // documentation for further information about ordinals and total ordering. - Ordinal uint64 `protobuf:"varint,7,opt,name=ordinal,proto3" json:"ordinal,omitempty"` - unknownFields protoimpl.UnknownFields - sizeCache protoimpl.SizeCache -} - -func (x *Log) Reset() { - *x = Log{} - mi := &file_sf_ethereum_type_v2_type_proto_msgTypes[8] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) -} - -func (x *Log) String() string { - return protoimpl.X.MessageStringOf(x) -} - -func (*Log) ProtoMessage() {} - -func (x *Log) ProtoReflect() protoreflect.Message { - mi := &file_sf_ethereum_type_v2_type_proto_msgTypes[8] - if x != nil { - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - if ms.LoadMessageInfo() == nil { - ms.StoreMessageInfo(mi) - } - return ms - } - return mi.MessageOf(x) -} - -// Deprecated: Use Log.ProtoReflect.Descriptor instead. -func (*Log) Descriptor() ([]byte, []int) { - return file_sf_ethereum_type_v2_type_proto_rawDescGZIP(), []int{8} -} - -func (x *Log) GetAddress() []byte { - if x != nil { - return x.Address - } - return nil -} - -func (x *Log) GetTopics() [][]byte { - if x != nil { - return x.Topics - } - return nil -} - -func (x *Log) GetData() []byte { - if x != nil { - return x.Data - } - return nil -} - -func (x *Log) GetIndex() uint32 { - if x != nil { - return x.Index - } - return 0 -} - -func (x *Log) GetBlockIndex() uint32 { - if x != nil { - return x.BlockIndex - } - return 0 -} - -func (x *Log) GetOrdinal() uint64 { - if x != nil { - return x.Ordinal - } - return 0 -} - -type Call struct { - state protoimpl.MessageState `protogen:"open.v1"` - Index uint32 `protobuf:"varint,1,opt,name=index,proto3" json:"index,omitempty"` - ParentIndex uint32 `protobuf:"varint,2,opt,name=parent_index,json=parentIndex,proto3" json:"parent_index,omitempty"` - Depth uint32 `protobuf:"varint,3,opt,name=depth,proto3" json:"depth,omitempty"` - CallType CallType `protobuf:"varint,4,opt,name=call_type,json=callType,proto3,enum=sf.ethereum.type.v2.CallType" json:"call_type,omitempty"` - Caller []byte `protobuf:"bytes,5,opt,name=caller,proto3" json:"caller,omitempty"` - Address []byte `protobuf:"bytes,6,opt,name=address,proto3" json:"address,omitempty"` - Value *BigInt `protobuf:"bytes,7,opt,name=value,proto3" json:"value,omitempty"` - GasLimit uint64 `protobuf:"varint,8,opt,name=gas_limit,json=gasLimit,proto3" json:"gas_limit,omitempty"` - GasConsumed uint64 `protobuf:"varint,9,opt,name=gas_consumed,json=gasConsumed,proto3" json:"gas_consumed,omitempty"` - ReturnData []byte `protobuf:"bytes,13,opt,name=return_data,json=returnData,proto3" json:"return_data,omitempty"` - Input []byte `protobuf:"bytes,14,opt,name=input,proto3" json:"input,omitempty"` - ExecutedCode bool `protobuf:"varint,15,opt,name=executed_code,json=executedCode,proto3" json:"executed_code,omitempty"` - Suicide bool `protobuf:"varint,16,opt,name=suicide,proto3" json:"suicide,omitempty"` - // hex representation of the hash -> preimage - KeccakPreimages map[string]string `protobuf:"bytes,20,rep,name=keccak_preimages,json=keccakPreimages,proto3" json:"keccak_preimages,omitempty" protobuf_key:"bytes,1,opt,name=key" protobuf_val:"bytes,2,opt,name=value"` - StorageChanges []*StorageChange `protobuf:"bytes,21,rep,name=storage_changes,json=storageChanges,proto3" json:"storage_changes,omitempty"` - BalanceChanges []*BalanceChange `protobuf:"bytes,22,rep,name=balance_changes,json=balanceChanges,proto3" json:"balance_changes,omitempty"` - NonceChanges []*NonceChange `protobuf:"bytes,24,rep,name=nonce_changes,json=nonceChanges,proto3" json:"nonce_changes,omitempty"` - Logs []*Log `protobuf:"bytes,25,rep,name=logs,proto3" json:"logs,omitempty"` - CodeChanges []*CodeChange `protobuf:"bytes,26,rep,name=code_changes,json=codeChanges,proto3" json:"code_changes,omitempty"` - GasChanges []*GasChange `protobuf:"bytes,28,rep,name=gas_changes,json=gasChanges,proto3" json:"gas_changes,omitempty"` - // In Ethereum, a call can be either: - // - Successfull, execution passes without any problem encountered - // - Failed, execution failed, and remaining gas should be consumed - // - Reverted, execution failed, but only gas consumed so far is billed, remaining gas is refunded - // - // When a call is either `failed` or `reverted`, the `status_failed` field - // below is set to `true`. If the status is `reverted`, then both `status_failed` - // and `status_reverted` are going to be set to `true`. - StatusFailed bool `protobuf:"varint,10,opt,name=status_failed,json=statusFailed,proto3" json:"status_failed,omitempty"` - StatusReverted bool `protobuf:"varint,12,opt,name=status_reverted,json=statusReverted,proto3" json:"status_reverted,omitempty"` - // Populated when a call either failed or reverted, so when `status_failed == true`, - // see above for details about those flags. - FailureReason string `protobuf:"bytes,11,opt,name=failure_reason,json=failureReason,proto3" json:"failure_reason,omitempty"` - // This field represents wheter or not the state changes performed - // by this call were correctly recorded by the blockchain. - // - // On Ethereum, a transaction can record state changes even if some - // of its inner nested calls failed. This is problematic however since - // a call will invalidate all its state changes as well as all state - // changes performed by its child call. This means that even if a call - // has a status of `SUCCESS`, the chain might have reverted all the state - // changes it performed. - // - // ```text - // - // Trx 1 - // Call #1 - // Call #2 - // Call #3 - // |--- Failure here - // Call #4 - // - // ``` - // - // In the transaction above, while Call #2 and Call #3 would have the - // status `EXECUTED`. - // - // If you check all calls and check only `state_reverted` flag, you might be missing - // some balance changes and nonce changes. This is because when a full transaction fails - // in ethereum (e.g. `calls.all(x.state_reverted == true)`), there is still the transaction - // fee that are recorded to the chain. - // - // Refer to [TransactionTrace#status] field for more details about the handling you must - // perform. - StateReverted bool `protobuf:"varint,30,opt,name=state_reverted,json=stateReverted,proto3" json:"state_reverted,omitempty"` - // The block's global ordinal when the call started executing, refer to - // [Block] documentation for further information about ordinals and total ordering. - BeginOrdinal uint64 `protobuf:"varint,31,opt,name=begin_ordinal,json=beginOrdinal,proto3" json:"begin_ordinal,omitempty"` - // The block's global ordinal when the call finished executing, refer to - // [Block] documentation for further information about ordinals and total ordering. - EndOrdinal uint64 `protobuf:"varint,32,opt,name=end_ordinal,json=endOrdinal,proto3" json:"end_ordinal,omitempty"` - AccountCreations []*AccountCreation `protobuf:"bytes,33,rep,name=account_creations,json=accountCreations,proto3" json:"account_creations,omitempty"` - unknownFields protoimpl.UnknownFields - sizeCache protoimpl.SizeCache -} - -func (x *Call) Reset() { - *x = Call{} - mi := &file_sf_ethereum_type_v2_type_proto_msgTypes[9] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) -} - -func (x *Call) String() string { - return protoimpl.X.MessageStringOf(x) -} - -func (*Call) ProtoMessage() {} - -func (x *Call) ProtoReflect() protoreflect.Message { - mi := &file_sf_ethereum_type_v2_type_proto_msgTypes[9] - if x != nil { - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - if ms.LoadMessageInfo() == nil { - ms.StoreMessageInfo(mi) - } - return ms - } - return mi.MessageOf(x) -} - -// Deprecated: Use Call.ProtoReflect.Descriptor instead. -func (*Call) Descriptor() ([]byte, []int) { - return file_sf_ethereum_type_v2_type_proto_rawDescGZIP(), []int{9} -} - -func (x *Call) GetIndex() uint32 { - if x != nil { - return x.Index - } - return 0 -} - -func (x *Call) GetParentIndex() uint32 { - if x != nil { - return x.ParentIndex - } - return 0 -} - -func (x *Call) GetDepth() uint32 { - if x != nil { - return x.Depth - } - return 0 -} - -func (x *Call) GetCallType() CallType { - if x != nil { - return x.CallType - } - return CallType_UNSPECIFIED -} - -func (x *Call) GetCaller() []byte { - if x != nil { - return x.Caller - } - return nil -} - -func (x *Call) GetAddress() []byte { - if x != nil { - return x.Address - } - return nil -} - -func (x *Call) GetValue() *BigInt { - if x != nil { - return x.Value - } - return nil -} - -func (x *Call) GetGasLimit() uint64 { - if x != nil { - return x.GasLimit - } - return 0 -} - -func (x *Call) GetGasConsumed() uint64 { - if x != nil { - return x.GasConsumed - } - return 0 -} - -func (x *Call) GetReturnData() []byte { - if x != nil { - return x.ReturnData - } - return nil -} - -func (x *Call) GetInput() []byte { - if x != nil { - return x.Input - } - return nil -} - -func (x *Call) GetExecutedCode() bool { - if x != nil { - return x.ExecutedCode - } - return false -} - -func (x *Call) GetSuicide() bool { - if x != nil { - return x.Suicide - } - return false -} - -func (x *Call) GetKeccakPreimages() map[string]string { - if x != nil { - return x.KeccakPreimages - } - return nil -} - -func (x *Call) GetStorageChanges() []*StorageChange { - if x != nil { - return x.StorageChanges - } - return nil -} - -func (x *Call) GetBalanceChanges() []*BalanceChange { - if x != nil { - return x.BalanceChanges - } - return nil -} - -func (x *Call) GetNonceChanges() []*NonceChange { - if x != nil { - return x.NonceChanges - } - return nil -} - -func (x *Call) GetLogs() []*Log { - if x != nil { - return x.Logs - } - return nil -} - -func (x *Call) GetCodeChanges() []*CodeChange { - if x != nil { - return x.CodeChanges - } - return nil -} - -func (x *Call) GetGasChanges() []*GasChange { - if x != nil { - return x.GasChanges - } - return nil -} - -func (x *Call) GetStatusFailed() bool { - if x != nil { - return x.StatusFailed - } - return false -} - -func (x *Call) GetStatusReverted() bool { - if x != nil { - return x.StatusReverted - } - return false -} - -func (x *Call) GetFailureReason() string { - if x != nil { - return x.FailureReason - } - return "" -} - -func (x *Call) GetStateReverted() bool { - if x != nil { - return x.StateReverted - } - return false -} - -func (x *Call) GetBeginOrdinal() uint64 { - if x != nil { - return x.BeginOrdinal - } - return 0 -} - -func (x *Call) GetEndOrdinal() uint64 { - if x != nil { - return x.EndOrdinal - } - return 0 -} - -func (x *Call) GetAccountCreations() []*AccountCreation { - if x != nil { - return x.AccountCreations - } - return nil -} - -type StorageChange struct { - state protoimpl.MessageState `protogen:"open.v1"` - Address []byte `protobuf:"bytes,1,opt,name=address,proto3" json:"address,omitempty"` - Key []byte `protobuf:"bytes,2,opt,name=key,proto3" json:"key,omitempty"` - OldValue []byte `protobuf:"bytes,3,opt,name=old_value,json=oldValue,proto3" json:"old_value,omitempty"` - NewValue []byte `protobuf:"bytes,4,opt,name=new_value,json=newValue,proto3" json:"new_value,omitempty"` - // The block's global ordinal when the storage change was recorded, refer to [Block] - // documentation for further information about ordinals and total ordering. - Ordinal uint64 `protobuf:"varint,5,opt,name=ordinal,proto3" json:"ordinal,omitempty"` - unknownFields protoimpl.UnknownFields - sizeCache protoimpl.SizeCache -} - -func (x *StorageChange) Reset() { - *x = StorageChange{} - mi := &file_sf_ethereum_type_v2_type_proto_msgTypes[10] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) -} - -func (x *StorageChange) String() string { - return protoimpl.X.MessageStringOf(x) -} - -func (*StorageChange) ProtoMessage() {} - -func (x *StorageChange) ProtoReflect() protoreflect.Message { - mi := &file_sf_ethereum_type_v2_type_proto_msgTypes[10] - if x != nil { - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - if ms.LoadMessageInfo() == nil { - ms.StoreMessageInfo(mi) - } - return ms - } - return mi.MessageOf(x) -} - -// Deprecated: Use StorageChange.ProtoReflect.Descriptor instead. -func (*StorageChange) Descriptor() ([]byte, []int) { - return file_sf_ethereum_type_v2_type_proto_rawDescGZIP(), []int{10} -} - -func (x *StorageChange) GetAddress() []byte { - if x != nil { - return x.Address - } - return nil -} - -func (x *StorageChange) GetKey() []byte { - if x != nil { - return x.Key - } - return nil -} - -func (x *StorageChange) GetOldValue() []byte { - if x != nil { - return x.OldValue - } - return nil -} - -func (x *StorageChange) GetNewValue() []byte { - if x != nil { - return x.NewValue - } - return nil -} - -func (x *StorageChange) GetOrdinal() uint64 { - if x != nil { - return x.Ordinal - } - return 0 -} - -type BalanceChange struct { - state protoimpl.MessageState `protogen:"open.v1"` - // Address is the address of the account that has changed balance. - Address []byte `protobuf:"bytes,1,opt,name=address,proto3" json:"address,omitempty"` - // OldValue is the balance of the address before the change. This value - // can be **nil/null/None** if there was no previous balance for the address. - // It is safe in those case(s) to consider the balance as being 0. - // - // If you consume this from a Substreams, you can safely use: - // - // ```ignore - // - // let old_value = old_value.unwrap_or_default(); - // - // ``` - OldValue *BigInt `protobuf:"bytes,2,opt,name=old_value,json=oldValue,proto3" json:"old_value,omitempty"` - // NewValue is the balance of the address after the change. This value - // can be **nil/null/None** if there was no previous balance for the address - // after the change. It is safe in those case(s) to consider the balance as being - // 0. - // - // If you consume this from a Substreams, you can safely use: - // - // ```ignore - // - // let new_value = new_value.unwrap_or_default(); - // - // ``` - NewValue *BigInt `protobuf:"bytes,3,opt,name=new_value,json=newValue,proto3" json:"new_value,omitempty"` - // Reason is the reason why the balance has changed. This is useful to determine - // why the balance has changed and what is the context of the change. - Reason BalanceChange_Reason `protobuf:"varint,4,opt,name=reason,proto3,enum=sf.ethereum.type.v2.BalanceChange_Reason" json:"reason,omitempty"` - // The block's global ordinal when the balance change was recorded, refer to [Block] - // documentation for further information about ordinals and total ordering. - Ordinal uint64 `protobuf:"varint,5,opt,name=ordinal,proto3" json:"ordinal,omitempty"` - unknownFields protoimpl.UnknownFields - sizeCache protoimpl.SizeCache -} - -func (x *BalanceChange) Reset() { - *x = BalanceChange{} - mi := &file_sf_ethereum_type_v2_type_proto_msgTypes[11] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) -} - -func (x *BalanceChange) String() string { - return protoimpl.X.MessageStringOf(x) -} - -func (*BalanceChange) ProtoMessage() {} - -func (x *BalanceChange) ProtoReflect() protoreflect.Message { - mi := &file_sf_ethereum_type_v2_type_proto_msgTypes[11] - if x != nil { - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - if ms.LoadMessageInfo() == nil { - ms.StoreMessageInfo(mi) - } - return ms - } - return mi.MessageOf(x) -} - -// Deprecated: Use BalanceChange.ProtoReflect.Descriptor instead. -func (*BalanceChange) Descriptor() ([]byte, []int) { - return file_sf_ethereum_type_v2_type_proto_rawDescGZIP(), []int{11} -} - -func (x *BalanceChange) GetAddress() []byte { - if x != nil { - return x.Address - } - return nil -} - -func (x *BalanceChange) GetOldValue() *BigInt { - if x != nil { - return x.OldValue - } - return nil -} - -func (x *BalanceChange) GetNewValue() *BigInt { - if x != nil { - return x.NewValue - } - return nil -} - -func (x *BalanceChange) GetReason() BalanceChange_Reason { - if x != nil { - return x.Reason - } - return BalanceChange_REASON_UNKNOWN -} - -func (x *BalanceChange) GetOrdinal() uint64 { - if x != nil { - return x.Ordinal - } - return 0 -} - -type NonceChange struct { - state protoimpl.MessageState `protogen:"open.v1"` - Address []byte `protobuf:"bytes,1,opt,name=address,proto3" json:"address,omitempty"` - OldValue uint64 `protobuf:"varint,2,opt,name=old_value,json=oldValue,proto3" json:"old_value,omitempty"` - NewValue uint64 `protobuf:"varint,3,opt,name=new_value,json=newValue,proto3" json:"new_value,omitempty"` - // The block's global ordinal when the nonce change was recorded, refer to [Block] - // documentation for further information about ordinals and total ordering. - Ordinal uint64 `protobuf:"varint,4,opt,name=ordinal,proto3" json:"ordinal,omitempty"` - unknownFields protoimpl.UnknownFields - sizeCache protoimpl.SizeCache -} - -func (x *NonceChange) Reset() { - *x = NonceChange{} - mi := &file_sf_ethereum_type_v2_type_proto_msgTypes[12] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) -} - -func (x *NonceChange) String() string { - return protoimpl.X.MessageStringOf(x) -} - -func (*NonceChange) ProtoMessage() {} - -func (x *NonceChange) ProtoReflect() protoreflect.Message { - mi := &file_sf_ethereum_type_v2_type_proto_msgTypes[12] - if x != nil { - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - if ms.LoadMessageInfo() == nil { - ms.StoreMessageInfo(mi) - } - return ms - } - return mi.MessageOf(x) -} - -// Deprecated: Use NonceChange.ProtoReflect.Descriptor instead. -func (*NonceChange) Descriptor() ([]byte, []int) { - return file_sf_ethereum_type_v2_type_proto_rawDescGZIP(), []int{12} -} - -func (x *NonceChange) GetAddress() []byte { - if x != nil { - return x.Address - } - return nil -} - -func (x *NonceChange) GetOldValue() uint64 { - if x != nil { - return x.OldValue - } - return 0 -} - -func (x *NonceChange) GetNewValue() uint64 { - if x != nil { - return x.NewValue - } - return 0 -} - -func (x *NonceChange) GetOrdinal() uint64 { - if x != nil { - return x.Ordinal - } - return 0 -} - -type AccountCreation struct { - state protoimpl.MessageState `protogen:"open.v1"` - Account []byte `protobuf:"bytes,1,opt,name=account,proto3" json:"account,omitempty"` - // The block's global ordinal when the account creation was recorded, refer to [Block] - // documentation for further information about ordinals and total ordering. - Ordinal uint64 `protobuf:"varint,2,opt,name=ordinal,proto3" json:"ordinal,omitempty"` - unknownFields protoimpl.UnknownFields - sizeCache protoimpl.SizeCache -} - -func (x *AccountCreation) Reset() { - *x = AccountCreation{} - mi := &file_sf_ethereum_type_v2_type_proto_msgTypes[13] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) -} - -func (x *AccountCreation) String() string { - return protoimpl.X.MessageStringOf(x) -} - -func (*AccountCreation) ProtoMessage() {} - -func (x *AccountCreation) ProtoReflect() protoreflect.Message { - mi := &file_sf_ethereum_type_v2_type_proto_msgTypes[13] - if x != nil { - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - if ms.LoadMessageInfo() == nil { - ms.StoreMessageInfo(mi) - } - return ms - } - return mi.MessageOf(x) -} - -// Deprecated: Use AccountCreation.ProtoReflect.Descriptor instead. -func (*AccountCreation) Descriptor() ([]byte, []int) { - return file_sf_ethereum_type_v2_type_proto_rawDescGZIP(), []int{13} -} - -func (x *AccountCreation) GetAccount() []byte { - if x != nil { - return x.Account - } - return nil -} - -func (x *AccountCreation) GetOrdinal() uint64 { - if x != nil { - return x.Ordinal - } - return 0 -} - -type CodeChange struct { - state protoimpl.MessageState `protogen:"open.v1"` - Address []byte `protobuf:"bytes,1,opt,name=address,proto3" json:"address,omitempty"` - OldHash []byte `protobuf:"bytes,2,opt,name=old_hash,json=oldHash,proto3" json:"old_hash,omitempty"` - OldCode []byte `protobuf:"bytes,3,opt,name=old_code,json=oldCode,proto3" json:"old_code,omitempty"` - NewHash []byte `protobuf:"bytes,4,opt,name=new_hash,json=newHash,proto3" json:"new_hash,omitempty"` - NewCode []byte `protobuf:"bytes,5,opt,name=new_code,json=newCode,proto3" json:"new_code,omitempty"` - // The block's global ordinal when the code change was recorded, refer to [Block] - // documentation for further information about ordinals and total ordering. - Ordinal uint64 `protobuf:"varint,6,opt,name=ordinal,proto3" json:"ordinal,omitempty"` - unknownFields protoimpl.UnknownFields - sizeCache protoimpl.SizeCache -} - -func (x *CodeChange) Reset() { - *x = CodeChange{} - mi := &file_sf_ethereum_type_v2_type_proto_msgTypes[14] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) -} - -func (x *CodeChange) String() string { - return protoimpl.X.MessageStringOf(x) -} - -func (*CodeChange) ProtoMessage() {} - -func (x *CodeChange) ProtoReflect() protoreflect.Message { - mi := &file_sf_ethereum_type_v2_type_proto_msgTypes[14] - if x != nil { - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - if ms.LoadMessageInfo() == nil { - ms.StoreMessageInfo(mi) - } - return ms - } - return mi.MessageOf(x) -} - -// Deprecated: Use CodeChange.ProtoReflect.Descriptor instead. -func (*CodeChange) Descriptor() ([]byte, []int) { - return file_sf_ethereum_type_v2_type_proto_rawDescGZIP(), []int{14} -} - -func (x *CodeChange) GetAddress() []byte { - if x != nil { - return x.Address - } - return nil -} - -func (x *CodeChange) GetOldHash() []byte { - if x != nil { - return x.OldHash - } - return nil -} - -func (x *CodeChange) GetOldCode() []byte { - if x != nil { - return x.OldCode - } - return nil -} - -func (x *CodeChange) GetNewHash() []byte { - if x != nil { - return x.NewHash - } - return nil -} - -func (x *CodeChange) GetNewCode() []byte { - if x != nil { - return x.NewCode - } - return nil -} - -func (x *CodeChange) GetOrdinal() uint64 { - if x != nil { - return x.Ordinal - } - return 0 -} - -// The gas change model represents the reason why some gas cost has occurred. -// The gas is computed per actual op codes. Doing them completely might prove -// overwhelming in most cases. -// -// Hence, we only index some of them, those that are costy like all the calls -// one, log events, return data, etc. -type GasChange struct { - state protoimpl.MessageState `protogen:"open.v1"` - OldValue uint64 `protobuf:"varint,1,opt,name=old_value,json=oldValue,proto3" json:"old_value,omitempty"` - NewValue uint64 `protobuf:"varint,2,opt,name=new_value,json=newValue,proto3" json:"new_value,omitempty"` - Reason GasChange_Reason `protobuf:"varint,3,opt,name=reason,proto3,enum=sf.ethereum.type.v2.GasChange_Reason" json:"reason,omitempty"` - // The block's global ordinal when the gas change was recorded, refer to [Block] - // documentation for further information about ordinals and total ordering. - Ordinal uint64 `protobuf:"varint,4,opt,name=ordinal,proto3" json:"ordinal,omitempty"` - unknownFields protoimpl.UnknownFields - sizeCache protoimpl.SizeCache -} - -func (x *GasChange) Reset() { - *x = GasChange{} - mi := &file_sf_ethereum_type_v2_type_proto_msgTypes[15] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) -} - -func (x *GasChange) String() string { - return protoimpl.X.MessageStringOf(x) -} - -func (*GasChange) ProtoMessage() {} - -func (x *GasChange) ProtoReflect() protoreflect.Message { - mi := &file_sf_ethereum_type_v2_type_proto_msgTypes[15] - if x != nil { - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - if ms.LoadMessageInfo() == nil { - ms.StoreMessageInfo(mi) - } - return ms - } - return mi.MessageOf(x) -} - -// Deprecated: Use GasChange.ProtoReflect.Descriptor instead. -func (*GasChange) Descriptor() ([]byte, []int) { - return file_sf_ethereum_type_v2_type_proto_rawDescGZIP(), []int{15} -} - -func (x *GasChange) GetOldValue() uint64 { - if x != nil { - return x.OldValue - } - return 0 -} - -func (x *GasChange) GetNewValue() uint64 { - if x != nil { - return x.NewValue - } - return 0 -} - -func (x *GasChange) GetReason() GasChange_Reason { - if x != nil { - return x.Reason - } - return GasChange_REASON_UNKNOWN -} - -func (x *GasChange) GetOrdinal() uint64 { - if x != nil { - return x.Ordinal - } - return 0 -} - -// HeaderOnlyBlock is used to optimally unpack the [Block] structure (note the -// corresponding message number for the `header` field) while consuming less -// memory, when only the `header` is desired. -// -// WARN: this is a client-side optimization pattern and should be moved in the -// consuming code. -type HeaderOnlyBlock struct { - state protoimpl.MessageState `protogen:"open.v1"` - Header *BlockHeader `protobuf:"bytes,5,opt,name=header,proto3" json:"header,omitempty"` - unknownFields protoimpl.UnknownFields - sizeCache protoimpl.SizeCache -} - -func (x *HeaderOnlyBlock) Reset() { - *x = HeaderOnlyBlock{} - mi := &file_sf_ethereum_type_v2_type_proto_msgTypes[16] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) -} - -func (x *HeaderOnlyBlock) String() string { - return protoimpl.X.MessageStringOf(x) -} - -func (*HeaderOnlyBlock) ProtoMessage() {} - -func (x *HeaderOnlyBlock) ProtoReflect() protoreflect.Message { - mi := &file_sf_ethereum_type_v2_type_proto_msgTypes[16] - if x != nil { - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - if ms.LoadMessageInfo() == nil { - ms.StoreMessageInfo(mi) - } - return ms - } - return mi.MessageOf(x) -} - -// Deprecated: Use HeaderOnlyBlock.ProtoReflect.Descriptor instead. -func (*HeaderOnlyBlock) Descriptor() ([]byte, []int) { - return file_sf_ethereum_type_v2_type_proto_rawDescGZIP(), []int{16} -} - -func (x *HeaderOnlyBlock) GetHeader() *BlockHeader { - if x != nil { - return x.Header - } - return nil -} - -// BlockWithRefs is a lightweight block, with traces and transactions -// purged from the `block` within, and only. It is used in transports -// to pass block data around. -type BlockWithRefs struct { - state protoimpl.MessageState `protogen:"open.v1"` - Id string `protobuf:"bytes,1,opt,name=id,proto3" json:"id,omitempty"` - Block *Block `protobuf:"bytes,2,opt,name=block,proto3" json:"block,omitempty"` - TransactionTraceRefs *TransactionRefs `protobuf:"bytes,3,opt,name=transaction_trace_refs,json=transactionTraceRefs,proto3" json:"transaction_trace_refs,omitempty"` - Irreversible bool `protobuf:"varint,4,opt,name=irreversible,proto3" json:"irreversible,omitempty"` - unknownFields protoimpl.UnknownFields - sizeCache protoimpl.SizeCache -} - -func (x *BlockWithRefs) Reset() { - *x = BlockWithRefs{} - mi := &file_sf_ethereum_type_v2_type_proto_msgTypes[17] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) -} - -func (x *BlockWithRefs) String() string { - return protoimpl.X.MessageStringOf(x) -} - -func (*BlockWithRefs) ProtoMessage() {} - -func (x *BlockWithRefs) ProtoReflect() protoreflect.Message { - mi := &file_sf_ethereum_type_v2_type_proto_msgTypes[17] - if x != nil { - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - if ms.LoadMessageInfo() == nil { - ms.StoreMessageInfo(mi) - } - return ms - } - return mi.MessageOf(x) -} - -// Deprecated: Use BlockWithRefs.ProtoReflect.Descriptor instead. -func (*BlockWithRefs) Descriptor() ([]byte, []int) { - return file_sf_ethereum_type_v2_type_proto_rawDescGZIP(), []int{17} -} - -func (x *BlockWithRefs) GetId() string { - if x != nil { - return x.Id - } - return "" -} - -func (x *BlockWithRefs) GetBlock() *Block { - if x != nil { - return x.Block - } - return nil -} - -func (x *BlockWithRefs) GetTransactionTraceRefs() *TransactionRefs { - if x != nil { - return x.TransactionTraceRefs - } - return nil -} - -func (x *BlockWithRefs) GetIrreversible() bool { - if x != nil { - return x.Irreversible - } - return false -} - -type TransactionTraceWithBlockRef struct { - state protoimpl.MessageState `protogen:"open.v1"` - Trace *TransactionTrace `protobuf:"bytes,1,opt,name=trace,proto3" json:"trace,omitempty"` - BlockRef *BlockRef `protobuf:"bytes,2,opt,name=block_ref,json=blockRef,proto3" json:"block_ref,omitempty"` - unknownFields protoimpl.UnknownFields - sizeCache protoimpl.SizeCache -} - -func (x *TransactionTraceWithBlockRef) Reset() { - *x = TransactionTraceWithBlockRef{} - mi := &file_sf_ethereum_type_v2_type_proto_msgTypes[18] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) -} - -func (x *TransactionTraceWithBlockRef) String() string { - return protoimpl.X.MessageStringOf(x) -} - -func (*TransactionTraceWithBlockRef) ProtoMessage() {} - -func (x *TransactionTraceWithBlockRef) ProtoReflect() protoreflect.Message { - mi := &file_sf_ethereum_type_v2_type_proto_msgTypes[18] - if x != nil { - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - if ms.LoadMessageInfo() == nil { - ms.StoreMessageInfo(mi) - } - return ms - } - return mi.MessageOf(x) -} - -// Deprecated: Use TransactionTraceWithBlockRef.ProtoReflect.Descriptor instead. -func (*TransactionTraceWithBlockRef) Descriptor() ([]byte, []int) { - return file_sf_ethereum_type_v2_type_proto_rawDescGZIP(), []int{18} -} - -func (x *TransactionTraceWithBlockRef) GetTrace() *TransactionTrace { - if x != nil { - return x.Trace - } - return nil -} - -func (x *TransactionTraceWithBlockRef) GetBlockRef() *BlockRef { - if x != nil { - return x.BlockRef - } - return nil -} - -type TransactionRefs struct { - state protoimpl.MessageState `protogen:"open.v1"` - Hashes [][]byte `protobuf:"bytes,1,rep,name=hashes,proto3" json:"hashes,omitempty"` - unknownFields protoimpl.UnknownFields - sizeCache protoimpl.SizeCache -} - -func (x *TransactionRefs) Reset() { - *x = TransactionRefs{} - mi := &file_sf_ethereum_type_v2_type_proto_msgTypes[19] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) -} - -func (x *TransactionRefs) String() string { - return protoimpl.X.MessageStringOf(x) -} - -func (*TransactionRefs) ProtoMessage() {} - -func (x *TransactionRefs) ProtoReflect() protoreflect.Message { - mi := &file_sf_ethereum_type_v2_type_proto_msgTypes[19] - if x != nil { - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - if ms.LoadMessageInfo() == nil { - ms.StoreMessageInfo(mi) - } - return ms - } - return mi.MessageOf(x) -} - -// Deprecated: Use TransactionRefs.ProtoReflect.Descriptor instead. -func (*TransactionRefs) Descriptor() ([]byte, []int) { - return file_sf_ethereum_type_v2_type_proto_rawDescGZIP(), []int{19} -} - -func (x *TransactionRefs) GetHashes() [][]byte { - if x != nil { - return x.Hashes - } - return nil -} - -type BlockRef struct { - state protoimpl.MessageState `protogen:"open.v1"` - Hash []byte `protobuf:"bytes,1,opt,name=hash,proto3" json:"hash,omitempty"` - Number uint64 `protobuf:"varint,2,opt,name=number,proto3" json:"number,omitempty"` - unknownFields protoimpl.UnknownFields - sizeCache protoimpl.SizeCache -} - -func (x *BlockRef) Reset() { - *x = BlockRef{} - mi := &file_sf_ethereum_type_v2_type_proto_msgTypes[20] - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - ms.StoreMessageInfo(mi) -} - -func (x *BlockRef) String() string { - return protoimpl.X.MessageStringOf(x) -} - -func (*BlockRef) ProtoMessage() {} - -func (x *BlockRef) ProtoReflect() protoreflect.Message { - mi := &file_sf_ethereum_type_v2_type_proto_msgTypes[20] - if x != nil { - ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) - if ms.LoadMessageInfo() == nil { - ms.StoreMessageInfo(mi) - } - return ms - } - return mi.MessageOf(x) -} - -// Deprecated: Use BlockRef.ProtoReflect.Descriptor instead. -func (*BlockRef) Descriptor() ([]byte, []int) { - return file_sf_ethereum_type_v2_type_proto_rawDescGZIP(), []int{20} -} - -func (x *BlockRef) GetHash() []byte { - if x != nil { - return x.Hash - } - return nil -} - -func (x *BlockRef) GetNumber() uint64 { - if x != nil { - return x.Number - } - return 0 -} - -var File_sf_ethereum_type_v2_type_proto protoreflect.FileDescriptor - -var file_sf_ethereum_type_v2_type_proto_rawDesc = string([]byte{ - 0x0a, 0x1e, 0x73, 0x66, 0x2f, 0x65, 0x74, 0x68, 0x65, 0x72, 0x65, 0x75, 0x6d, 0x2f, 0x74, 0x79, - 0x70, 0x65, 0x2f, 0x76, 0x32, 0x2f, 0x74, 0x79, 0x70, 0x65, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, - 0x12, 0x13, 0x73, 0x66, 0x2e, 0x65, 0x74, 0x68, 0x65, 0x72, 0x65, 0x75, 0x6d, 0x2e, 0x74, 0x79, - 0x70, 0x65, 0x2e, 0x76, 0x32, 0x1a, 0x1f, 0x67, 0x6f, 0x6f, 0x67, 0x6c, 0x65, 0x2f, 0x70, 0x72, - 0x6f, 0x74, 0x6f, 0x62, 0x75, 0x66, 0x2f, 0x74, 0x69, 0x6d, 0x65, 0x73, 0x74, 0x61, 0x6d, 0x70, - 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x22, 0x8e, 0x05, 0x0a, 0x05, 0x42, 0x6c, 0x6f, 0x63, 0x6b, - 0x12, 0x12, 0x0a, 0x04, 0x68, 0x61, 0x73, 0x68, 0x18, 0x02, 0x20, 0x01, 0x28, 0x0c, 0x52, 0x04, - 0x68, 0x61, 0x73, 0x68, 0x12, 0x16, 0x0a, 0x06, 0x6e, 0x75, 0x6d, 0x62, 0x65, 0x72, 0x18, 0x03, - 0x20, 0x01, 0x28, 0x04, 0x52, 0x06, 0x6e, 0x75, 0x6d, 0x62, 0x65, 0x72, 0x12, 0x12, 0x0a, 0x04, - 0x73, 0x69, 0x7a, 0x65, 0x18, 0x04, 0x20, 0x01, 0x28, 0x04, 0x52, 0x04, 0x73, 0x69, 0x7a, 0x65, - 0x12, 0x38, 0x0a, 0x06, 0x68, 0x65, 0x61, 0x64, 0x65, 0x72, 0x18, 0x05, 0x20, 0x01, 0x28, 0x0b, - 0x32, 0x20, 0x2e, 0x73, 0x66, 0x2e, 0x65, 0x74, 0x68, 0x65, 0x72, 0x65, 0x75, 0x6d, 0x2e, 0x74, - 0x79, 0x70, 0x65, 0x2e, 0x76, 0x32, 0x2e, 0x42, 0x6c, 0x6f, 0x63, 0x6b, 0x48, 0x65, 0x61, 0x64, - 0x65, 0x72, 0x52, 0x06, 0x68, 0x65, 0x61, 0x64, 0x65, 0x72, 0x12, 0x38, 0x0a, 0x06, 0x75, 0x6e, - 0x63, 0x6c, 0x65, 0x73, 0x18, 0x06, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x20, 0x2e, 0x73, 0x66, 0x2e, - 0x65, 0x74, 0x68, 0x65, 0x72, 0x65, 0x75, 0x6d, 0x2e, 0x74, 0x79, 0x70, 0x65, 0x2e, 0x76, 0x32, - 0x2e, 0x42, 0x6c, 0x6f, 0x63, 0x6b, 0x48, 0x65, 0x61, 0x64, 0x65, 0x72, 0x52, 0x06, 0x75, 0x6e, - 0x63, 0x6c, 0x65, 0x73, 0x12, 0x54, 0x0a, 0x12, 0x74, 0x72, 0x61, 0x6e, 0x73, 0x61, 0x63, 0x74, - 0x69, 0x6f, 0x6e, 0x5f, 0x74, 0x72, 0x61, 0x63, 0x65, 0x73, 0x18, 0x0a, 0x20, 0x03, 0x28, 0x0b, - 0x32, 0x25, 0x2e, 0x73, 0x66, 0x2e, 0x65, 0x74, 0x68, 0x65, 0x72, 0x65, 0x75, 0x6d, 0x2e, 0x74, - 0x79, 0x70, 0x65, 0x2e, 0x76, 0x32, 0x2e, 0x54, 0x72, 0x61, 0x6e, 0x73, 0x61, 0x63, 0x74, 0x69, - 0x6f, 0x6e, 0x54, 0x72, 0x61, 0x63, 0x65, 0x52, 0x11, 0x74, 0x72, 0x61, 0x6e, 0x73, 0x61, 0x63, - 0x74, 0x69, 0x6f, 0x6e, 0x54, 0x72, 0x61, 0x63, 0x65, 0x73, 0x12, 0x4b, 0x0a, 0x0f, 0x62, 0x61, - 0x6c, 0x61, 0x6e, 0x63, 0x65, 0x5f, 0x63, 0x68, 0x61, 0x6e, 0x67, 0x65, 0x73, 0x18, 0x0b, 0x20, - 0x03, 0x28, 0x0b, 0x32, 0x22, 0x2e, 0x73, 0x66, 0x2e, 0x65, 0x74, 0x68, 0x65, 0x72, 0x65, 0x75, - 0x6d, 0x2e, 0x74, 0x79, 0x70, 0x65, 0x2e, 0x76, 0x32, 0x2e, 0x42, 0x61, 0x6c, 0x61, 0x6e, 0x63, - 0x65, 0x43, 0x68, 0x61, 0x6e, 0x67, 0x65, 0x52, 0x0e, 0x62, 0x61, 0x6c, 0x61, 0x6e, 0x63, 0x65, - 0x43, 0x68, 0x61, 0x6e, 0x67, 0x65, 0x73, 0x12, 0x49, 0x0a, 0x0c, 0x64, 0x65, 0x74, 0x61, 0x69, - 0x6c, 0x5f, 0x6c, 0x65, 0x76, 0x65, 0x6c, 0x18, 0x0c, 0x20, 0x01, 0x28, 0x0e, 0x32, 0x26, 0x2e, - 0x73, 0x66, 0x2e, 0x65, 0x74, 0x68, 0x65, 0x72, 0x65, 0x75, 0x6d, 0x2e, 0x74, 0x79, 0x70, 0x65, - 0x2e, 0x76, 0x32, 0x2e, 0x42, 0x6c, 0x6f, 0x63, 0x6b, 0x2e, 0x44, 0x65, 0x74, 0x61, 0x69, 0x6c, - 0x4c, 0x65, 0x76, 0x65, 0x6c, 0x52, 0x0b, 0x64, 0x65, 0x74, 0x61, 0x69, 0x6c, 0x4c, 0x65, 0x76, - 0x65, 0x6c, 0x12, 0x42, 0x0a, 0x0c, 0x63, 0x6f, 0x64, 0x65, 0x5f, 0x63, 0x68, 0x61, 0x6e, 0x67, - 0x65, 0x73, 0x18, 0x14, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x1f, 0x2e, 0x73, 0x66, 0x2e, 0x65, 0x74, - 0x68, 0x65, 0x72, 0x65, 0x75, 0x6d, 0x2e, 0x74, 0x79, 0x70, 0x65, 0x2e, 0x76, 0x32, 0x2e, 0x43, - 0x6f, 0x64, 0x65, 0x43, 0x68, 0x61, 0x6e, 0x67, 0x65, 0x52, 0x0b, 0x63, 0x6f, 0x64, 0x65, 0x43, - 0x68, 0x61, 0x6e, 0x67, 0x65, 0x73, 0x12, 0x3c, 0x0a, 0x0c, 0x73, 0x79, 0x73, 0x74, 0x65, 0x6d, - 0x5f, 0x63, 0x61, 0x6c, 0x6c, 0x73, 0x18, 0x15, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x19, 0x2e, 0x73, - 0x66, 0x2e, 0x65, 0x74, 0x68, 0x65, 0x72, 0x65, 0x75, 0x6d, 0x2e, 0x74, 0x79, 0x70, 0x65, 0x2e, - 0x76, 0x32, 0x2e, 0x43, 0x61, 0x6c, 0x6c, 0x52, 0x0b, 0x73, 0x79, 0x73, 0x74, 0x65, 0x6d, 0x43, - 0x61, 0x6c, 0x6c, 0x73, 0x12, 0x10, 0x0a, 0x03, 0x76, 0x65, 0x72, 0x18, 0x01, 0x20, 0x01, 0x28, - 0x05, 0x52, 0x03, 0x76, 0x65, 0x72, 0x22, 0x3d, 0x0a, 0x0b, 0x44, 0x65, 0x74, 0x61, 0x69, 0x6c, - 0x4c, 0x65, 0x76, 0x65, 0x6c, 0x12, 0x18, 0x0a, 0x14, 0x44, 0x45, 0x54, 0x41, 0x49, 0x4c, 0x4c, - 0x45, 0x56, 0x45, 0x4c, 0x5f, 0x45, 0x58, 0x54, 0x45, 0x4e, 0x44, 0x45, 0x44, 0x10, 0x00, 0x12, - 0x14, 0x0a, 0x10, 0x44, 0x45, 0x54, 0x41, 0x49, 0x4c, 0x4c, 0x45, 0x56, 0x45, 0x4c, 0x5f, 0x42, - 0x41, 0x53, 0x45, 0x10, 0x02, 0x4a, 0x04, 0x08, 0x28, 0x10, 0x29, 0x4a, 0x04, 0x08, 0x29, 0x10, - 0x2a, 0x4a, 0x04, 0x08, 0x2a, 0x10, 0x2b, 0x22, 0xfb, 0x07, 0x0a, 0x0b, 0x42, 0x6c, 0x6f, 0x63, - 0x6b, 0x48, 0x65, 0x61, 0x64, 0x65, 0x72, 0x12, 0x1f, 0x0a, 0x0b, 0x70, 0x61, 0x72, 0x65, 0x6e, - 0x74, 0x5f, 0x68, 0x61, 0x73, 0x68, 0x18, 0x01, 0x20, 0x01, 0x28, 0x0c, 0x52, 0x0a, 0x70, 0x61, - 0x72, 0x65, 0x6e, 0x74, 0x48, 0x61, 0x73, 0x68, 0x12, 0x1d, 0x0a, 0x0a, 0x75, 0x6e, 0x63, 0x6c, - 0x65, 0x5f, 0x68, 0x61, 0x73, 0x68, 0x18, 0x02, 0x20, 0x01, 0x28, 0x0c, 0x52, 0x09, 0x75, 0x6e, - 0x63, 0x6c, 0x65, 0x48, 0x61, 0x73, 0x68, 0x12, 0x1a, 0x0a, 0x08, 0x63, 0x6f, 0x69, 0x6e, 0x62, - 0x61, 0x73, 0x65, 0x18, 0x03, 0x20, 0x01, 0x28, 0x0c, 0x52, 0x08, 0x63, 0x6f, 0x69, 0x6e, 0x62, - 0x61, 0x73, 0x65, 0x12, 0x1d, 0x0a, 0x0a, 0x73, 0x74, 0x61, 0x74, 0x65, 0x5f, 0x72, 0x6f, 0x6f, - 0x74, 0x18, 0x04, 0x20, 0x01, 0x28, 0x0c, 0x52, 0x09, 0x73, 0x74, 0x61, 0x74, 0x65, 0x52, 0x6f, - 0x6f, 0x74, 0x12, 0x2b, 0x0a, 0x11, 0x74, 0x72, 0x61, 0x6e, 0x73, 0x61, 0x63, 0x74, 0x69, 0x6f, - 0x6e, 0x73, 0x5f, 0x72, 0x6f, 0x6f, 0x74, 0x18, 0x05, 0x20, 0x01, 0x28, 0x0c, 0x52, 0x10, 0x74, - 0x72, 0x61, 0x6e, 0x73, 0x61, 0x63, 0x74, 0x69, 0x6f, 0x6e, 0x73, 0x52, 0x6f, 0x6f, 0x74, 0x12, - 0x21, 0x0a, 0x0c, 0x72, 0x65, 0x63, 0x65, 0x69, 0x70, 0x74, 0x5f, 0x72, 0x6f, 0x6f, 0x74, 0x18, - 0x06, 0x20, 0x01, 0x28, 0x0c, 0x52, 0x0b, 0x72, 0x65, 0x63, 0x65, 0x69, 0x70, 0x74, 0x52, 0x6f, - 0x6f, 0x74, 0x12, 0x1d, 0x0a, 0x0a, 0x6c, 0x6f, 0x67, 0x73, 0x5f, 0x62, 0x6c, 0x6f, 0x6f, 0x6d, - 0x18, 0x07, 0x20, 0x01, 0x28, 0x0c, 0x52, 0x09, 0x6c, 0x6f, 0x67, 0x73, 0x42, 0x6c, 0x6f, 0x6f, - 0x6d, 0x12, 0x3b, 0x0a, 0x0a, 0x64, 0x69, 0x66, 0x66, 0x69, 0x63, 0x75, 0x6c, 0x74, 0x79, 0x18, - 0x08, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x1b, 0x2e, 0x73, 0x66, 0x2e, 0x65, 0x74, 0x68, 0x65, 0x72, - 0x65, 0x75, 0x6d, 0x2e, 0x74, 0x79, 0x70, 0x65, 0x2e, 0x76, 0x32, 0x2e, 0x42, 0x69, 0x67, 0x49, - 0x6e, 0x74, 0x52, 0x0a, 0x64, 0x69, 0x66, 0x66, 0x69, 0x63, 0x75, 0x6c, 0x74, 0x79, 0x12, 0x4a, - 0x0a, 0x10, 0x74, 0x6f, 0x74, 0x61, 0x6c, 0x5f, 0x64, 0x69, 0x66, 0x66, 0x69, 0x63, 0x75, 0x6c, - 0x74, 0x79, 0x18, 0x11, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x1b, 0x2e, 0x73, 0x66, 0x2e, 0x65, 0x74, - 0x68, 0x65, 0x72, 0x65, 0x75, 0x6d, 0x2e, 0x74, 0x79, 0x70, 0x65, 0x2e, 0x76, 0x32, 0x2e, 0x42, - 0x69, 0x67, 0x49, 0x6e, 0x74, 0x42, 0x02, 0x18, 0x01, 0x52, 0x0f, 0x74, 0x6f, 0x74, 0x61, 0x6c, - 0x44, 0x69, 0x66, 0x66, 0x69, 0x63, 0x75, 0x6c, 0x74, 0x79, 0x12, 0x16, 0x0a, 0x06, 0x6e, 0x75, - 0x6d, 0x62, 0x65, 0x72, 0x18, 0x09, 0x20, 0x01, 0x28, 0x04, 0x52, 0x06, 0x6e, 0x75, 0x6d, 0x62, - 0x65, 0x72, 0x12, 0x1b, 0x0a, 0x09, 0x67, 0x61, 0x73, 0x5f, 0x6c, 0x69, 0x6d, 0x69, 0x74, 0x18, - 0x0a, 0x20, 0x01, 0x28, 0x04, 0x52, 0x08, 0x67, 0x61, 0x73, 0x4c, 0x69, 0x6d, 0x69, 0x74, 0x12, - 0x19, 0x0a, 0x08, 0x67, 0x61, 0x73, 0x5f, 0x75, 0x73, 0x65, 0x64, 0x18, 0x0b, 0x20, 0x01, 0x28, - 0x04, 0x52, 0x07, 0x67, 0x61, 0x73, 0x55, 0x73, 0x65, 0x64, 0x12, 0x38, 0x0a, 0x09, 0x74, 0x69, - 0x6d, 0x65, 0x73, 0x74, 0x61, 0x6d, 0x70, 0x18, 0x0c, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x1a, 0x2e, - 0x67, 0x6f, 0x6f, 0x67, 0x6c, 0x65, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x62, 0x75, 0x66, 0x2e, - 0x54, 0x69, 0x6d, 0x65, 0x73, 0x74, 0x61, 0x6d, 0x70, 0x52, 0x09, 0x74, 0x69, 0x6d, 0x65, 0x73, - 0x74, 0x61, 0x6d, 0x70, 0x12, 0x1d, 0x0a, 0x0a, 0x65, 0x78, 0x74, 0x72, 0x61, 0x5f, 0x64, 0x61, - 0x74, 0x61, 0x18, 0x0d, 0x20, 0x01, 0x28, 0x0c, 0x52, 0x09, 0x65, 0x78, 0x74, 0x72, 0x61, 0x44, - 0x61, 0x74, 0x61, 0x12, 0x19, 0x0a, 0x08, 0x6d, 0x69, 0x78, 0x5f, 0x68, 0x61, 0x73, 0x68, 0x18, - 0x0e, 0x20, 0x01, 0x28, 0x0c, 0x52, 0x07, 0x6d, 0x69, 0x78, 0x48, 0x61, 0x73, 0x68, 0x12, 0x14, - 0x0a, 0x05, 0x6e, 0x6f, 0x6e, 0x63, 0x65, 0x18, 0x0f, 0x20, 0x01, 0x28, 0x04, 0x52, 0x05, 0x6e, - 0x6f, 0x6e, 0x63, 0x65, 0x12, 0x12, 0x0a, 0x04, 0x68, 0x61, 0x73, 0x68, 0x18, 0x10, 0x20, 0x01, - 0x28, 0x0c, 0x52, 0x04, 0x68, 0x61, 0x73, 0x68, 0x12, 0x44, 0x0a, 0x10, 0x62, 0x61, 0x73, 0x65, - 0x5f, 0x66, 0x65, 0x65, 0x5f, 0x70, 0x65, 0x72, 0x5f, 0x67, 0x61, 0x73, 0x18, 0x12, 0x20, 0x01, - 0x28, 0x0b, 0x32, 0x1b, 0x2e, 0x73, 0x66, 0x2e, 0x65, 0x74, 0x68, 0x65, 0x72, 0x65, 0x75, 0x6d, - 0x2e, 0x74, 0x79, 0x70, 0x65, 0x2e, 0x76, 0x32, 0x2e, 0x42, 0x69, 0x67, 0x49, 0x6e, 0x74, 0x52, - 0x0d, 0x62, 0x61, 0x73, 0x65, 0x46, 0x65, 0x65, 0x50, 0x65, 0x72, 0x47, 0x61, 0x73, 0x12, 0x29, - 0x0a, 0x10, 0x77, 0x69, 0x74, 0x68, 0x64, 0x72, 0x61, 0x77, 0x61, 0x6c, 0x73, 0x5f, 0x72, 0x6f, - 0x6f, 0x74, 0x18, 0x13, 0x20, 0x01, 0x28, 0x0c, 0x52, 0x0f, 0x77, 0x69, 0x74, 0x68, 0x64, 0x72, - 0x61, 0x77, 0x61, 0x6c, 0x73, 0x52, 0x6f, 0x6f, 0x74, 0x12, 0x4b, 0x0a, 0x0d, 0x74, 0x78, 0x5f, - 0x64, 0x65, 0x70, 0x65, 0x6e, 0x64, 0x65, 0x6e, 0x63, 0x79, 0x18, 0x14, 0x20, 0x01, 0x28, 0x0b, - 0x32, 0x26, 0x2e, 0x73, 0x66, 0x2e, 0x65, 0x74, 0x68, 0x65, 0x72, 0x65, 0x75, 0x6d, 0x2e, 0x74, - 0x79, 0x70, 0x65, 0x2e, 0x76, 0x32, 0x2e, 0x55, 0x69, 0x6e, 0x74, 0x36, 0x34, 0x4e, 0x65, 0x73, - 0x74, 0x65, 0x64, 0x41, 0x72, 0x72, 0x61, 0x79, 0x52, 0x0c, 0x74, 0x78, 0x44, 0x65, 0x70, 0x65, - 0x6e, 0x64, 0x65, 0x6e, 0x63, 0x79, 0x12, 0x27, 0x0a, 0x0d, 0x62, 0x6c, 0x6f, 0x62, 0x5f, 0x67, - 0x61, 0x73, 0x5f, 0x75, 0x73, 0x65, 0x64, 0x18, 0x16, 0x20, 0x01, 0x28, 0x04, 0x48, 0x00, 0x52, - 0x0b, 0x62, 0x6c, 0x6f, 0x62, 0x47, 0x61, 0x73, 0x55, 0x73, 0x65, 0x64, 0x88, 0x01, 0x01, 0x12, - 0x2b, 0x0a, 0x0f, 0x65, 0x78, 0x63, 0x65, 0x73, 0x73, 0x5f, 0x62, 0x6c, 0x6f, 0x62, 0x5f, 0x67, - 0x61, 0x73, 0x18, 0x17, 0x20, 0x01, 0x28, 0x04, 0x48, 0x01, 0x52, 0x0d, 0x65, 0x78, 0x63, 0x65, - 0x73, 0x73, 0x42, 0x6c, 0x6f, 0x62, 0x47, 0x61, 0x73, 0x88, 0x01, 0x01, 0x12, 0x2c, 0x0a, 0x12, - 0x70, 0x61, 0x72, 0x65, 0x6e, 0x74, 0x5f, 0x62, 0x65, 0x61, 0x63, 0x6f, 0x6e, 0x5f, 0x72, 0x6f, - 0x6f, 0x74, 0x18, 0x18, 0x20, 0x01, 0x28, 0x0c, 0x52, 0x10, 0x70, 0x61, 0x72, 0x65, 0x6e, 0x74, - 0x42, 0x65, 0x61, 0x63, 0x6f, 0x6e, 0x52, 0x6f, 0x6f, 0x74, 0x12, 0x23, 0x0a, 0x0d, 0x72, 0x65, - 0x71, 0x75, 0x65, 0x73, 0x74, 0x73, 0x5f, 0x68, 0x61, 0x73, 0x68, 0x18, 0x19, 0x20, 0x01, 0x28, - 0x0c, 0x52, 0x0c, 0x72, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x73, 0x48, 0x61, 0x73, 0x68, 0x42, - 0x10, 0x0a, 0x0e, 0x5f, 0x62, 0x6c, 0x6f, 0x62, 0x5f, 0x67, 0x61, 0x73, 0x5f, 0x75, 0x73, 0x65, - 0x64, 0x42, 0x12, 0x0a, 0x10, 0x5f, 0x65, 0x78, 0x63, 0x65, 0x73, 0x73, 0x5f, 0x62, 0x6c, 0x6f, - 0x62, 0x5f, 0x67, 0x61, 0x73, 0x22, 0x47, 0x0a, 0x11, 0x55, 0x69, 0x6e, 0x74, 0x36, 0x34, 0x4e, - 0x65, 0x73, 0x74, 0x65, 0x64, 0x41, 0x72, 0x72, 0x61, 0x79, 0x12, 0x32, 0x0a, 0x03, 0x76, 0x61, - 0x6c, 0x18, 0x01, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x20, 0x2e, 0x73, 0x66, 0x2e, 0x65, 0x74, 0x68, - 0x65, 0x72, 0x65, 0x75, 0x6d, 0x2e, 0x74, 0x79, 0x70, 0x65, 0x2e, 0x76, 0x32, 0x2e, 0x55, 0x69, - 0x6e, 0x74, 0x36, 0x34, 0x41, 0x72, 0x72, 0x61, 0x79, 0x52, 0x03, 0x76, 0x61, 0x6c, 0x22, 0x1f, - 0x0a, 0x0b, 0x55, 0x69, 0x6e, 0x74, 0x36, 0x34, 0x41, 0x72, 0x72, 0x61, 0x79, 0x12, 0x10, 0x0a, - 0x03, 0x76, 0x61, 0x6c, 0x18, 0x01, 0x20, 0x03, 0x28, 0x04, 0x52, 0x03, 0x76, 0x61, 0x6c, 0x22, - 0x1e, 0x0a, 0x06, 0x42, 0x69, 0x67, 0x49, 0x6e, 0x74, 0x12, 0x14, 0x0a, 0x05, 0x62, 0x79, 0x74, - 0x65, 0x73, 0x18, 0x01, 0x20, 0x01, 0x28, 0x0c, 0x52, 0x05, 0x62, 0x79, 0x74, 0x65, 0x73, 0x22, - 0xe1, 0x0b, 0x0a, 0x10, 0x54, 0x72, 0x61, 0x6e, 0x73, 0x61, 0x63, 0x74, 0x69, 0x6f, 0x6e, 0x54, - 0x72, 0x61, 0x63, 0x65, 0x12, 0x0e, 0x0a, 0x02, 0x74, 0x6f, 0x18, 0x01, 0x20, 0x01, 0x28, 0x0c, - 0x52, 0x02, 0x74, 0x6f, 0x12, 0x14, 0x0a, 0x05, 0x6e, 0x6f, 0x6e, 0x63, 0x65, 0x18, 0x02, 0x20, - 0x01, 0x28, 0x04, 0x52, 0x05, 0x6e, 0x6f, 0x6e, 0x63, 0x65, 0x12, 0x38, 0x0a, 0x09, 0x67, 0x61, - 0x73, 0x5f, 0x70, 0x72, 0x69, 0x63, 0x65, 0x18, 0x03, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x1b, 0x2e, - 0x73, 0x66, 0x2e, 0x65, 0x74, 0x68, 0x65, 0x72, 0x65, 0x75, 0x6d, 0x2e, 0x74, 0x79, 0x70, 0x65, - 0x2e, 0x76, 0x32, 0x2e, 0x42, 0x69, 0x67, 0x49, 0x6e, 0x74, 0x52, 0x08, 0x67, 0x61, 0x73, 0x50, - 0x72, 0x69, 0x63, 0x65, 0x12, 0x1b, 0x0a, 0x09, 0x67, 0x61, 0x73, 0x5f, 0x6c, 0x69, 0x6d, 0x69, - 0x74, 0x18, 0x04, 0x20, 0x01, 0x28, 0x04, 0x52, 0x08, 0x67, 0x61, 0x73, 0x4c, 0x69, 0x6d, 0x69, - 0x74, 0x12, 0x31, 0x0a, 0x05, 0x76, 0x61, 0x6c, 0x75, 0x65, 0x18, 0x05, 0x20, 0x01, 0x28, 0x0b, - 0x32, 0x1b, 0x2e, 0x73, 0x66, 0x2e, 0x65, 0x74, 0x68, 0x65, 0x72, 0x65, 0x75, 0x6d, 0x2e, 0x74, - 0x79, 0x70, 0x65, 0x2e, 0x76, 0x32, 0x2e, 0x42, 0x69, 0x67, 0x49, 0x6e, 0x74, 0x52, 0x05, 0x76, - 0x61, 0x6c, 0x75, 0x65, 0x12, 0x14, 0x0a, 0x05, 0x69, 0x6e, 0x70, 0x75, 0x74, 0x18, 0x06, 0x20, - 0x01, 0x28, 0x0c, 0x52, 0x05, 0x69, 0x6e, 0x70, 0x75, 0x74, 0x12, 0x0c, 0x0a, 0x01, 0x76, 0x18, - 0x07, 0x20, 0x01, 0x28, 0x0c, 0x52, 0x01, 0x76, 0x12, 0x0c, 0x0a, 0x01, 0x72, 0x18, 0x08, 0x20, - 0x01, 0x28, 0x0c, 0x52, 0x01, 0x72, 0x12, 0x0c, 0x0a, 0x01, 0x73, 0x18, 0x09, 0x20, 0x01, 0x28, - 0x0c, 0x52, 0x01, 0x73, 0x12, 0x19, 0x0a, 0x08, 0x67, 0x61, 0x73, 0x5f, 0x75, 0x73, 0x65, 0x64, - 0x18, 0x0a, 0x20, 0x01, 0x28, 0x04, 0x52, 0x07, 0x67, 0x61, 0x73, 0x55, 0x73, 0x65, 0x64, 0x12, - 0x3e, 0x0a, 0x04, 0x74, 0x79, 0x70, 0x65, 0x18, 0x0c, 0x20, 0x01, 0x28, 0x0e, 0x32, 0x2a, 0x2e, - 0x73, 0x66, 0x2e, 0x65, 0x74, 0x68, 0x65, 0x72, 0x65, 0x75, 0x6d, 0x2e, 0x74, 0x79, 0x70, 0x65, - 0x2e, 0x76, 0x32, 0x2e, 0x54, 0x72, 0x61, 0x6e, 0x73, 0x61, 0x63, 0x74, 0x69, 0x6f, 0x6e, 0x54, - 0x72, 0x61, 0x63, 0x65, 0x2e, 0x54, 0x79, 0x70, 0x65, 0x52, 0x04, 0x74, 0x79, 0x70, 0x65, 0x12, - 0x41, 0x0a, 0x0b, 0x61, 0x63, 0x63, 0x65, 0x73, 0x73, 0x5f, 0x6c, 0x69, 0x73, 0x74, 0x18, 0x0e, - 0x20, 0x03, 0x28, 0x0b, 0x32, 0x20, 0x2e, 0x73, 0x66, 0x2e, 0x65, 0x74, 0x68, 0x65, 0x72, 0x65, - 0x75, 0x6d, 0x2e, 0x74, 0x79, 0x70, 0x65, 0x2e, 0x76, 0x32, 0x2e, 0x41, 0x63, 0x63, 0x65, 0x73, - 0x73, 0x54, 0x75, 0x70, 0x6c, 0x65, 0x52, 0x0a, 0x61, 0x63, 0x63, 0x65, 0x73, 0x73, 0x4c, 0x69, - 0x73, 0x74, 0x12, 0x42, 0x0a, 0x0f, 0x6d, 0x61, 0x78, 0x5f, 0x66, 0x65, 0x65, 0x5f, 0x70, 0x65, - 0x72, 0x5f, 0x67, 0x61, 0x73, 0x18, 0x0b, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x1b, 0x2e, 0x73, 0x66, - 0x2e, 0x65, 0x74, 0x68, 0x65, 0x72, 0x65, 0x75, 0x6d, 0x2e, 0x74, 0x79, 0x70, 0x65, 0x2e, 0x76, - 0x32, 0x2e, 0x42, 0x69, 0x67, 0x49, 0x6e, 0x74, 0x52, 0x0c, 0x6d, 0x61, 0x78, 0x46, 0x65, 0x65, - 0x50, 0x65, 0x72, 0x47, 0x61, 0x73, 0x12, 0x53, 0x0a, 0x18, 0x6d, 0x61, 0x78, 0x5f, 0x70, 0x72, - 0x69, 0x6f, 0x72, 0x69, 0x74, 0x79, 0x5f, 0x66, 0x65, 0x65, 0x5f, 0x70, 0x65, 0x72, 0x5f, 0x67, - 0x61, 0x73, 0x18, 0x0d, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x1b, 0x2e, 0x73, 0x66, 0x2e, 0x65, 0x74, - 0x68, 0x65, 0x72, 0x65, 0x75, 0x6d, 0x2e, 0x74, 0x79, 0x70, 0x65, 0x2e, 0x76, 0x32, 0x2e, 0x42, - 0x69, 0x67, 0x49, 0x6e, 0x74, 0x52, 0x14, 0x6d, 0x61, 0x78, 0x50, 0x72, 0x69, 0x6f, 0x72, 0x69, - 0x74, 0x79, 0x46, 0x65, 0x65, 0x50, 0x65, 0x72, 0x47, 0x61, 0x73, 0x12, 0x14, 0x0a, 0x05, 0x69, - 0x6e, 0x64, 0x65, 0x78, 0x18, 0x14, 0x20, 0x01, 0x28, 0x0d, 0x52, 0x05, 0x69, 0x6e, 0x64, 0x65, - 0x78, 0x12, 0x12, 0x0a, 0x04, 0x68, 0x61, 0x73, 0x68, 0x18, 0x15, 0x20, 0x01, 0x28, 0x0c, 0x52, - 0x04, 0x68, 0x61, 0x73, 0x68, 0x12, 0x12, 0x0a, 0x04, 0x66, 0x72, 0x6f, 0x6d, 0x18, 0x16, 0x20, - 0x01, 0x28, 0x0c, 0x52, 0x04, 0x66, 0x72, 0x6f, 0x6d, 0x12, 0x1f, 0x0a, 0x0b, 0x72, 0x65, 0x74, - 0x75, 0x72, 0x6e, 0x5f, 0x64, 0x61, 0x74, 0x61, 0x18, 0x17, 0x20, 0x01, 0x28, 0x0c, 0x52, 0x0a, - 0x72, 0x65, 0x74, 0x75, 0x72, 0x6e, 0x44, 0x61, 0x74, 0x61, 0x12, 0x1d, 0x0a, 0x0a, 0x70, 0x75, - 0x62, 0x6c, 0x69, 0x63, 0x5f, 0x6b, 0x65, 0x79, 0x18, 0x18, 0x20, 0x01, 0x28, 0x0c, 0x52, 0x09, - 0x70, 0x75, 0x62, 0x6c, 0x69, 0x63, 0x4b, 0x65, 0x79, 0x12, 0x23, 0x0a, 0x0d, 0x62, 0x65, 0x67, - 0x69, 0x6e, 0x5f, 0x6f, 0x72, 0x64, 0x69, 0x6e, 0x61, 0x6c, 0x18, 0x19, 0x20, 0x01, 0x28, 0x04, - 0x52, 0x0c, 0x62, 0x65, 0x67, 0x69, 0x6e, 0x4f, 0x72, 0x64, 0x69, 0x6e, 0x61, 0x6c, 0x12, 0x1f, - 0x0a, 0x0b, 0x65, 0x6e, 0x64, 0x5f, 0x6f, 0x72, 0x64, 0x69, 0x6e, 0x61, 0x6c, 0x18, 0x1a, 0x20, - 0x01, 0x28, 0x04, 0x52, 0x0a, 0x65, 0x6e, 0x64, 0x4f, 0x72, 0x64, 0x69, 0x6e, 0x61, 0x6c, 0x12, - 0x43, 0x0a, 0x06, 0x73, 0x74, 0x61, 0x74, 0x75, 0x73, 0x18, 0x1e, 0x20, 0x01, 0x28, 0x0e, 0x32, - 0x2b, 0x2e, 0x73, 0x66, 0x2e, 0x65, 0x74, 0x68, 0x65, 0x72, 0x65, 0x75, 0x6d, 0x2e, 0x74, 0x79, - 0x70, 0x65, 0x2e, 0x76, 0x32, 0x2e, 0x54, 0x72, 0x61, 0x6e, 0x73, 0x61, 0x63, 0x74, 0x69, 0x6f, - 0x6e, 0x54, 0x72, 0x61, 0x63, 0x65, 0x53, 0x74, 0x61, 0x74, 0x75, 0x73, 0x52, 0x06, 0x73, 0x74, - 0x61, 0x74, 0x75, 0x73, 0x12, 0x41, 0x0a, 0x07, 0x72, 0x65, 0x63, 0x65, 0x69, 0x70, 0x74, 0x18, - 0x1f, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x27, 0x2e, 0x73, 0x66, 0x2e, 0x65, 0x74, 0x68, 0x65, 0x72, - 0x65, 0x75, 0x6d, 0x2e, 0x74, 0x79, 0x70, 0x65, 0x2e, 0x76, 0x32, 0x2e, 0x54, 0x72, 0x61, 0x6e, - 0x73, 0x61, 0x63, 0x74, 0x69, 0x6f, 0x6e, 0x52, 0x65, 0x63, 0x65, 0x69, 0x70, 0x74, 0x52, 0x07, - 0x72, 0x65, 0x63, 0x65, 0x69, 0x70, 0x74, 0x12, 0x2f, 0x0a, 0x05, 0x63, 0x61, 0x6c, 0x6c, 0x73, - 0x18, 0x20, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x19, 0x2e, 0x73, 0x66, 0x2e, 0x65, 0x74, 0x68, 0x65, - 0x72, 0x65, 0x75, 0x6d, 0x2e, 0x74, 0x79, 0x70, 0x65, 0x2e, 0x76, 0x32, 0x2e, 0x43, 0x61, 0x6c, - 0x6c, 0x52, 0x05, 0x63, 0x61, 0x6c, 0x6c, 0x73, 0x12, 0x1e, 0x0a, 0x08, 0x62, 0x6c, 0x6f, 0x62, - 0x5f, 0x67, 0x61, 0x73, 0x18, 0x21, 0x20, 0x01, 0x28, 0x04, 0x48, 0x00, 0x52, 0x07, 0x62, 0x6c, - 0x6f, 0x62, 0x47, 0x61, 0x73, 0x88, 0x01, 0x01, 0x12, 0x49, 0x0a, 0x10, 0x62, 0x6c, 0x6f, 0x62, - 0x5f, 0x67, 0x61, 0x73, 0x5f, 0x66, 0x65, 0x65, 0x5f, 0x63, 0x61, 0x70, 0x18, 0x22, 0x20, 0x01, - 0x28, 0x0b, 0x32, 0x1b, 0x2e, 0x73, 0x66, 0x2e, 0x65, 0x74, 0x68, 0x65, 0x72, 0x65, 0x75, 0x6d, - 0x2e, 0x74, 0x79, 0x70, 0x65, 0x2e, 0x76, 0x32, 0x2e, 0x42, 0x69, 0x67, 0x49, 0x6e, 0x74, 0x48, - 0x01, 0x52, 0x0d, 0x62, 0x6c, 0x6f, 0x62, 0x47, 0x61, 0x73, 0x46, 0x65, 0x65, 0x43, 0x61, 0x70, - 0x88, 0x01, 0x01, 0x12, 0x1f, 0x0a, 0x0b, 0x62, 0x6c, 0x6f, 0x62, 0x5f, 0x68, 0x61, 0x73, 0x68, - 0x65, 0x73, 0x18, 0x23, 0x20, 0x03, 0x28, 0x0c, 0x52, 0x0a, 0x62, 0x6c, 0x6f, 0x62, 0x48, 0x61, - 0x73, 0x68, 0x65, 0x73, 0x22, 0xfa, 0x02, 0x0a, 0x04, 0x54, 0x79, 0x70, 0x65, 0x12, 0x13, 0x0a, - 0x0f, 0x54, 0x52, 0x58, 0x5f, 0x54, 0x59, 0x50, 0x45, 0x5f, 0x4c, 0x45, 0x47, 0x41, 0x43, 0x59, - 0x10, 0x00, 0x12, 0x18, 0x0a, 0x14, 0x54, 0x52, 0x58, 0x5f, 0x54, 0x59, 0x50, 0x45, 0x5f, 0x41, - 0x43, 0x43, 0x45, 0x53, 0x53, 0x5f, 0x4c, 0x49, 0x53, 0x54, 0x10, 0x01, 0x12, 0x18, 0x0a, 0x14, - 0x54, 0x52, 0x58, 0x5f, 0x54, 0x59, 0x50, 0x45, 0x5f, 0x44, 0x59, 0x4e, 0x41, 0x4d, 0x49, 0x43, - 0x5f, 0x46, 0x45, 0x45, 0x10, 0x02, 0x12, 0x11, 0x0a, 0x0d, 0x54, 0x52, 0x58, 0x5f, 0x54, 0x59, - 0x50, 0x45, 0x5f, 0x42, 0x4c, 0x4f, 0x42, 0x10, 0x03, 0x12, 0x15, 0x0a, 0x11, 0x54, 0x52, 0x58, - 0x5f, 0x54, 0x59, 0x50, 0x45, 0x5f, 0x53, 0x45, 0x54, 0x5f, 0x43, 0x4f, 0x44, 0x45, 0x10, 0x04, - 0x12, 0x1d, 0x0a, 0x19, 0x54, 0x52, 0x58, 0x5f, 0x54, 0x59, 0x50, 0x45, 0x5f, 0x41, 0x52, 0x42, - 0x49, 0x54, 0x52, 0x55, 0x4d, 0x5f, 0x44, 0x45, 0x50, 0x4f, 0x53, 0x49, 0x54, 0x10, 0x64, 0x12, - 0x1e, 0x0a, 0x1a, 0x54, 0x52, 0x58, 0x5f, 0x54, 0x59, 0x50, 0x45, 0x5f, 0x41, 0x52, 0x42, 0x49, - 0x54, 0x52, 0x55, 0x4d, 0x5f, 0x55, 0x4e, 0x53, 0x49, 0x47, 0x4e, 0x45, 0x44, 0x10, 0x65, 0x12, - 0x1e, 0x0a, 0x1a, 0x54, 0x52, 0x58, 0x5f, 0x54, 0x59, 0x50, 0x45, 0x5f, 0x41, 0x52, 0x42, 0x49, - 0x54, 0x52, 0x55, 0x4d, 0x5f, 0x43, 0x4f, 0x4e, 0x54, 0x52, 0x41, 0x43, 0x54, 0x10, 0x66, 0x12, - 0x1b, 0x0a, 0x17, 0x54, 0x52, 0x58, 0x5f, 0x54, 0x59, 0x50, 0x45, 0x5f, 0x41, 0x52, 0x42, 0x49, - 0x54, 0x52, 0x55, 0x4d, 0x5f, 0x52, 0x45, 0x54, 0x52, 0x59, 0x10, 0x68, 0x12, 0x26, 0x0a, 0x22, - 0x54, 0x52, 0x58, 0x5f, 0x54, 0x59, 0x50, 0x45, 0x5f, 0x41, 0x52, 0x42, 0x49, 0x54, 0x52, 0x55, - 0x4d, 0x5f, 0x53, 0x55, 0x42, 0x4d, 0x49, 0x54, 0x5f, 0x52, 0x45, 0x54, 0x52, 0x59, 0x41, 0x42, - 0x4c, 0x45, 0x10, 0x69, 0x12, 0x1e, 0x0a, 0x1a, 0x54, 0x52, 0x58, 0x5f, 0x54, 0x59, 0x50, 0x45, - 0x5f, 0x41, 0x52, 0x42, 0x49, 0x54, 0x52, 0x55, 0x4d, 0x5f, 0x49, 0x4e, 0x54, 0x45, 0x52, 0x4e, - 0x41, 0x4c, 0x10, 0x6a, 0x12, 0x1c, 0x0a, 0x18, 0x54, 0x52, 0x58, 0x5f, 0x54, 0x59, 0x50, 0x45, - 0x5f, 0x41, 0x52, 0x42, 0x49, 0x54, 0x52, 0x55, 0x4d, 0x5f, 0x4c, 0x45, 0x47, 0x41, 0x43, 0x59, - 0x10, 0x78, 0x12, 0x1d, 0x0a, 0x19, 0x54, 0x52, 0x58, 0x5f, 0x54, 0x59, 0x50, 0x45, 0x5f, 0x4f, - 0x50, 0x54, 0x49, 0x4d, 0x49, 0x53, 0x4d, 0x5f, 0x44, 0x45, 0x50, 0x4f, 0x53, 0x49, 0x54, 0x10, - 0x7e, 0x42, 0x0b, 0x0a, 0x09, 0x5f, 0x62, 0x6c, 0x6f, 0x62, 0x5f, 0x67, 0x61, 0x73, 0x42, 0x13, - 0x0a, 0x11, 0x5f, 0x62, 0x6c, 0x6f, 0x62, 0x5f, 0x67, 0x61, 0x73, 0x5f, 0x66, 0x65, 0x65, 0x5f, - 0x63, 0x61, 0x70, 0x22, 0x4a, 0x0a, 0x0b, 0x41, 0x63, 0x63, 0x65, 0x73, 0x73, 0x54, 0x75, 0x70, - 0x6c, 0x65, 0x12, 0x18, 0x0a, 0x07, 0x61, 0x64, 0x64, 0x72, 0x65, 0x73, 0x73, 0x18, 0x01, 0x20, - 0x01, 0x28, 0x0c, 0x52, 0x07, 0x61, 0x64, 0x64, 0x72, 0x65, 0x73, 0x73, 0x12, 0x21, 0x0a, 0x0c, - 0x73, 0x74, 0x6f, 0x72, 0x61, 0x67, 0x65, 0x5f, 0x6b, 0x65, 0x79, 0x73, 0x18, 0x02, 0x20, 0x03, - 0x28, 0x0c, 0x52, 0x0b, 0x73, 0x74, 0x6f, 0x72, 0x61, 0x67, 0x65, 0x4b, 0x65, 0x79, 0x73, 0x22, - 0xc6, 0x02, 0x0a, 0x12, 0x54, 0x72, 0x61, 0x6e, 0x73, 0x61, 0x63, 0x74, 0x69, 0x6f, 0x6e, 0x52, - 0x65, 0x63, 0x65, 0x69, 0x70, 0x74, 0x12, 0x1d, 0x0a, 0x0a, 0x73, 0x74, 0x61, 0x74, 0x65, 0x5f, - 0x72, 0x6f, 0x6f, 0x74, 0x18, 0x01, 0x20, 0x01, 0x28, 0x0c, 0x52, 0x09, 0x73, 0x74, 0x61, 0x74, - 0x65, 0x52, 0x6f, 0x6f, 0x74, 0x12, 0x2e, 0x0a, 0x13, 0x63, 0x75, 0x6d, 0x75, 0x6c, 0x61, 0x74, - 0x69, 0x76, 0x65, 0x5f, 0x67, 0x61, 0x73, 0x5f, 0x75, 0x73, 0x65, 0x64, 0x18, 0x02, 0x20, 0x01, - 0x28, 0x04, 0x52, 0x11, 0x63, 0x75, 0x6d, 0x75, 0x6c, 0x61, 0x74, 0x69, 0x76, 0x65, 0x47, 0x61, - 0x73, 0x55, 0x73, 0x65, 0x64, 0x12, 0x1d, 0x0a, 0x0a, 0x6c, 0x6f, 0x67, 0x73, 0x5f, 0x62, 0x6c, - 0x6f, 0x6f, 0x6d, 0x18, 0x03, 0x20, 0x01, 0x28, 0x0c, 0x52, 0x09, 0x6c, 0x6f, 0x67, 0x73, 0x42, - 0x6c, 0x6f, 0x6f, 0x6d, 0x12, 0x2c, 0x0a, 0x04, 0x6c, 0x6f, 0x67, 0x73, 0x18, 0x04, 0x20, 0x03, - 0x28, 0x0b, 0x32, 0x18, 0x2e, 0x73, 0x66, 0x2e, 0x65, 0x74, 0x68, 0x65, 0x72, 0x65, 0x75, 0x6d, - 0x2e, 0x74, 0x79, 0x70, 0x65, 0x2e, 0x76, 0x32, 0x2e, 0x4c, 0x6f, 0x67, 0x52, 0x04, 0x6c, 0x6f, - 0x67, 0x73, 0x12, 0x27, 0x0a, 0x0d, 0x62, 0x6c, 0x6f, 0x62, 0x5f, 0x67, 0x61, 0x73, 0x5f, 0x75, - 0x73, 0x65, 0x64, 0x18, 0x05, 0x20, 0x01, 0x28, 0x04, 0x48, 0x00, 0x52, 0x0b, 0x62, 0x6c, 0x6f, - 0x62, 0x47, 0x61, 0x73, 0x55, 0x73, 0x65, 0x64, 0x88, 0x01, 0x01, 0x12, 0x46, 0x0a, 0x0e, 0x62, - 0x6c, 0x6f, 0x62, 0x5f, 0x67, 0x61, 0x73, 0x5f, 0x70, 0x72, 0x69, 0x63, 0x65, 0x18, 0x06, 0x20, - 0x01, 0x28, 0x0b, 0x32, 0x1b, 0x2e, 0x73, 0x66, 0x2e, 0x65, 0x74, 0x68, 0x65, 0x72, 0x65, 0x75, - 0x6d, 0x2e, 0x74, 0x79, 0x70, 0x65, 0x2e, 0x76, 0x32, 0x2e, 0x42, 0x69, 0x67, 0x49, 0x6e, 0x74, - 0x48, 0x01, 0x52, 0x0c, 0x62, 0x6c, 0x6f, 0x62, 0x47, 0x61, 0x73, 0x50, 0x72, 0x69, 0x63, 0x65, - 0x88, 0x01, 0x01, 0x42, 0x10, 0x0a, 0x0e, 0x5f, 0x62, 0x6c, 0x6f, 0x62, 0x5f, 0x67, 0x61, 0x73, - 0x5f, 0x75, 0x73, 0x65, 0x64, 0x42, 0x11, 0x0a, 0x0f, 0x5f, 0x62, 0x6c, 0x6f, 0x62, 0x5f, 0x67, - 0x61, 0x73, 0x5f, 0x70, 0x72, 0x69, 0x63, 0x65, 0x22, 0x9b, 0x01, 0x0a, 0x03, 0x4c, 0x6f, 0x67, - 0x12, 0x18, 0x0a, 0x07, 0x61, 0x64, 0x64, 0x72, 0x65, 0x73, 0x73, 0x18, 0x01, 0x20, 0x01, 0x28, - 0x0c, 0x52, 0x07, 0x61, 0x64, 0x64, 0x72, 0x65, 0x73, 0x73, 0x12, 0x16, 0x0a, 0x06, 0x74, 0x6f, - 0x70, 0x69, 0x63, 0x73, 0x18, 0x02, 0x20, 0x03, 0x28, 0x0c, 0x52, 0x06, 0x74, 0x6f, 0x70, 0x69, - 0x63, 0x73, 0x12, 0x12, 0x0a, 0x04, 0x64, 0x61, 0x74, 0x61, 0x18, 0x03, 0x20, 0x01, 0x28, 0x0c, - 0x52, 0x04, 0x64, 0x61, 0x74, 0x61, 0x12, 0x14, 0x0a, 0x05, 0x69, 0x6e, 0x64, 0x65, 0x78, 0x18, - 0x04, 0x20, 0x01, 0x28, 0x0d, 0x52, 0x05, 0x69, 0x6e, 0x64, 0x65, 0x78, 0x12, 0x1e, 0x0a, 0x0a, - 0x62, 0x6c, 0x6f, 0x63, 0x6b, 0x49, 0x6e, 0x64, 0x65, 0x78, 0x18, 0x06, 0x20, 0x01, 0x28, 0x0d, - 0x52, 0x0a, 0x62, 0x6c, 0x6f, 0x63, 0x6b, 0x49, 0x6e, 0x64, 0x65, 0x78, 0x12, 0x18, 0x0a, 0x07, - 0x6f, 0x72, 0x64, 0x69, 0x6e, 0x61, 0x6c, 0x18, 0x07, 0x20, 0x01, 0x28, 0x04, 0x52, 0x07, 0x6f, - 0x72, 0x64, 0x69, 0x6e, 0x61, 0x6c, 0x22, 0xb2, 0x0a, 0x0a, 0x04, 0x43, 0x61, 0x6c, 0x6c, 0x12, - 0x14, 0x0a, 0x05, 0x69, 0x6e, 0x64, 0x65, 0x78, 0x18, 0x01, 0x20, 0x01, 0x28, 0x0d, 0x52, 0x05, - 0x69, 0x6e, 0x64, 0x65, 0x78, 0x12, 0x21, 0x0a, 0x0c, 0x70, 0x61, 0x72, 0x65, 0x6e, 0x74, 0x5f, - 0x69, 0x6e, 0x64, 0x65, 0x78, 0x18, 0x02, 0x20, 0x01, 0x28, 0x0d, 0x52, 0x0b, 0x70, 0x61, 0x72, - 0x65, 0x6e, 0x74, 0x49, 0x6e, 0x64, 0x65, 0x78, 0x12, 0x14, 0x0a, 0x05, 0x64, 0x65, 0x70, 0x74, - 0x68, 0x18, 0x03, 0x20, 0x01, 0x28, 0x0d, 0x52, 0x05, 0x64, 0x65, 0x70, 0x74, 0x68, 0x12, 0x3a, - 0x0a, 0x09, 0x63, 0x61, 0x6c, 0x6c, 0x5f, 0x74, 0x79, 0x70, 0x65, 0x18, 0x04, 0x20, 0x01, 0x28, - 0x0e, 0x32, 0x1d, 0x2e, 0x73, 0x66, 0x2e, 0x65, 0x74, 0x68, 0x65, 0x72, 0x65, 0x75, 0x6d, 0x2e, - 0x74, 0x79, 0x70, 0x65, 0x2e, 0x76, 0x32, 0x2e, 0x43, 0x61, 0x6c, 0x6c, 0x54, 0x79, 0x70, 0x65, - 0x52, 0x08, 0x63, 0x61, 0x6c, 0x6c, 0x54, 0x79, 0x70, 0x65, 0x12, 0x16, 0x0a, 0x06, 0x63, 0x61, - 0x6c, 0x6c, 0x65, 0x72, 0x18, 0x05, 0x20, 0x01, 0x28, 0x0c, 0x52, 0x06, 0x63, 0x61, 0x6c, 0x6c, - 0x65, 0x72, 0x12, 0x18, 0x0a, 0x07, 0x61, 0x64, 0x64, 0x72, 0x65, 0x73, 0x73, 0x18, 0x06, 0x20, - 0x01, 0x28, 0x0c, 0x52, 0x07, 0x61, 0x64, 0x64, 0x72, 0x65, 0x73, 0x73, 0x12, 0x31, 0x0a, 0x05, - 0x76, 0x61, 0x6c, 0x75, 0x65, 0x18, 0x07, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x1b, 0x2e, 0x73, 0x66, - 0x2e, 0x65, 0x74, 0x68, 0x65, 0x72, 0x65, 0x75, 0x6d, 0x2e, 0x74, 0x79, 0x70, 0x65, 0x2e, 0x76, - 0x32, 0x2e, 0x42, 0x69, 0x67, 0x49, 0x6e, 0x74, 0x52, 0x05, 0x76, 0x61, 0x6c, 0x75, 0x65, 0x12, - 0x1b, 0x0a, 0x09, 0x67, 0x61, 0x73, 0x5f, 0x6c, 0x69, 0x6d, 0x69, 0x74, 0x18, 0x08, 0x20, 0x01, - 0x28, 0x04, 0x52, 0x08, 0x67, 0x61, 0x73, 0x4c, 0x69, 0x6d, 0x69, 0x74, 0x12, 0x21, 0x0a, 0x0c, - 0x67, 0x61, 0x73, 0x5f, 0x63, 0x6f, 0x6e, 0x73, 0x75, 0x6d, 0x65, 0x64, 0x18, 0x09, 0x20, 0x01, - 0x28, 0x04, 0x52, 0x0b, 0x67, 0x61, 0x73, 0x43, 0x6f, 0x6e, 0x73, 0x75, 0x6d, 0x65, 0x64, 0x12, - 0x1f, 0x0a, 0x0b, 0x72, 0x65, 0x74, 0x75, 0x72, 0x6e, 0x5f, 0x64, 0x61, 0x74, 0x61, 0x18, 0x0d, - 0x20, 0x01, 0x28, 0x0c, 0x52, 0x0a, 0x72, 0x65, 0x74, 0x75, 0x72, 0x6e, 0x44, 0x61, 0x74, 0x61, - 0x12, 0x14, 0x0a, 0x05, 0x69, 0x6e, 0x70, 0x75, 0x74, 0x18, 0x0e, 0x20, 0x01, 0x28, 0x0c, 0x52, - 0x05, 0x69, 0x6e, 0x70, 0x75, 0x74, 0x12, 0x23, 0x0a, 0x0d, 0x65, 0x78, 0x65, 0x63, 0x75, 0x74, - 0x65, 0x64, 0x5f, 0x63, 0x6f, 0x64, 0x65, 0x18, 0x0f, 0x20, 0x01, 0x28, 0x08, 0x52, 0x0c, 0x65, - 0x78, 0x65, 0x63, 0x75, 0x74, 0x65, 0x64, 0x43, 0x6f, 0x64, 0x65, 0x12, 0x18, 0x0a, 0x07, 0x73, - 0x75, 0x69, 0x63, 0x69, 0x64, 0x65, 0x18, 0x10, 0x20, 0x01, 0x28, 0x08, 0x52, 0x07, 0x73, 0x75, - 0x69, 0x63, 0x69, 0x64, 0x65, 0x12, 0x59, 0x0a, 0x10, 0x6b, 0x65, 0x63, 0x63, 0x61, 0x6b, 0x5f, - 0x70, 0x72, 0x65, 0x69, 0x6d, 0x61, 0x67, 0x65, 0x73, 0x18, 0x14, 0x20, 0x03, 0x28, 0x0b, 0x32, - 0x2e, 0x2e, 0x73, 0x66, 0x2e, 0x65, 0x74, 0x68, 0x65, 0x72, 0x65, 0x75, 0x6d, 0x2e, 0x74, 0x79, - 0x70, 0x65, 0x2e, 0x76, 0x32, 0x2e, 0x43, 0x61, 0x6c, 0x6c, 0x2e, 0x4b, 0x65, 0x63, 0x63, 0x61, - 0x6b, 0x50, 0x72, 0x65, 0x69, 0x6d, 0x61, 0x67, 0x65, 0x73, 0x45, 0x6e, 0x74, 0x72, 0x79, 0x52, - 0x0f, 0x6b, 0x65, 0x63, 0x63, 0x61, 0x6b, 0x50, 0x72, 0x65, 0x69, 0x6d, 0x61, 0x67, 0x65, 0x73, - 0x12, 0x4b, 0x0a, 0x0f, 0x73, 0x74, 0x6f, 0x72, 0x61, 0x67, 0x65, 0x5f, 0x63, 0x68, 0x61, 0x6e, - 0x67, 0x65, 0x73, 0x18, 0x15, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x22, 0x2e, 0x73, 0x66, 0x2e, 0x65, - 0x74, 0x68, 0x65, 0x72, 0x65, 0x75, 0x6d, 0x2e, 0x74, 0x79, 0x70, 0x65, 0x2e, 0x76, 0x32, 0x2e, - 0x53, 0x74, 0x6f, 0x72, 0x61, 0x67, 0x65, 0x43, 0x68, 0x61, 0x6e, 0x67, 0x65, 0x52, 0x0e, 0x73, - 0x74, 0x6f, 0x72, 0x61, 0x67, 0x65, 0x43, 0x68, 0x61, 0x6e, 0x67, 0x65, 0x73, 0x12, 0x4b, 0x0a, - 0x0f, 0x62, 0x61, 0x6c, 0x61, 0x6e, 0x63, 0x65, 0x5f, 0x63, 0x68, 0x61, 0x6e, 0x67, 0x65, 0x73, - 0x18, 0x16, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x22, 0x2e, 0x73, 0x66, 0x2e, 0x65, 0x74, 0x68, 0x65, - 0x72, 0x65, 0x75, 0x6d, 0x2e, 0x74, 0x79, 0x70, 0x65, 0x2e, 0x76, 0x32, 0x2e, 0x42, 0x61, 0x6c, - 0x61, 0x6e, 0x63, 0x65, 0x43, 0x68, 0x61, 0x6e, 0x67, 0x65, 0x52, 0x0e, 0x62, 0x61, 0x6c, 0x61, - 0x6e, 0x63, 0x65, 0x43, 0x68, 0x61, 0x6e, 0x67, 0x65, 0x73, 0x12, 0x45, 0x0a, 0x0d, 0x6e, 0x6f, - 0x6e, 0x63, 0x65, 0x5f, 0x63, 0x68, 0x61, 0x6e, 0x67, 0x65, 0x73, 0x18, 0x18, 0x20, 0x03, 0x28, - 0x0b, 0x32, 0x20, 0x2e, 0x73, 0x66, 0x2e, 0x65, 0x74, 0x68, 0x65, 0x72, 0x65, 0x75, 0x6d, 0x2e, - 0x74, 0x79, 0x70, 0x65, 0x2e, 0x76, 0x32, 0x2e, 0x4e, 0x6f, 0x6e, 0x63, 0x65, 0x43, 0x68, 0x61, - 0x6e, 0x67, 0x65, 0x52, 0x0c, 0x6e, 0x6f, 0x6e, 0x63, 0x65, 0x43, 0x68, 0x61, 0x6e, 0x67, 0x65, - 0x73, 0x12, 0x2c, 0x0a, 0x04, 0x6c, 0x6f, 0x67, 0x73, 0x18, 0x19, 0x20, 0x03, 0x28, 0x0b, 0x32, - 0x18, 0x2e, 0x73, 0x66, 0x2e, 0x65, 0x74, 0x68, 0x65, 0x72, 0x65, 0x75, 0x6d, 0x2e, 0x74, 0x79, - 0x70, 0x65, 0x2e, 0x76, 0x32, 0x2e, 0x4c, 0x6f, 0x67, 0x52, 0x04, 0x6c, 0x6f, 0x67, 0x73, 0x12, - 0x42, 0x0a, 0x0c, 0x63, 0x6f, 0x64, 0x65, 0x5f, 0x63, 0x68, 0x61, 0x6e, 0x67, 0x65, 0x73, 0x18, - 0x1a, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x1f, 0x2e, 0x73, 0x66, 0x2e, 0x65, 0x74, 0x68, 0x65, 0x72, - 0x65, 0x75, 0x6d, 0x2e, 0x74, 0x79, 0x70, 0x65, 0x2e, 0x76, 0x32, 0x2e, 0x43, 0x6f, 0x64, 0x65, - 0x43, 0x68, 0x61, 0x6e, 0x67, 0x65, 0x52, 0x0b, 0x63, 0x6f, 0x64, 0x65, 0x43, 0x68, 0x61, 0x6e, - 0x67, 0x65, 0x73, 0x12, 0x3f, 0x0a, 0x0b, 0x67, 0x61, 0x73, 0x5f, 0x63, 0x68, 0x61, 0x6e, 0x67, - 0x65, 0x73, 0x18, 0x1c, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x1e, 0x2e, 0x73, 0x66, 0x2e, 0x65, 0x74, - 0x68, 0x65, 0x72, 0x65, 0x75, 0x6d, 0x2e, 0x74, 0x79, 0x70, 0x65, 0x2e, 0x76, 0x32, 0x2e, 0x47, - 0x61, 0x73, 0x43, 0x68, 0x61, 0x6e, 0x67, 0x65, 0x52, 0x0a, 0x67, 0x61, 0x73, 0x43, 0x68, 0x61, - 0x6e, 0x67, 0x65, 0x73, 0x12, 0x23, 0x0a, 0x0d, 0x73, 0x74, 0x61, 0x74, 0x75, 0x73, 0x5f, 0x66, - 0x61, 0x69, 0x6c, 0x65, 0x64, 0x18, 0x0a, 0x20, 0x01, 0x28, 0x08, 0x52, 0x0c, 0x73, 0x74, 0x61, - 0x74, 0x75, 0x73, 0x46, 0x61, 0x69, 0x6c, 0x65, 0x64, 0x12, 0x27, 0x0a, 0x0f, 0x73, 0x74, 0x61, - 0x74, 0x75, 0x73, 0x5f, 0x72, 0x65, 0x76, 0x65, 0x72, 0x74, 0x65, 0x64, 0x18, 0x0c, 0x20, 0x01, - 0x28, 0x08, 0x52, 0x0e, 0x73, 0x74, 0x61, 0x74, 0x75, 0x73, 0x52, 0x65, 0x76, 0x65, 0x72, 0x74, - 0x65, 0x64, 0x12, 0x25, 0x0a, 0x0e, 0x66, 0x61, 0x69, 0x6c, 0x75, 0x72, 0x65, 0x5f, 0x72, 0x65, - 0x61, 0x73, 0x6f, 0x6e, 0x18, 0x0b, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0d, 0x66, 0x61, 0x69, 0x6c, - 0x75, 0x72, 0x65, 0x52, 0x65, 0x61, 0x73, 0x6f, 0x6e, 0x12, 0x25, 0x0a, 0x0e, 0x73, 0x74, 0x61, - 0x74, 0x65, 0x5f, 0x72, 0x65, 0x76, 0x65, 0x72, 0x74, 0x65, 0x64, 0x18, 0x1e, 0x20, 0x01, 0x28, - 0x08, 0x52, 0x0d, 0x73, 0x74, 0x61, 0x74, 0x65, 0x52, 0x65, 0x76, 0x65, 0x72, 0x74, 0x65, 0x64, - 0x12, 0x23, 0x0a, 0x0d, 0x62, 0x65, 0x67, 0x69, 0x6e, 0x5f, 0x6f, 0x72, 0x64, 0x69, 0x6e, 0x61, - 0x6c, 0x18, 0x1f, 0x20, 0x01, 0x28, 0x04, 0x52, 0x0c, 0x62, 0x65, 0x67, 0x69, 0x6e, 0x4f, 0x72, - 0x64, 0x69, 0x6e, 0x61, 0x6c, 0x12, 0x1f, 0x0a, 0x0b, 0x65, 0x6e, 0x64, 0x5f, 0x6f, 0x72, 0x64, - 0x69, 0x6e, 0x61, 0x6c, 0x18, 0x20, 0x20, 0x01, 0x28, 0x04, 0x52, 0x0a, 0x65, 0x6e, 0x64, 0x4f, - 0x72, 0x64, 0x69, 0x6e, 0x61, 0x6c, 0x12, 0x51, 0x0a, 0x11, 0x61, 0x63, 0x63, 0x6f, 0x75, 0x6e, - 0x74, 0x5f, 0x63, 0x72, 0x65, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x73, 0x18, 0x21, 0x20, 0x03, 0x28, - 0x0b, 0x32, 0x24, 0x2e, 0x73, 0x66, 0x2e, 0x65, 0x74, 0x68, 0x65, 0x72, 0x65, 0x75, 0x6d, 0x2e, - 0x74, 0x79, 0x70, 0x65, 0x2e, 0x76, 0x32, 0x2e, 0x41, 0x63, 0x63, 0x6f, 0x75, 0x6e, 0x74, 0x43, - 0x72, 0x65, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x52, 0x10, 0x61, 0x63, 0x63, 0x6f, 0x75, 0x6e, 0x74, - 0x43, 0x72, 0x65, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x73, 0x1a, 0x42, 0x0a, 0x14, 0x4b, 0x65, 0x63, - 0x63, 0x61, 0x6b, 0x50, 0x72, 0x65, 0x69, 0x6d, 0x61, 0x67, 0x65, 0x73, 0x45, 0x6e, 0x74, 0x72, - 0x79, 0x12, 0x10, 0x0a, 0x03, 0x6b, 0x65, 0x79, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x03, - 0x6b, 0x65, 0x79, 0x12, 0x14, 0x0a, 0x05, 0x76, 0x61, 0x6c, 0x75, 0x65, 0x18, 0x02, 0x20, 0x01, - 0x28, 0x09, 0x52, 0x05, 0x76, 0x61, 0x6c, 0x75, 0x65, 0x3a, 0x02, 0x38, 0x01, 0x4a, 0x04, 0x08, - 0x1b, 0x10, 0x1c, 0x4a, 0x04, 0x08, 0x1d, 0x10, 0x1e, 0x4a, 0x04, 0x08, 0x32, 0x10, 0x33, 0x4a, - 0x04, 0x08, 0x33, 0x10, 0x34, 0x4a, 0x04, 0x08, 0x3c, 0x10, 0x3d, 0x22, 0x8f, 0x01, 0x0a, 0x0d, - 0x53, 0x74, 0x6f, 0x72, 0x61, 0x67, 0x65, 0x43, 0x68, 0x61, 0x6e, 0x67, 0x65, 0x12, 0x18, 0x0a, - 0x07, 0x61, 0x64, 0x64, 0x72, 0x65, 0x73, 0x73, 0x18, 0x01, 0x20, 0x01, 0x28, 0x0c, 0x52, 0x07, - 0x61, 0x64, 0x64, 0x72, 0x65, 0x73, 0x73, 0x12, 0x10, 0x0a, 0x03, 0x6b, 0x65, 0x79, 0x18, 0x02, - 0x20, 0x01, 0x28, 0x0c, 0x52, 0x03, 0x6b, 0x65, 0x79, 0x12, 0x1b, 0x0a, 0x09, 0x6f, 0x6c, 0x64, - 0x5f, 0x76, 0x61, 0x6c, 0x75, 0x65, 0x18, 0x03, 0x20, 0x01, 0x28, 0x0c, 0x52, 0x08, 0x6f, 0x6c, - 0x64, 0x56, 0x61, 0x6c, 0x75, 0x65, 0x12, 0x1b, 0x0a, 0x09, 0x6e, 0x65, 0x77, 0x5f, 0x76, 0x61, - 0x6c, 0x75, 0x65, 0x18, 0x04, 0x20, 0x01, 0x28, 0x0c, 0x52, 0x08, 0x6e, 0x65, 0x77, 0x56, 0x61, - 0x6c, 0x75, 0x65, 0x12, 0x18, 0x0a, 0x07, 0x6f, 0x72, 0x64, 0x69, 0x6e, 0x61, 0x6c, 0x18, 0x05, - 0x20, 0x01, 0x28, 0x04, 0x52, 0x07, 0x6f, 0x72, 0x64, 0x69, 0x6e, 0x61, 0x6c, 0x22, 0x82, 0x06, - 0x0a, 0x0d, 0x42, 0x61, 0x6c, 0x61, 0x6e, 0x63, 0x65, 0x43, 0x68, 0x61, 0x6e, 0x67, 0x65, 0x12, - 0x18, 0x0a, 0x07, 0x61, 0x64, 0x64, 0x72, 0x65, 0x73, 0x73, 0x18, 0x01, 0x20, 0x01, 0x28, 0x0c, - 0x52, 0x07, 0x61, 0x64, 0x64, 0x72, 0x65, 0x73, 0x73, 0x12, 0x38, 0x0a, 0x09, 0x6f, 0x6c, 0x64, - 0x5f, 0x76, 0x61, 0x6c, 0x75, 0x65, 0x18, 0x02, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x1b, 0x2e, 0x73, - 0x66, 0x2e, 0x65, 0x74, 0x68, 0x65, 0x72, 0x65, 0x75, 0x6d, 0x2e, 0x74, 0x79, 0x70, 0x65, 0x2e, - 0x76, 0x32, 0x2e, 0x42, 0x69, 0x67, 0x49, 0x6e, 0x74, 0x52, 0x08, 0x6f, 0x6c, 0x64, 0x56, 0x61, - 0x6c, 0x75, 0x65, 0x12, 0x38, 0x0a, 0x09, 0x6e, 0x65, 0x77, 0x5f, 0x76, 0x61, 0x6c, 0x75, 0x65, - 0x18, 0x03, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x1b, 0x2e, 0x73, 0x66, 0x2e, 0x65, 0x74, 0x68, 0x65, - 0x72, 0x65, 0x75, 0x6d, 0x2e, 0x74, 0x79, 0x70, 0x65, 0x2e, 0x76, 0x32, 0x2e, 0x42, 0x69, 0x67, - 0x49, 0x6e, 0x74, 0x52, 0x08, 0x6e, 0x65, 0x77, 0x56, 0x61, 0x6c, 0x75, 0x65, 0x12, 0x41, 0x0a, - 0x06, 0x72, 0x65, 0x61, 0x73, 0x6f, 0x6e, 0x18, 0x04, 0x20, 0x01, 0x28, 0x0e, 0x32, 0x29, 0x2e, - 0x73, 0x66, 0x2e, 0x65, 0x74, 0x68, 0x65, 0x72, 0x65, 0x75, 0x6d, 0x2e, 0x74, 0x79, 0x70, 0x65, - 0x2e, 0x76, 0x32, 0x2e, 0x42, 0x61, 0x6c, 0x61, 0x6e, 0x63, 0x65, 0x43, 0x68, 0x61, 0x6e, 0x67, - 0x65, 0x2e, 0x52, 0x65, 0x61, 0x73, 0x6f, 0x6e, 0x52, 0x06, 0x72, 0x65, 0x61, 0x73, 0x6f, 0x6e, - 0x12, 0x18, 0x0a, 0x07, 0x6f, 0x72, 0x64, 0x69, 0x6e, 0x61, 0x6c, 0x18, 0x05, 0x20, 0x01, 0x28, - 0x04, 0x52, 0x07, 0x6f, 0x72, 0x64, 0x69, 0x6e, 0x61, 0x6c, 0x22, 0x85, 0x04, 0x0a, 0x06, 0x52, - 0x65, 0x61, 0x73, 0x6f, 0x6e, 0x12, 0x12, 0x0a, 0x0e, 0x52, 0x45, 0x41, 0x53, 0x4f, 0x4e, 0x5f, - 0x55, 0x4e, 0x4b, 0x4e, 0x4f, 0x57, 0x4e, 0x10, 0x00, 0x12, 0x1c, 0x0a, 0x18, 0x52, 0x45, 0x41, - 0x53, 0x4f, 0x4e, 0x5f, 0x52, 0x45, 0x57, 0x41, 0x52, 0x44, 0x5f, 0x4d, 0x49, 0x4e, 0x45, 0x5f, - 0x55, 0x4e, 0x43, 0x4c, 0x45, 0x10, 0x01, 0x12, 0x1c, 0x0a, 0x18, 0x52, 0x45, 0x41, 0x53, 0x4f, - 0x4e, 0x5f, 0x52, 0x45, 0x57, 0x41, 0x52, 0x44, 0x5f, 0x4d, 0x49, 0x4e, 0x45, 0x5f, 0x42, 0x4c, - 0x4f, 0x43, 0x4b, 0x10, 0x02, 0x12, 0x1e, 0x0a, 0x1a, 0x52, 0x45, 0x41, 0x53, 0x4f, 0x4e, 0x5f, - 0x44, 0x41, 0x4f, 0x5f, 0x52, 0x45, 0x46, 0x55, 0x4e, 0x44, 0x5f, 0x43, 0x4f, 0x4e, 0x54, 0x52, - 0x41, 0x43, 0x54, 0x10, 0x03, 0x12, 0x1d, 0x0a, 0x19, 0x52, 0x45, 0x41, 0x53, 0x4f, 0x4e, 0x5f, - 0x44, 0x41, 0x4f, 0x5f, 0x41, 0x44, 0x4a, 0x55, 0x53, 0x54, 0x5f, 0x42, 0x41, 0x4c, 0x41, 0x4e, - 0x43, 0x45, 0x10, 0x04, 0x12, 0x13, 0x0a, 0x0f, 0x52, 0x45, 0x41, 0x53, 0x4f, 0x4e, 0x5f, 0x54, - 0x52, 0x41, 0x4e, 0x53, 0x46, 0x45, 0x52, 0x10, 0x05, 0x12, 0x1a, 0x0a, 0x16, 0x52, 0x45, 0x41, - 0x53, 0x4f, 0x4e, 0x5f, 0x47, 0x45, 0x4e, 0x45, 0x53, 0x49, 0x53, 0x5f, 0x42, 0x41, 0x4c, 0x41, - 0x4e, 0x43, 0x45, 0x10, 0x06, 0x12, 0x12, 0x0a, 0x0e, 0x52, 0x45, 0x41, 0x53, 0x4f, 0x4e, 0x5f, - 0x47, 0x41, 0x53, 0x5f, 0x42, 0x55, 0x59, 0x10, 0x07, 0x12, 0x21, 0x0a, 0x1d, 0x52, 0x45, 0x41, - 0x53, 0x4f, 0x4e, 0x5f, 0x52, 0x45, 0x57, 0x41, 0x52, 0x44, 0x5f, 0x54, 0x52, 0x41, 0x4e, 0x53, - 0x41, 0x43, 0x54, 0x49, 0x4f, 0x4e, 0x5f, 0x46, 0x45, 0x45, 0x10, 0x08, 0x12, 0x1b, 0x0a, 0x17, - 0x52, 0x45, 0x41, 0x53, 0x4f, 0x4e, 0x5f, 0x52, 0x45, 0x57, 0x41, 0x52, 0x44, 0x5f, 0x46, 0x45, - 0x45, 0x5f, 0x52, 0x45, 0x53, 0x45, 0x54, 0x10, 0x0e, 0x12, 0x15, 0x0a, 0x11, 0x52, 0x45, 0x41, - 0x53, 0x4f, 0x4e, 0x5f, 0x47, 0x41, 0x53, 0x5f, 0x52, 0x45, 0x46, 0x55, 0x4e, 0x44, 0x10, 0x09, - 0x12, 0x18, 0x0a, 0x14, 0x52, 0x45, 0x41, 0x53, 0x4f, 0x4e, 0x5f, 0x54, 0x4f, 0x55, 0x43, 0x48, - 0x5f, 0x41, 0x43, 0x43, 0x4f, 0x55, 0x4e, 0x54, 0x10, 0x0a, 0x12, 0x19, 0x0a, 0x15, 0x52, 0x45, - 0x41, 0x53, 0x4f, 0x4e, 0x5f, 0x53, 0x55, 0x49, 0x43, 0x49, 0x44, 0x45, 0x5f, 0x52, 0x45, 0x46, - 0x55, 0x4e, 0x44, 0x10, 0x0b, 0x12, 0x1b, 0x0a, 0x17, 0x52, 0x45, 0x41, 0x53, 0x4f, 0x4e, 0x5f, - 0x53, 0x55, 0x49, 0x43, 0x49, 0x44, 0x45, 0x5f, 0x57, 0x49, 0x54, 0x48, 0x44, 0x52, 0x41, 0x57, - 0x10, 0x0d, 0x12, 0x20, 0x0a, 0x1c, 0x52, 0x45, 0x41, 0x53, 0x4f, 0x4e, 0x5f, 0x43, 0x41, 0x4c, - 0x4c, 0x5f, 0x42, 0x41, 0x4c, 0x41, 0x4e, 0x43, 0x45, 0x5f, 0x4f, 0x56, 0x45, 0x52, 0x52, 0x49, - 0x44, 0x45, 0x10, 0x0c, 0x12, 0x0f, 0x0a, 0x0b, 0x52, 0x45, 0x41, 0x53, 0x4f, 0x4e, 0x5f, 0x42, - 0x55, 0x52, 0x4e, 0x10, 0x0f, 0x12, 0x15, 0x0a, 0x11, 0x52, 0x45, 0x41, 0x53, 0x4f, 0x4e, 0x5f, - 0x57, 0x49, 0x54, 0x48, 0x44, 0x52, 0x41, 0x57, 0x41, 0x4c, 0x10, 0x10, 0x12, 0x1a, 0x0a, 0x16, - 0x52, 0x45, 0x41, 0x53, 0x4f, 0x4e, 0x5f, 0x52, 0x45, 0x57, 0x41, 0x52, 0x44, 0x5f, 0x42, 0x4c, - 0x4f, 0x42, 0x5f, 0x46, 0x45, 0x45, 0x10, 0x11, 0x12, 0x18, 0x0a, 0x14, 0x52, 0x45, 0x41, 0x53, - 0x4f, 0x4e, 0x5f, 0x49, 0x4e, 0x43, 0x52, 0x45, 0x41, 0x53, 0x45, 0x5f, 0x4d, 0x49, 0x4e, 0x54, - 0x10, 0x12, 0x22, 0x7b, 0x0a, 0x0b, 0x4e, 0x6f, 0x6e, 0x63, 0x65, 0x43, 0x68, 0x61, 0x6e, 0x67, - 0x65, 0x12, 0x18, 0x0a, 0x07, 0x61, 0x64, 0x64, 0x72, 0x65, 0x73, 0x73, 0x18, 0x01, 0x20, 0x01, - 0x28, 0x0c, 0x52, 0x07, 0x61, 0x64, 0x64, 0x72, 0x65, 0x73, 0x73, 0x12, 0x1b, 0x0a, 0x09, 0x6f, - 0x6c, 0x64, 0x5f, 0x76, 0x61, 0x6c, 0x75, 0x65, 0x18, 0x02, 0x20, 0x01, 0x28, 0x04, 0x52, 0x08, - 0x6f, 0x6c, 0x64, 0x56, 0x61, 0x6c, 0x75, 0x65, 0x12, 0x1b, 0x0a, 0x09, 0x6e, 0x65, 0x77, 0x5f, - 0x76, 0x61, 0x6c, 0x75, 0x65, 0x18, 0x03, 0x20, 0x01, 0x28, 0x04, 0x52, 0x08, 0x6e, 0x65, 0x77, - 0x56, 0x61, 0x6c, 0x75, 0x65, 0x12, 0x18, 0x0a, 0x07, 0x6f, 0x72, 0x64, 0x69, 0x6e, 0x61, 0x6c, - 0x18, 0x04, 0x20, 0x01, 0x28, 0x04, 0x52, 0x07, 0x6f, 0x72, 0x64, 0x69, 0x6e, 0x61, 0x6c, 0x22, - 0x45, 0x0a, 0x0f, 0x41, 0x63, 0x63, 0x6f, 0x75, 0x6e, 0x74, 0x43, 0x72, 0x65, 0x61, 0x74, 0x69, - 0x6f, 0x6e, 0x12, 0x18, 0x0a, 0x07, 0x61, 0x63, 0x63, 0x6f, 0x75, 0x6e, 0x74, 0x18, 0x01, 0x20, - 0x01, 0x28, 0x0c, 0x52, 0x07, 0x61, 0x63, 0x63, 0x6f, 0x75, 0x6e, 0x74, 0x12, 0x18, 0x0a, 0x07, - 0x6f, 0x72, 0x64, 0x69, 0x6e, 0x61, 0x6c, 0x18, 0x02, 0x20, 0x01, 0x28, 0x04, 0x52, 0x07, 0x6f, - 0x72, 0x64, 0x69, 0x6e, 0x61, 0x6c, 0x22, 0xac, 0x01, 0x0a, 0x0a, 0x43, 0x6f, 0x64, 0x65, 0x43, - 0x68, 0x61, 0x6e, 0x67, 0x65, 0x12, 0x18, 0x0a, 0x07, 0x61, 0x64, 0x64, 0x72, 0x65, 0x73, 0x73, - 0x18, 0x01, 0x20, 0x01, 0x28, 0x0c, 0x52, 0x07, 0x61, 0x64, 0x64, 0x72, 0x65, 0x73, 0x73, 0x12, - 0x19, 0x0a, 0x08, 0x6f, 0x6c, 0x64, 0x5f, 0x68, 0x61, 0x73, 0x68, 0x18, 0x02, 0x20, 0x01, 0x28, - 0x0c, 0x52, 0x07, 0x6f, 0x6c, 0x64, 0x48, 0x61, 0x73, 0x68, 0x12, 0x19, 0x0a, 0x08, 0x6f, 0x6c, - 0x64, 0x5f, 0x63, 0x6f, 0x64, 0x65, 0x18, 0x03, 0x20, 0x01, 0x28, 0x0c, 0x52, 0x07, 0x6f, 0x6c, - 0x64, 0x43, 0x6f, 0x64, 0x65, 0x12, 0x19, 0x0a, 0x08, 0x6e, 0x65, 0x77, 0x5f, 0x68, 0x61, 0x73, - 0x68, 0x18, 0x04, 0x20, 0x01, 0x28, 0x0c, 0x52, 0x07, 0x6e, 0x65, 0x77, 0x48, 0x61, 0x73, 0x68, - 0x12, 0x19, 0x0a, 0x08, 0x6e, 0x65, 0x77, 0x5f, 0x63, 0x6f, 0x64, 0x65, 0x18, 0x05, 0x20, 0x01, - 0x28, 0x0c, 0x52, 0x07, 0x6e, 0x65, 0x77, 0x43, 0x6f, 0x64, 0x65, 0x12, 0x18, 0x0a, 0x07, 0x6f, - 0x72, 0x64, 0x69, 0x6e, 0x61, 0x6c, 0x18, 0x06, 0x20, 0x01, 0x28, 0x04, 0x52, 0x07, 0x6f, 0x72, - 0x64, 0x69, 0x6e, 0x61, 0x6c, 0x22, 0x8e, 0x08, 0x0a, 0x09, 0x47, 0x61, 0x73, 0x43, 0x68, 0x61, - 0x6e, 0x67, 0x65, 0x12, 0x1b, 0x0a, 0x09, 0x6f, 0x6c, 0x64, 0x5f, 0x76, 0x61, 0x6c, 0x75, 0x65, - 0x18, 0x01, 0x20, 0x01, 0x28, 0x04, 0x52, 0x08, 0x6f, 0x6c, 0x64, 0x56, 0x61, 0x6c, 0x75, 0x65, - 0x12, 0x1b, 0x0a, 0x09, 0x6e, 0x65, 0x77, 0x5f, 0x76, 0x61, 0x6c, 0x75, 0x65, 0x18, 0x02, 0x20, - 0x01, 0x28, 0x04, 0x52, 0x08, 0x6e, 0x65, 0x77, 0x56, 0x61, 0x6c, 0x75, 0x65, 0x12, 0x3d, 0x0a, - 0x06, 0x72, 0x65, 0x61, 0x73, 0x6f, 0x6e, 0x18, 0x03, 0x20, 0x01, 0x28, 0x0e, 0x32, 0x25, 0x2e, - 0x73, 0x66, 0x2e, 0x65, 0x74, 0x68, 0x65, 0x72, 0x65, 0x75, 0x6d, 0x2e, 0x74, 0x79, 0x70, 0x65, - 0x2e, 0x76, 0x32, 0x2e, 0x47, 0x61, 0x73, 0x43, 0x68, 0x61, 0x6e, 0x67, 0x65, 0x2e, 0x52, 0x65, - 0x61, 0x73, 0x6f, 0x6e, 0x52, 0x06, 0x72, 0x65, 0x61, 0x73, 0x6f, 0x6e, 0x12, 0x18, 0x0a, 0x07, - 0x6f, 0x72, 0x64, 0x69, 0x6e, 0x61, 0x6c, 0x18, 0x04, 0x20, 0x01, 0x28, 0x04, 0x52, 0x07, 0x6f, - 0x72, 0x64, 0x69, 0x6e, 0x61, 0x6c, 0x22, 0xed, 0x06, 0x0a, 0x06, 0x52, 0x65, 0x61, 0x73, 0x6f, - 0x6e, 0x12, 0x12, 0x0a, 0x0e, 0x52, 0x45, 0x41, 0x53, 0x4f, 0x4e, 0x5f, 0x55, 0x4e, 0x4b, 0x4e, - 0x4f, 0x57, 0x4e, 0x10, 0x00, 0x12, 0x0f, 0x0a, 0x0b, 0x52, 0x45, 0x41, 0x53, 0x4f, 0x4e, 0x5f, - 0x43, 0x41, 0x4c, 0x4c, 0x10, 0x01, 0x12, 0x14, 0x0a, 0x10, 0x52, 0x45, 0x41, 0x53, 0x4f, 0x4e, - 0x5f, 0x43, 0x41, 0x4c, 0x4c, 0x5f, 0x43, 0x4f, 0x44, 0x45, 0x10, 0x02, 0x12, 0x19, 0x0a, 0x15, - 0x52, 0x45, 0x41, 0x53, 0x4f, 0x4e, 0x5f, 0x43, 0x41, 0x4c, 0x4c, 0x5f, 0x44, 0x41, 0x54, 0x41, - 0x5f, 0x43, 0x4f, 0x50, 0x59, 0x10, 0x03, 0x12, 0x14, 0x0a, 0x10, 0x52, 0x45, 0x41, 0x53, 0x4f, - 0x4e, 0x5f, 0x43, 0x4f, 0x44, 0x45, 0x5f, 0x43, 0x4f, 0x50, 0x59, 0x10, 0x04, 0x12, 0x17, 0x0a, - 0x13, 0x52, 0x45, 0x41, 0x53, 0x4f, 0x4e, 0x5f, 0x43, 0x4f, 0x44, 0x45, 0x5f, 0x53, 0x54, 0x4f, - 0x52, 0x41, 0x47, 0x45, 0x10, 0x05, 0x12, 0x1c, 0x0a, 0x18, 0x52, 0x45, 0x41, 0x53, 0x4f, 0x4e, - 0x5f, 0x43, 0x4f, 0x4e, 0x54, 0x52, 0x41, 0x43, 0x54, 0x5f, 0x43, 0x52, 0x45, 0x41, 0x54, 0x49, - 0x4f, 0x4e, 0x10, 0x06, 0x12, 0x1d, 0x0a, 0x19, 0x52, 0x45, 0x41, 0x53, 0x4f, 0x4e, 0x5f, 0x43, - 0x4f, 0x4e, 0x54, 0x52, 0x41, 0x43, 0x54, 0x5f, 0x43, 0x52, 0x45, 0x41, 0x54, 0x49, 0x4f, 0x4e, - 0x32, 0x10, 0x07, 0x12, 0x18, 0x0a, 0x14, 0x52, 0x45, 0x41, 0x53, 0x4f, 0x4e, 0x5f, 0x44, 0x45, - 0x4c, 0x45, 0x47, 0x41, 0x54, 0x45, 0x5f, 0x43, 0x41, 0x4c, 0x4c, 0x10, 0x08, 0x12, 0x14, 0x0a, - 0x10, 0x52, 0x45, 0x41, 0x53, 0x4f, 0x4e, 0x5f, 0x45, 0x56, 0x45, 0x4e, 0x54, 0x5f, 0x4c, 0x4f, - 0x47, 0x10, 0x09, 0x12, 0x18, 0x0a, 0x14, 0x52, 0x45, 0x41, 0x53, 0x4f, 0x4e, 0x5f, 0x45, 0x58, - 0x54, 0x5f, 0x43, 0x4f, 0x44, 0x45, 0x5f, 0x43, 0x4f, 0x50, 0x59, 0x10, 0x0a, 0x12, 0x1b, 0x0a, - 0x17, 0x52, 0x45, 0x41, 0x53, 0x4f, 0x4e, 0x5f, 0x46, 0x41, 0x49, 0x4c, 0x45, 0x44, 0x5f, 0x45, - 0x58, 0x45, 0x43, 0x55, 0x54, 0x49, 0x4f, 0x4e, 0x10, 0x0b, 0x12, 0x18, 0x0a, 0x14, 0x52, 0x45, - 0x41, 0x53, 0x4f, 0x4e, 0x5f, 0x49, 0x4e, 0x54, 0x52, 0x49, 0x4e, 0x53, 0x49, 0x43, 0x5f, 0x47, - 0x41, 0x53, 0x10, 0x0c, 0x12, 0x1f, 0x0a, 0x1b, 0x52, 0x45, 0x41, 0x53, 0x4f, 0x4e, 0x5f, 0x50, - 0x52, 0x45, 0x43, 0x4f, 0x4d, 0x50, 0x49, 0x4c, 0x45, 0x44, 0x5f, 0x43, 0x4f, 0x4e, 0x54, 0x52, - 0x41, 0x43, 0x54, 0x10, 0x0d, 0x12, 0x21, 0x0a, 0x1d, 0x52, 0x45, 0x41, 0x53, 0x4f, 0x4e, 0x5f, - 0x52, 0x45, 0x46, 0x55, 0x4e, 0x44, 0x5f, 0x41, 0x46, 0x54, 0x45, 0x52, 0x5f, 0x45, 0x58, 0x45, - 0x43, 0x55, 0x54, 0x49, 0x4f, 0x4e, 0x10, 0x0e, 0x12, 0x11, 0x0a, 0x0d, 0x52, 0x45, 0x41, 0x53, - 0x4f, 0x4e, 0x5f, 0x52, 0x45, 0x54, 0x55, 0x52, 0x4e, 0x10, 0x0f, 0x12, 0x1b, 0x0a, 0x17, 0x52, - 0x45, 0x41, 0x53, 0x4f, 0x4e, 0x5f, 0x52, 0x45, 0x54, 0x55, 0x52, 0x4e, 0x5f, 0x44, 0x41, 0x54, - 0x41, 0x5f, 0x43, 0x4f, 0x50, 0x59, 0x10, 0x10, 0x12, 0x11, 0x0a, 0x0d, 0x52, 0x45, 0x41, 0x53, - 0x4f, 0x4e, 0x5f, 0x52, 0x45, 0x56, 0x45, 0x52, 0x54, 0x10, 0x11, 0x12, 0x18, 0x0a, 0x14, 0x52, - 0x45, 0x41, 0x53, 0x4f, 0x4e, 0x5f, 0x53, 0x45, 0x4c, 0x46, 0x5f, 0x44, 0x45, 0x53, 0x54, 0x52, - 0x55, 0x43, 0x54, 0x10, 0x12, 0x12, 0x16, 0x0a, 0x12, 0x52, 0x45, 0x41, 0x53, 0x4f, 0x4e, 0x5f, - 0x53, 0x54, 0x41, 0x54, 0x49, 0x43, 0x5f, 0x43, 0x41, 0x4c, 0x4c, 0x10, 0x13, 0x12, 0x1c, 0x0a, - 0x18, 0x52, 0x45, 0x41, 0x53, 0x4f, 0x4e, 0x5f, 0x53, 0x54, 0x41, 0x54, 0x45, 0x5f, 0x43, 0x4f, - 0x4c, 0x44, 0x5f, 0x41, 0x43, 0x43, 0x45, 0x53, 0x53, 0x10, 0x14, 0x12, 0x1d, 0x0a, 0x19, 0x52, - 0x45, 0x41, 0x53, 0x4f, 0x4e, 0x5f, 0x54, 0x58, 0x5f, 0x49, 0x4e, 0x49, 0x54, 0x49, 0x41, 0x4c, - 0x5f, 0x42, 0x41, 0x4c, 0x41, 0x4e, 0x43, 0x45, 0x10, 0x15, 0x12, 0x15, 0x0a, 0x11, 0x52, 0x45, - 0x41, 0x53, 0x4f, 0x4e, 0x5f, 0x54, 0x58, 0x5f, 0x52, 0x45, 0x46, 0x55, 0x4e, 0x44, 0x53, 0x10, - 0x16, 0x12, 0x20, 0x0a, 0x1c, 0x52, 0x45, 0x41, 0x53, 0x4f, 0x4e, 0x5f, 0x54, 0x58, 0x5f, 0x4c, - 0x45, 0x46, 0x54, 0x5f, 0x4f, 0x56, 0x45, 0x52, 0x5f, 0x52, 0x45, 0x54, 0x55, 0x52, 0x4e, 0x45, - 0x44, 0x10, 0x17, 0x12, 0x1f, 0x0a, 0x1b, 0x52, 0x45, 0x41, 0x53, 0x4f, 0x4e, 0x5f, 0x43, 0x41, - 0x4c, 0x4c, 0x5f, 0x49, 0x4e, 0x49, 0x54, 0x49, 0x41, 0x4c, 0x5f, 0x42, 0x41, 0x4c, 0x41, 0x4e, - 0x43, 0x45, 0x10, 0x18, 0x12, 0x22, 0x0a, 0x1e, 0x52, 0x45, 0x41, 0x53, 0x4f, 0x4e, 0x5f, 0x43, - 0x41, 0x4c, 0x4c, 0x5f, 0x4c, 0x45, 0x46, 0x54, 0x5f, 0x4f, 0x56, 0x45, 0x52, 0x5f, 0x52, 0x45, - 0x54, 0x55, 0x52, 0x4e, 0x45, 0x44, 0x10, 0x19, 0x12, 0x20, 0x0a, 0x1c, 0x52, 0x45, 0x41, 0x53, - 0x4f, 0x4e, 0x5f, 0x57, 0x49, 0x54, 0x4e, 0x45, 0x53, 0x53, 0x5f, 0x43, 0x4f, 0x4e, 0x54, 0x52, - 0x41, 0x43, 0x54, 0x5f, 0x49, 0x4e, 0x49, 0x54, 0x10, 0x1a, 0x12, 0x24, 0x0a, 0x20, 0x52, 0x45, - 0x41, 0x53, 0x4f, 0x4e, 0x5f, 0x57, 0x49, 0x54, 0x4e, 0x45, 0x53, 0x53, 0x5f, 0x43, 0x4f, 0x4e, - 0x54, 0x52, 0x41, 0x43, 0x54, 0x5f, 0x43, 0x52, 0x45, 0x41, 0x54, 0x49, 0x4f, 0x4e, 0x10, 0x1b, - 0x12, 0x1d, 0x0a, 0x19, 0x52, 0x45, 0x41, 0x53, 0x4f, 0x4e, 0x5f, 0x57, 0x49, 0x54, 0x4e, 0x45, - 0x53, 0x53, 0x5f, 0x43, 0x4f, 0x44, 0x45, 0x5f, 0x43, 0x48, 0x55, 0x4e, 0x4b, 0x10, 0x1c, 0x12, - 0x2b, 0x0a, 0x27, 0x52, 0x45, 0x41, 0x53, 0x4f, 0x4e, 0x5f, 0x57, 0x49, 0x54, 0x4e, 0x45, 0x53, - 0x53, 0x5f, 0x43, 0x4f, 0x4e, 0x54, 0x52, 0x41, 0x43, 0x54, 0x5f, 0x43, 0x4f, 0x4c, 0x4c, 0x49, - 0x53, 0x49, 0x4f, 0x4e, 0x5f, 0x43, 0x48, 0x45, 0x43, 0x4b, 0x10, 0x1d, 0x12, 0x18, 0x0a, 0x14, - 0x52, 0x45, 0x41, 0x53, 0x4f, 0x4e, 0x5f, 0x54, 0x58, 0x5f, 0x44, 0x41, 0x54, 0x41, 0x5f, 0x46, - 0x4c, 0x4f, 0x4f, 0x52, 0x10, 0x1e, 0x22, 0x4b, 0x0a, 0x0f, 0x48, 0x65, 0x61, 0x64, 0x65, 0x72, - 0x4f, 0x6e, 0x6c, 0x79, 0x42, 0x6c, 0x6f, 0x63, 0x6b, 0x12, 0x38, 0x0a, 0x06, 0x68, 0x65, 0x61, - 0x64, 0x65, 0x72, 0x18, 0x05, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x20, 0x2e, 0x73, 0x66, 0x2e, 0x65, - 0x74, 0x68, 0x65, 0x72, 0x65, 0x75, 0x6d, 0x2e, 0x74, 0x79, 0x70, 0x65, 0x2e, 0x76, 0x32, 0x2e, - 0x42, 0x6c, 0x6f, 0x63, 0x6b, 0x48, 0x65, 0x61, 0x64, 0x65, 0x72, 0x52, 0x06, 0x68, 0x65, 0x61, - 0x64, 0x65, 0x72, 0x22, 0xd1, 0x01, 0x0a, 0x0d, 0x42, 0x6c, 0x6f, 0x63, 0x6b, 0x57, 0x69, 0x74, - 0x68, 0x52, 0x65, 0x66, 0x73, 0x12, 0x0e, 0x0a, 0x02, 0x69, 0x64, 0x18, 0x01, 0x20, 0x01, 0x28, - 0x09, 0x52, 0x02, 0x69, 0x64, 0x12, 0x30, 0x0a, 0x05, 0x62, 0x6c, 0x6f, 0x63, 0x6b, 0x18, 0x02, - 0x20, 0x01, 0x28, 0x0b, 0x32, 0x1a, 0x2e, 0x73, 0x66, 0x2e, 0x65, 0x74, 0x68, 0x65, 0x72, 0x65, - 0x75, 0x6d, 0x2e, 0x74, 0x79, 0x70, 0x65, 0x2e, 0x76, 0x32, 0x2e, 0x42, 0x6c, 0x6f, 0x63, 0x6b, - 0x52, 0x05, 0x62, 0x6c, 0x6f, 0x63, 0x6b, 0x12, 0x5a, 0x0a, 0x16, 0x74, 0x72, 0x61, 0x6e, 0x73, - 0x61, 0x63, 0x74, 0x69, 0x6f, 0x6e, 0x5f, 0x74, 0x72, 0x61, 0x63, 0x65, 0x5f, 0x72, 0x65, 0x66, - 0x73, 0x18, 0x03, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x24, 0x2e, 0x73, 0x66, 0x2e, 0x65, 0x74, 0x68, - 0x65, 0x72, 0x65, 0x75, 0x6d, 0x2e, 0x74, 0x79, 0x70, 0x65, 0x2e, 0x76, 0x32, 0x2e, 0x54, 0x72, - 0x61, 0x6e, 0x73, 0x61, 0x63, 0x74, 0x69, 0x6f, 0x6e, 0x52, 0x65, 0x66, 0x73, 0x52, 0x14, 0x74, - 0x72, 0x61, 0x6e, 0x73, 0x61, 0x63, 0x74, 0x69, 0x6f, 0x6e, 0x54, 0x72, 0x61, 0x63, 0x65, 0x52, - 0x65, 0x66, 0x73, 0x12, 0x22, 0x0a, 0x0c, 0x69, 0x72, 0x72, 0x65, 0x76, 0x65, 0x72, 0x73, 0x69, - 0x62, 0x6c, 0x65, 0x18, 0x04, 0x20, 0x01, 0x28, 0x08, 0x52, 0x0c, 0x69, 0x72, 0x72, 0x65, 0x76, - 0x65, 0x72, 0x73, 0x69, 0x62, 0x6c, 0x65, 0x22, 0x97, 0x01, 0x0a, 0x1c, 0x54, 0x72, 0x61, 0x6e, - 0x73, 0x61, 0x63, 0x74, 0x69, 0x6f, 0x6e, 0x54, 0x72, 0x61, 0x63, 0x65, 0x57, 0x69, 0x74, 0x68, - 0x42, 0x6c, 0x6f, 0x63, 0x6b, 0x52, 0x65, 0x66, 0x12, 0x3b, 0x0a, 0x05, 0x74, 0x72, 0x61, 0x63, - 0x65, 0x18, 0x01, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x25, 0x2e, 0x73, 0x66, 0x2e, 0x65, 0x74, 0x68, - 0x65, 0x72, 0x65, 0x75, 0x6d, 0x2e, 0x74, 0x79, 0x70, 0x65, 0x2e, 0x76, 0x32, 0x2e, 0x54, 0x72, - 0x61, 0x6e, 0x73, 0x61, 0x63, 0x74, 0x69, 0x6f, 0x6e, 0x54, 0x72, 0x61, 0x63, 0x65, 0x52, 0x05, - 0x74, 0x72, 0x61, 0x63, 0x65, 0x12, 0x3a, 0x0a, 0x09, 0x62, 0x6c, 0x6f, 0x63, 0x6b, 0x5f, 0x72, - 0x65, 0x66, 0x18, 0x02, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x1d, 0x2e, 0x73, 0x66, 0x2e, 0x65, 0x74, - 0x68, 0x65, 0x72, 0x65, 0x75, 0x6d, 0x2e, 0x74, 0x79, 0x70, 0x65, 0x2e, 0x76, 0x32, 0x2e, 0x42, - 0x6c, 0x6f, 0x63, 0x6b, 0x52, 0x65, 0x66, 0x52, 0x08, 0x62, 0x6c, 0x6f, 0x63, 0x6b, 0x52, 0x65, - 0x66, 0x22, 0x29, 0x0a, 0x0f, 0x54, 0x72, 0x61, 0x6e, 0x73, 0x61, 0x63, 0x74, 0x69, 0x6f, 0x6e, - 0x52, 0x65, 0x66, 0x73, 0x12, 0x16, 0x0a, 0x06, 0x68, 0x61, 0x73, 0x68, 0x65, 0x73, 0x18, 0x01, - 0x20, 0x03, 0x28, 0x0c, 0x52, 0x06, 0x68, 0x61, 0x73, 0x68, 0x65, 0x73, 0x22, 0x36, 0x0a, 0x08, - 0x42, 0x6c, 0x6f, 0x63, 0x6b, 0x52, 0x65, 0x66, 0x12, 0x12, 0x0a, 0x04, 0x68, 0x61, 0x73, 0x68, - 0x18, 0x01, 0x20, 0x01, 0x28, 0x0c, 0x52, 0x04, 0x68, 0x61, 0x73, 0x68, 0x12, 0x16, 0x0a, 0x06, - 0x6e, 0x75, 0x6d, 0x62, 0x65, 0x72, 0x18, 0x02, 0x20, 0x01, 0x28, 0x04, 0x52, 0x06, 0x6e, 0x75, - 0x6d, 0x62, 0x65, 0x72, 0x2a, 0x4e, 0x0a, 0x16, 0x54, 0x72, 0x61, 0x6e, 0x73, 0x61, 0x63, 0x74, - 0x69, 0x6f, 0x6e, 0x54, 0x72, 0x61, 0x63, 0x65, 0x53, 0x74, 0x61, 0x74, 0x75, 0x73, 0x12, 0x0b, - 0x0a, 0x07, 0x55, 0x4e, 0x4b, 0x4e, 0x4f, 0x57, 0x4e, 0x10, 0x00, 0x12, 0x0d, 0x0a, 0x09, 0x53, - 0x55, 0x43, 0x43, 0x45, 0x45, 0x44, 0x45, 0x44, 0x10, 0x01, 0x12, 0x0a, 0x0a, 0x06, 0x46, 0x41, - 0x49, 0x4c, 0x45, 0x44, 0x10, 0x02, 0x12, 0x0c, 0x0a, 0x08, 0x52, 0x45, 0x56, 0x45, 0x52, 0x54, - 0x45, 0x44, 0x10, 0x03, 0x2a, 0x59, 0x0a, 0x08, 0x43, 0x61, 0x6c, 0x6c, 0x54, 0x79, 0x70, 0x65, - 0x12, 0x0f, 0x0a, 0x0b, 0x55, 0x4e, 0x53, 0x50, 0x45, 0x43, 0x49, 0x46, 0x49, 0x45, 0x44, 0x10, - 0x00, 0x12, 0x08, 0x0a, 0x04, 0x43, 0x41, 0x4c, 0x4c, 0x10, 0x01, 0x12, 0x0c, 0x0a, 0x08, 0x43, - 0x41, 0x4c, 0x4c, 0x43, 0x4f, 0x44, 0x45, 0x10, 0x02, 0x12, 0x0c, 0x0a, 0x08, 0x44, 0x45, 0x4c, - 0x45, 0x47, 0x41, 0x54, 0x45, 0x10, 0x03, 0x12, 0x0a, 0x0a, 0x06, 0x53, 0x54, 0x41, 0x54, 0x49, - 0x43, 0x10, 0x04, 0x12, 0x0a, 0x0a, 0x06, 0x43, 0x52, 0x45, 0x41, 0x54, 0x45, 0x10, 0x05, 0x42, - 0x4f, 0x5a, 0x4d, 0x67, 0x69, 0x74, 0x68, 0x75, 0x62, 0x2e, 0x63, 0x6f, 0x6d, 0x2f, 0x73, 0x74, - 0x72, 0x65, 0x61, 0x6d, 0x69, 0x6e, 0x67, 0x66, 0x61, 0x73, 0x74, 0x2f, 0x66, 0x69, 0x72, 0x65, - 0x68, 0x6f, 0x73, 0x65, 0x2d, 0x65, 0x74, 0x68, 0x65, 0x72, 0x65, 0x75, 0x6d, 0x2f, 0x74, 0x79, - 0x70, 0x65, 0x73, 0x2f, 0x70, 0x62, 0x2f, 0x73, 0x66, 0x2f, 0x65, 0x74, 0x68, 0x65, 0x72, 0x65, - 0x75, 0x6d, 0x2f, 0x74, 0x79, 0x70, 0x65, 0x2f, 0x76, 0x32, 0x3b, 0x70, 0x62, 0x65, 0x74, 0x68, - 0x62, 0x06, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x33, -}) - -var ( - file_sf_ethereum_type_v2_type_proto_rawDescOnce sync.Once - file_sf_ethereum_type_v2_type_proto_rawDescData []byte -) - -func file_sf_ethereum_type_v2_type_proto_rawDescGZIP() []byte { - file_sf_ethereum_type_v2_type_proto_rawDescOnce.Do(func() { - file_sf_ethereum_type_v2_type_proto_rawDescData = protoimpl.X.CompressGZIP(unsafe.Slice(unsafe.StringData(file_sf_ethereum_type_v2_type_proto_rawDesc), len(file_sf_ethereum_type_v2_type_proto_rawDesc))) - }) - return file_sf_ethereum_type_v2_type_proto_rawDescData -} - -var file_sf_ethereum_type_v2_type_proto_enumTypes = make([]protoimpl.EnumInfo, 6) -var file_sf_ethereum_type_v2_type_proto_msgTypes = make([]protoimpl.MessageInfo, 22) -var file_sf_ethereum_type_v2_type_proto_goTypes = []any{ - (TransactionTraceStatus)(0), // 0: sf.ethereum.type.v2.TransactionTraceStatus - (CallType)(0), // 1: sf.ethereum.type.v2.CallType - (Block_DetailLevel)(0), // 2: sf.ethereum.type.v2.Block.DetailLevel - (TransactionTrace_Type)(0), // 3: sf.ethereum.type.v2.TransactionTrace.Type - (BalanceChange_Reason)(0), // 4: sf.ethereum.type.v2.BalanceChange.Reason - (GasChange_Reason)(0), // 5: sf.ethereum.type.v2.GasChange.Reason - (*Block)(nil), // 6: sf.ethereum.type.v2.Block - (*BlockHeader)(nil), // 7: sf.ethereum.type.v2.BlockHeader - (*Uint64NestedArray)(nil), // 8: sf.ethereum.type.v2.Uint64NestedArray - (*Uint64Array)(nil), // 9: sf.ethereum.type.v2.Uint64Array - (*BigInt)(nil), // 10: sf.ethereum.type.v2.BigInt - (*TransactionTrace)(nil), // 11: sf.ethereum.type.v2.TransactionTrace - (*AccessTuple)(nil), // 12: sf.ethereum.type.v2.AccessTuple - (*TransactionReceipt)(nil), // 13: sf.ethereum.type.v2.TransactionReceipt - (*Log)(nil), // 14: sf.ethereum.type.v2.Log - (*Call)(nil), // 15: sf.ethereum.type.v2.Call - (*StorageChange)(nil), // 16: sf.ethereum.type.v2.StorageChange - (*BalanceChange)(nil), // 17: sf.ethereum.type.v2.BalanceChange - (*NonceChange)(nil), // 18: sf.ethereum.type.v2.NonceChange - (*AccountCreation)(nil), // 19: sf.ethereum.type.v2.AccountCreation - (*CodeChange)(nil), // 20: sf.ethereum.type.v2.CodeChange - (*GasChange)(nil), // 21: sf.ethereum.type.v2.GasChange - (*HeaderOnlyBlock)(nil), // 22: sf.ethereum.type.v2.HeaderOnlyBlock - (*BlockWithRefs)(nil), // 23: sf.ethereum.type.v2.BlockWithRefs - (*TransactionTraceWithBlockRef)(nil), // 24: sf.ethereum.type.v2.TransactionTraceWithBlockRef - (*TransactionRefs)(nil), // 25: sf.ethereum.type.v2.TransactionRefs - (*BlockRef)(nil), // 26: sf.ethereum.type.v2.BlockRef - nil, // 27: sf.ethereum.type.v2.Call.KeccakPreimagesEntry - (*timestamppb.Timestamp)(nil), // 28: google.protobuf.Timestamp -} -var file_sf_ethereum_type_v2_type_proto_depIdxs = []int32{ - 7, // 0: sf.ethereum.type.v2.Block.header:type_name -> sf.ethereum.type.v2.BlockHeader - 7, // 1: sf.ethereum.type.v2.Block.uncles:type_name -> sf.ethereum.type.v2.BlockHeader - 11, // 2: sf.ethereum.type.v2.Block.transaction_traces:type_name -> sf.ethereum.type.v2.TransactionTrace - 17, // 3: sf.ethereum.type.v2.Block.balance_changes:type_name -> sf.ethereum.type.v2.BalanceChange - 2, // 4: sf.ethereum.type.v2.Block.detail_level:type_name -> sf.ethereum.type.v2.Block.DetailLevel - 20, // 5: sf.ethereum.type.v2.Block.code_changes:type_name -> sf.ethereum.type.v2.CodeChange - 15, // 6: sf.ethereum.type.v2.Block.system_calls:type_name -> sf.ethereum.type.v2.Call - 10, // 7: sf.ethereum.type.v2.BlockHeader.difficulty:type_name -> sf.ethereum.type.v2.BigInt - 10, // 8: sf.ethereum.type.v2.BlockHeader.total_difficulty:type_name -> sf.ethereum.type.v2.BigInt - 28, // 9: sf.ethereum.type.v2.BlockHeader.timestamp:type_name -> google.protobuf.Timestamp - 10, // 10: sf.ethereum.type.v2.BlockHeader.base_fee_per_gas:type_name -> sf.ethereum.type.v2.BigInt - 8, // 11: sf.ethereum.type.v2.BlockHeader.tx_dependency:type_name -> sf.ethereum.type.v2.Uint64NestedArray - 9, // 12: sf.ethereum.type.v2.Uint64NestedArray.val:type_name -> sf.ethereum.type.v2.Uint64Array - 10, // 13: sf.ethereum.type.v2.TransactionTrace.gas_price:type_name -> sf.ethereum.type.v2.BigInt - 10, // 14: sf.ethereum.type.v2.TransactionTrace.value:type_name -> sf.ethereum.type.v2.BigInt - 3, // 15: sf.ethereum.type.v2.TransactionTrace.type:type_name -> sf.ethereum.type.v2.TransactionTrace.Type - 12, // 16: sf.ethereum.type.v2.TransactionTrace.access_list:type_name -> sf.ethereum.type.v2.AccessTuple - 10, // 17: sf.ethereum.type.v2.TransactionTrace.max_fee_per_gas:type_name -> sf.ethereum.type.v2.BigInt - 10, // 18: sf.ethereum.type.v2.TransactionTrace.max_priority_fee_per_gas:type_name -> sf.ethereum.type.v2.BigInt - 0, // 19: sf.ethereum.type.v2.TransactionTrace.status:type_name -> sf.ethereum.type.v2.TransactionTraceStatus - 13, // 20: sf.ethereum.type.v2.TransactionTrace.receipt:type_name -> sf.ethereum.type.v2.TransactionReceipt - 15, // 21: sf.ethereum.type.v2.TransactionTrace.calls:type_name -> sf.ethereum.type.v2.Call - 10, // 22: sf.ethereum.type.v2.TransactionTrace.blob_gas_fee_cap:type_name -> sf.ethereum.type.v2.BigInt - 14, // 23: sf.ethereum.type.v2.TransactionReceipt.logs:type_name -> sf.ethereum.type.v2.Log - 10, // 24: sf.ethereum.type.v2.TransactionReceipt.blob_gas_price:type_name -> sf.ethereum.type.v2.BigInt - 1, // 25: sf.ethereum.type.v2.Call.call_type:type_name -> sf.ethereum.type.v2.CallType - 10, // 26: sf.ethereum.type.v2.Call.value:type_name -> sf.ethereum.type.v2.BigInt - 27, // 27: sf.ethereum.type.v2.Call.keccak_preimages:type_name -> sf.ethereum.type.v2.Call.KeccakPreimagesEntry - 16, // 28: sf.ethereum.type.v2.Call.storage_changes:type_name -> sf.ethereum.type.v2.StorageChange - 17, // 29: sf.ethereum.type.v2.Call.balance_changes:type_name -> sf.ethereum.type.v2.BalanceChange - 18, // 30: sf.ethereum.type.v2.Call.nonce_changes:type_name -> sf.ethereum.type.v2.NonceChange - 14, // 31: sf.ethereum.type.v2.Call.logs:type_name -> sf.ethereum.type.v2.Log - 20, // 32: sf.ethereum.type.v2.Call.code_changes:type_name -> sf.ethereum.type.v2.CodeChange - 21, // 33: sf.ethereum.type.v2.Call.gas_changes:type_name -> sf.ethereum.type.v2.GasChange - 19, // 34: sf.ethereum.type.v2.Call.account_creations:type_name -> sf.ethereum.type.v2.AccountCreation - 10, // 35: sf.ethereum.type.v2.BalanceChange.old_value:type_name -> sf.ethereum.type.v2.BigInt - 10, // 36: sf.ethereum.type.v2.BalanceChange.new_value:type_name -> sf.ethereum.type.v2.BigInt - 4, // 37: sf.ethereum.type.v2.BalanceChange.reason:type_name -> sf.ethereum.type.v2.BalanceChange.Reason - 5, // 38: sf.ethereum.type.v2.GasChange.reason:type_name -> sf.ethereum.type.v2.GasChange.Reason - 7, // 39: sf.ethereum.type.v2.HeaderOnlyBlock.header:type_name -> sf.ethereum.type.v2.BlockHeader - 6, // 40: sf.ethereum.type.v2.BlockWithRefs.block:type_name -> sf.ethereum.type.v2.Block - 25, // 41: sf.ethereum.type.v2.BlockWithRefs.transaction_trace_refs:type_name -> sf.ethereum.type.v2.TransactionRefs - 11, // 42: sf.ethereum.type.v2.TransactionTraceWithBlockRef.trace:type_name -> sf.ethereum.type.v2.TransactionTrace - 26, // 43: sf.ethereum.type.v2.TransactionTraceWithBlockRef.block_ref:type_name -> sf.ethereum.type.v2.BlockRef - 44, // [44:44] is the sub-list for method output_type - 44, // [44:44] is the sub-list for method input_type - 44, // [44:44] is the sub-list for extension type_name - 44, // [44:44] is the sub-list for extension extendee - 0, // [0:44] is the sub-list for field type_name -} - -func init() { file_sf_ethereum_type_v2_type_proto_init() } -func file_sf_ethereum_type_v2_type_proto_init() { - if File_sf_ethereum_type_v2_type_proto != nil { - return - } - file_sf_ethereum_type_v2_type_proto_msgTypes[1].OneofWrappers = []any{} - file_sf_ethereum_type_v2_type_proto_msgTypes[5].OneofWrappers = []any{} - file_sf_ethereum_type_v2_type_proto_msgTypes[7].OneofWrappers = []any{} - type x struct{} - out := protoimpl.TypeBuilder{ - File: protoimpl.DescBuilder{ - GoPackagePath: reflect.TypeOf(x{}).PkgPath(), - RawDescriptor: unsafe.Slice(unsafe.StringData(file_sf_ethereum_type_v2_type_proto_rawDesc), len(file_sf_ethereum_type_v2_type_proto_rawDesc)), - NumEnums: 6, - NumMessages: 22, - NumExtensions: 0, - NumServices: 0, - }, - GoTypes: file_sf_ethereum_type_v2_type_proto_goTypes, - DependencyIndexes: file_sf_ethereum_type_v2_type_proto_depIdxs, - EnumInfos: file_sf_ethereum_type_v2_type_proto_enumTypes, - MessageInfos: file_sf_ethereum_type_v2_type_proto_msgTypes, - }.Build() - File_sf_ethereum_type_v2_type_proto = out.File - file_sf_ethereum_type_v2_type_proto_goTypes = nil - file_sf_ethereum_type_v2_type_proto_depIdxs = nil -}