diff --git a/blockchain/arbitrum_one/arbitrum_one.go b/blockchain/arbitrum_one/arbitrum_one.go index ed36ee7..d87cb06 100644 --- a/blockchain/arbitrum_one/arbitrum_one.go +++ b/blockchain/arbitrum_one/arbitrum_one.go @@ -662,19 +662,20 @@ func (c *Client) DecodeProtoEntireBlockToJson(rawData *bytes.Buffer) (*seer_comm return blocksBatchJson, nil } -func (c *Client) DecodeProtoEntireBlockToLabels(rawData *bytes.Buffer, abiMap map[string]map[string]*indexer.AbiEntry, threads int) ([]indexer.EventLabel, []indexer.TransactionLabel, error) { +func (c *Client) DecodeProtoEntireBlockToLabels(rawData *bytes.Buffer, abiMap map[string]map[string]*indexer.AbiEntry, threads int) ([]indexer.EventLabel, []indexer.TransactionLabel, []indexer.RawTransaction, error) { var protoBlocksBatch ArbitrumOneBlocksBatch dataBytes := rawData.Bytes() err := proto.Unmarshal(dataBytes, &protoBlocksBatch) if err != nil { - return nil, nil, fmt.Errorf("failed to unmarshal data: %v", err) + return nil, nil, nil, fmt.Errorf("failed to unmarshal data: %v", err) } // Shared slices to collect labels var labels []indexer.EventLabel var txLabels []indexer.TransactionLabel + var rawTransactions []indexer.RawTransaction var labelsMutex sync.Mutex var decodeErr error @@ -699,7 +700,7 @@ func (c *Client) DecodeProtoEntireBlockToLabels(rawData *bytes.Buffer, abiMap ma // Local slices to collect labels for this block var localEventLabels []indexer.EventLabel var localTxLabels []indexer.TransactionLabel - + localRawTransactions := make(map[string]indexer.RawTransaction) for _, tx := range b.Transactions { var decodedArgsTx map[string]interface{} @@ -767,6 +768,25 @@ func (c *Client) DecodeProtoEntireBlockToLabels(rawData *bytes.Buffer, abiMap ma continue } + localRawTransactions[tx.Hash] = indexer.RawTransaction{ + Hash: tx.Hash, + BlockHash: b.Hash, + BlockTimestamp: b.Timestamp, + BlockNumber: tx.BlockNumber, + FromAddress: tx.FromAddress, + ToAddress: tx.ToAddress, + Gas: tx.Gas, + GasPrice: tx.GasPrice, + Input: tx.Input, + Nonce: tx.Nonce, + MaxFeePerGas: tx.MaxFeePerGas, + MaxPriorityFeePerGas: tx.MaxPriorityFeePerGas, + TransactionIndex: tx.TransactionIndex, + TransactionType: tx.TransactionType, + Value: tx.Value, + L1BlockNumber: &b.L1BlockNumber, + } + // Convert transaction to label transactionLabel := indexer.TransactionLabel{ Address: tx.ToAddress, @@ -835,6 +855,26 @@ func (c *Client) DecodeProtoEntireBlockToLabels(rawData *bytes.Buffer, abiMap ma errorChan <- fmt.Errorf("error converting decodedArgsLogs to JSON for tx %s: %v", e.TransactionHash, err) continue } + if _, exists := localRawTransactions[e.TransactionHash]; !exists { + localRawTransactions[e.TransactionHash] = indexer.RawTransaction{ + Hash: tx.Hash, + BlockHash: b.Hash, + BlockTimestamp: b.Timestamp, + BlockNumber: tx.BlockNumber, + FromAddress: tx.FromAddress, + ToAddress: tx.ToAddress, + Gas: tx.Gas, + GasPrice: tx.GasPrice, + Input: tx.Input, + Nonce: tx.Nonce, + MaxFeePerGas: tx.MaxFeePerGas, + MaxPriorityFeePerGas: tx.MaxPriorityFeePerGas, + TransactionIndex: tx.TransactionIndex, + TransactionType: tx.TransactionType, + Value: tx.Value, + L1BlockNumber: &b.L1BlockNumber, + } + } // Convert event to label eventLabel := indexer.EventLabel{ Label: label, @@ -858,6 +898,9 @@ func (c *Client) DecodeProtoEntireBlockToLabels(rawData *bytes.Buffer, abiMap ma labelsMutex.Lock() labels = append(labels, localEventLabels...) txLabels = append(txLabels, localTxLabels...) + for _, rawTransaction := range localRawTransactions { + rawTransactions = append(rawTransactions, rawTransaction) + } labelsMutex.Unlock() }(b) } @@ -873,10 +916,10 @@ func (c *Client) DecodeProtoEntireBlockToLabels(rawData *bytes.Buffer, abiMap ma // If any errors occurred, return them if len(errorMessages) > 0 { - return nil, nil, fmt.Errorf("errors occurred during processing:\n%s", strings.Join(errorMessages, "\n")) + return nil, nil, nil, fmt.Errorf("errors occurred during processing:\n%s", strings.Join(errorMessages, "\n")) } - return labels, txLabels, nil + return labels, txLabels, rawTransactions, nil } func (c *Client) DecodeProtoTransactionsToLabels(transactions []string, blocksCache map[uint64]uint64, abiMap map[string]map[string]*indexer.AbiEntry) ([]indexer.TransactionLabel, error) { diff --git a/blockchain/arbitrum_sepolia/arbitrum_sepolia.go b/blockchain/arbitrum_sepolia/arbitrum_sepolia.go index eb23bee..eb4a6b0 100644 --- a/blockchain/arbitrum_sepolia/arbitrum_sepolia.go +++ b/blockchain/arbitrum_sepolia/arbitrum_sepolia.go @@ -662,19 +662,20 @@ func (c *Client) DecodeProtoEntireBlockToJson(rawData *bytes.Buffer) (*seer_comm return blocksBatchJson, nil } -func (c *Client) DecodeProtoEntireBlockToLabels(rawData *bytes.Buffer, abiMap map[string]map[string]*indexer.AbiEntry, threads int) ([]indexer.EventLabel, []indexer.TransactionLabel, error) { +func (c *Client) DecodeProtoEntireBlockToLabels(rawData *bytes.Buffer, abiMap map[string]map[string]*indexer.AbiEntry, threads int) ([]indexer.EventLabel, []indexer.TransactionLabel, []indexer.RawTransaction, error) { var protoBlocksBatch ArbitrumSepoliaBlocksBatch dataBytes := rawData.Bytes() err := proto.Unmarshal(dataBytes, &protoBlocksBatch) if err != nil { - return nil, nil, fmt.Errorf("failed to unmarshal data: %v", err) + return nil, nil, nil, fmt.Errorf("failed to unmarshal data: %v", err) } // Shared slices to collect labels var labels []indexer.EventLabel var txLabels []indexer.TransactionLabel + var rawTransactions []indexer.RawTransaction var labelsMutex sync.Mutex var decodeErr error @@ -699,7 +700,7 @@ func (c *Client) DecodeProtoEntireBlockToLabels(rawData *bytes.Buffer, abiMap ma // Local slices to collect labels for this block var localEventLabels []indexer.EventLabel var localTxLabels []indexer.TransactionLabel - + localRawTransactions := make(map[string]indexer.RawTransaction) for _, tx := range b.Transactions { var decodedArgsTx map[string]interface{} @@ -767,6 +768,25 @@ func (c *Client) DecodeProtoEntireBlockToLabels(rawData *bytes.Buffer, abiMap ma continue } + localRawTransactions[tx.Hash] = indexer.RawTransaction{ + Hash: tx.Hash, + BlockHash: b.Hash, + BlockTimestamp: b.Timestamp, + BlockNumber: tx.BlockNumber, + FromAddress: tx.FromAddress, + ToAddress: tx.ToAddress, + Gas: tx.Gas, + GasPrice: tx.GasPrice, + Input: tx.Input, + Nonce: tx.Nonce, + MaxFeePerGas: tx.MaxFeePerGas, + MaxPriorityFeePerGas: tx.MaxPriorityFeePerGas, + TransactionIndex: tx.TransactionIndex, + TransactionType: tx.TransactionType, + Value: tx.Value, + L1BlockNumber: &b.L1BlockNumber, + } + // Convert transaction to label transactionLabel := indexer.TransactionLabel{ Address: tx.ToAddress, @@ -835,6 +855,26 @@ func (c *Client) DecodeProtoEntireBlockToLabels(rawData *bytes.Buffer, abiMap ma errorChan <- fmt.Errorf("error converting decodedArgsLogs to JSON for tx %s: %v", e.TransactionHash, err) continue } + if _, exists := localRawTransactions[e.TransactionHash]; !exists { + localRawTransactions[e.TransactionHash] = indexer.RawTransaction{ + Hash: tx.Hash, + BlockHash: b.Hash, + BlockTimestamp: b.Timestamp, + BlockNumber: tx.BlockNumber, + FromAddress: tx.FromAddress, + ToAddress: tx.ToAddress, + Gas: tx.Gas, + GasPrice: tx.GasPrice, + Input: tx.Input, + Nonce: tx.Nonce, + MaxFeePerGas: tx.MaxFeePerGas, + MaxPriorityFeePerGas: tx.MaxPriorityFeePerGas, + TransactionIndex: tx.TransactionIndex, + TransactionType: tx.TransactionType, + Value: tx.Value, + L1BlockNumber: &b.L1BlockNumber, + } + } // Convert event to label eventLabel := indexer.EventLabel{ Label: label, @@ -858,6 +898,9 @@ func (c *Client) DecodeProtoEntireBlockToLabels(rawData *bytes.Buffer, abiMap ma labelsMutex.Lock() labels = append(labels, localEventLabels...) txLabels = append(txLabels, localTxLabels...) + for _, rawTransaction := range localRawTransactions { + rawTransactions = append(rawTransactions, rawTransaction) + } labelsMutex.Unlock() }(b) } @@ -873,10 +916,10 @@ func (c *Client) DecodeProtoEntireBlockToLabels(rawData *bytes.Buffer, abiMap ma // If any errors occurred, return them if len(errorMessages) > 0 { - return nil, nil, fmt.Errorf("errors occurred during processing:\n%s", strings.Join(errorMessages, "\n")) + return nil, nil, nil, fmt.Errorf("errors occurred during processing:\n%s", strings.Join(errorMessages, "\n")) } - return labels, txLabels, nil + return labels, txLabels, rawTransactions, nil } func (c *Client) DecodeProtoTransactionsToLabels(transactions []string, blocksCache map[uint64]uint64, abiMap map[string]map[string]*indexer.AbiEntry) ([]indexer.TransactionLabel, error) { diff --git a/blockchain/b3/b3.go b/blockchain/b3/b3.go index 81b0d88..1147234 100644 --- a/blockchain/b3/b3.go +++ b/blockchain/b3/b3.go @@ -652,19 +652,20 @@ func (c *Client) DecodeProtoEntireBlockToJson(rawData *bytes.Buffer) (*seer_comm return blocksBatchJson, nil } -func (c *Client) DecodeProtoEntireBlockToLabels(rawData *bytes.Buffer, abiMap map[string]map[string]*indexer.AbiEntry, threads int) ([]indexer.EventLabel, []indexer.TransactionLabel, error) { +func (c *Client) DecodeProtoEntireBlockToLabels(rawData *bytes.Buffer, abiMap map[string]map[string]*indexer.AbiEntry, threads int) ([]indexer.EventLabel, []indexer.TransactionLabel, []indexer.RawTransaction, error) { var protoBlocksBatch B3BlocksBatch dataBytes := rawData.Bytes() err := proto.Unmarshal(dataBytes, &protoBlocksBatch) if err != nil { - return nil, nil, fmt.Errorf("failed to unmarshal data: %v", err) + return nil, nil, nil, fmt.Errorf("failed to unmarshal data: %v", err) } // Shared slices to collect labels var labels []indexer.EventLabel var txLabels []indexer.TransactionLabel + var rawTransactions []indexer.RawTransaction var labelsMutex sync.Mutex var decodeErr error @@ -689,7 +690,7 @@ func (c *Client) DecodeProtoEntireBlockToLabels(rawData *bytes.Buffer, abiMap ma // Local slices to collect labels for this block var localEventLabels []indexer.EventLabel var localTxLabels []indexer.TransactionLabel - + localRawTransactions := make(map[string]indexer.RawTransaction) for _, tx := range b.Transactions { var decodedArgsTx map[string]interface{} @@ -757,6 +758,24 @@ func (c *Client) DecodeProtoEntireBlockToLabels(rawData *bytes.Buffer, abiMap ma continue } + localRawTransactions[tx.Hash] = indexer.RawTransaction{ + Hash: tx.Hash, + BlockHash: b.Hash, + BlockTimestamp: b.Timestamp, + BlockNumber: tx.BlockNumber, + FromAddress: tx.FromAddress, + ToAddress: tx.ToAddress, + Gas: tx.Gas, + GasPrice: tx.GasPrice, + Input: tx.Input, + Nonce: tx.Nonce, + MaxFeePerGas: tx.MaxFeePerGas, + MaxPriorityFeePerGas: tx.MaxPriorityFeePerGas, + TransactionIndex: tx.TransactionIndex, + TransactionType: tx.TransactionType, + Value: tx.Value, + } + // Convert transaction to label transactionLabel := indexer.TransactionLabel{ Address: tx.ToAddress, @@ -825,6 +844,25 @@ func (c *Client) DecodeProtoEntireBlockToLabels(rawData *bytes.Buffer, abiMap ma errorChan <- fmt.Errorf("error converting decodedArgsLogs to JSON for tx %s: %v", e.TransactionHash, err) continue } + if _, exists := localRawTransactions[e.TransactionHash]; !exists { + localRawTransactions[e.TransactionHash] = indexer.RawTransaction{ + Hash: tx.Hash, + BlockHash: b.Hash, + BlockTimestamp: b.Timestamp, + BlockNumber: tx.BlockNumber, + FromAddress: tx.FromAddress, + ToAddress: tx.ToAddress, + Gas: tx.Gas, + GasPrice: tx.GasPrice, + Input: tx.Input, + Nonce: tx.Nonce, + MaxFeePerGas: tx.MaxFeePerGas, + MaxPriorityFeePerGas: tx.MaxPriorityFeePerGas, + TransactionIndex: tx.TransactionIndex, + TransactionType: tx.TransactionType, + Value: tx.Value, + } + } // Convert event to label eventLabel := indexer.EventLabel{ Label: label, @@ -848,6 +886,9 @@ func (c *Client) DecodeProtoEntireBlockToLabels(rawData *bytes.Buffer, abiMap ma labelsMutex.Lock() labels = append(labels, localEventLabels...) txLabels = append(txLabels, localTxLabels...) + for _, rawTransaction := range localRawTransactions { + rawTransactions = append(rawTransactions, rawTransaction) + } labelsMutex.Unlock() }(b) } @@ -863,10 +904,10 @@ func (c *Client) DecodeProtoEntireBlockToLabels(rawData *bytes.Buffer, abiMap ma // If any errors occurred, return them if len(errorMessages) > 0 { - return nil, nil, fmt.Errorf("errors occurred during processing:\n%s", strings.Join(errorMessages, "\n")) + return nil, nil, nil, fmt.Errorf("errors occurred during processing:\n%s", strings.Join(errorMessages, "\n")) } - return labels, txLabels, nil + return labels, txLabels, rawTransactions, nil } func (c *Client) DecodeProtoTransactionsToLabels(transactions []string, blocksCache map[uint64]uint64, abiMap map[string]map[string]*indexer.AbiEntry) ([]indexer.TransactionLabel, error) { diff --git a/blockchain/b3_sepolia/b3_sepolia.go b/blockchain/b3_sepolia/b3_sepolia.go index 12df6fc..825a193 100644 --- a/blockchain/b3_sepolia/b3_sepolia.go +++ b/blockchain/b3_sepolia/b3_sepolia.go @@ -652,19 +652,20 @@ func (c *Client) DecodeProtoEntireBlockToJson(rawData *bytes.Buffer) (*seer_comm return blocksBatchJson, nil } -func (c *Client) DecodeProtoEntireBlockToLabels(rawData *bytes.Buffer, abiMap map[string]map[string]*indexer.AbiEntry, threads int) ([]indexer.EventLabel, []indexer.TransactionLabel, error) { +func (c *Client) DecodeProtoEntireBlockToLabels(rawData *bytes.Buffer, abiMap map[string]map[string]*indexer.AbiEntry, threads int) ([]indexer.EventLabel, []indexer.TransactionLabel, []indexer.RawTransaction, error) { var protoBlocksBatch B3SepoliaBlocksBatch dataBytes := rawData.Bytes() err := proto.Unmarshal(dataBytes, &protoBlocksBatch) if err != nil { - return nil, nil, fmt.Errorf("failed to unmarshal data: %v", err) + return nil, nil, nil, fmt.Errorf("failed to unmarshal data: %v", err) } // Shared slices to collect labels var labels []indexer.EventLabel var txLabels []indexer.TransactionLabel + var rawTransactions []indexer.RawTransaction var labelsMutex sync.Mutex var decodeErr error @@ -689,7 +690,7 @@ func (c *Client) DecodeProtoEntireBlockToLabels(rawData *bytes.Buffer, abiMap ma // Local slices to collect labels for this block var localEventLabels []indexer.EventLabel var localTxLabels []indexer.TransactionLabel - + localRawTransactions := make(map[string]indexer.RawTransaction) for _, tx := range b.Transactions { var decodedArgsTx map[string]interface{} @@ -757,6 +758,24 @@ func (c *Client) DecodeProtoEntireBlockToLabels(rawData *bytes.Buffer, abiMap ma continue } + localRawTransactions[tx.Hash] = indexer.RawTransaction{ + Hash: tx.Hash, + BlockHash: b.Hash, + BlockTimestamp: b.Timestamp, + BlockNumber: tx.BlockNumber, + FromAddress: tx.FromAddress, + ToAddress: tx.ToAddress, + Gas: tx.Gas, + GasPrice: tx.GasPrice, + Input: tx.Input, + Nonce: tx.Nonce, + MaxFeePerGas: tx.MaxFeePerGas, + MaxPriorityFeePerGas: tx.MaxPriorityFeePerGas, + TransactionIndex: tx.TransactionIndex, + TransactionType: tx.TransactionType, + Value: tx.Value, + } + // Convert transaction to label transactionLabel := indexer.TransactionLabel{ Address: tx.ToAddress, @@ -825,6 +844,25 @@ func (c *Client) DecodeProtoEntireBlockToLabels(rawData *bytes.Buffer, abiMap ma errorChan <- fmt.Errorf("error converting decodedArgsLogs to JSON for tx %s: %v", e.TransactionHash, err) continue } + if _, exists := localRawTransactions[e.TransactionHash]; !exists { + localRawTransactions[e.TransactionHash] = indexer.RawTransaction{ + Hash: tx.Hash, + BlockHash: b.Hash, + BlockTimestamp: b.Timestamp, + BlockNumber: tx.BlockNumber, + FromAddress: tx.FromAddress, + ToAddress: tx.ToAddress, + Gas: tx.Gas, + GasPrice: tx.GasPrice, + Input: tx.Input, + Nonce: tx.Nonce, + MaxFeePerGas: tx.MaxFeePerGas, + MaxPriorityFeePerGas: tx.MaxPriorityFeePerGas, + TransactionIndex: tx.TransactionIndex, + TransactionType: tx.TransactionType, + Value: tx.Value, + } + } // Convert event to label eventLabel := indexer.EventLabel{ Label: label, @@ -848,6 +886,9 @@ func (c *Client) DecodeProtoEntireBlockToLabels(rawData *bytes.Buffer, abiMap ma labelsMutex.Lock() labels = append(labels, localEventLabels...) txLabels = append(txLabels, localTxLabels...) + for _, rawTransaction := range localRawTransactions { + rawTransactions = append(rawTransactions, rawTransaction) + } labelsMutex.Unlock() }(b) } @@ -863,10 +904,10 @@ func (c *Client) DecodeProtoEntireBlockToLabels(rawData *bytes.Buffer, abiMap ma // If any errors occurred, return them if len(errorMessages) > 0 { - return nil, nil, fmt.Errorf("errors occurred during processing:\n%s", strings.Join(errorMessages, "\n")) + return nil, nil, nil, fmt.Errorf("errors occurred during processing:\n%s", strings.Join(errorMessages, "\n")) } - return labels, txLabels, nil + return labels, txLabels, rawTransactions, nil } func (c *Client) DecodeProtoTransactionsToLabels(transactions []string, blocksCache map[uint64]uint64, abiMap map[string]map[string]*indexer.AbiEntry) ([]indexer.TransactionLabel, error) { diff --git a/blockchain/blockchain.go.tmpl b/blockchain/blockchain.go.tmpl index e2dfcff..080ebdd 100644 --- a/blockchain/blockchain.go.tmpl +++ b/blockchain/blockchain.go.tmpl @@ -664,19 +664,20 @@ func (c *Client) DecodeProtoEntireBlockToJson(rawData *bytes.Buffer) (*seer_comm return blocksBatchJson, nil } -func (c *Client) DecodeProtoEntireBlockToLabels(rawData *bytes.Buffer, abiMap map[string]map[string]*indexer.AbiEntry, threads int) ([]indexer.EventLabel, []indexer.TransactionLabel, error) { +func (c *Client) DecodeProtoEntireBlockToLabels(rawData *bytes.Buffer, abiMap map[string]map[string]*indexer.AbiEntry, threads int) ([]indexer.EventLabel, []indexer.TransactionLabel, []indexer.RawTransaction, error) { var protoBlocksBatch {{.BlockchainName}}BlocksBatch dataBytes := rawData.Bytes() err := proto.Unmarshal(dataBytes, &protoBlocksBatch) if err != nil { - return nil, nil, fmt.Errorf("failed to unmarshal data: %v", err) + return nil, nil, nil, fmt.Errorf("failed to unmarshal data: %v", err) } // Shared slices to collect labels var labels []indexer.EventLabel var txLabels []indexer.TransactionLabel + var rawTransactions []indexer.RawTransaction var labelsMutex sync.Mutex var decodeErr error @@ -703,7 +704,7 @@ func (c *Client) DecodeProtoEntireBlockToLabels(rawData *bytes.Buffer, abiMap ma // Local slices to collect labels for this block var localEventLabels []indexer.EventLabel var localTxLabels []indexer.TransactionLabel - + localRawTransactions := make(map[string]indexer.RawTransaction) for _, tx := range b.Transactions { var decodedArgsTx map[string]interface{} @@ -771,6 +772,25 @@ func (c *Client) DecodeProtoEntireBlockToLabels(rawData *bytes.Buffer, abiMap ma continue } + localRawTransactions[tx.Hash] = indexer.RawTransaction{ + Hash: tx.Hash, + BlockHash: b.Hash, + BlockTimestamp: b.Timestamp, + BlockNumber: tx.BlockNumber, + FromAddress: tx.FromAddress, + ToAddress: tx.ToAddress, + Gas: tx.Gas, + GasPrice: tx.GasPrice, + Input: tx.Input, + Nonce: tx.Nonce, + MaxFeePerGas: tx.MaxFeePerGas, + MaxPriorityFeePerGas: tx.MaxPriorityFeePerGas, + TransactionIndex: tx.TransactionIndex, + TransactionType: tx.TransactionType, + Value: tx.Value, + {{if .IsSideChain -}} L1BlockNumber: &b.L1BlockNumber, {{end}} + } + // Convert transaction to label transactionLabel := indexer.TransactionLabel{ Address: tx.ToAddress, @@ -839,6 +859,26 @@ func (c *Client) DecodeProtoEntireBlockToLabels(rawData *bytes.Buffer, abiMap ma errorChan <- fmt.Errorf("error converting decodedArgsLogs to JSON for tx %s: %v", e.TransactionHash, err) continue } + if _, exists := localRawTransactions[e.TransactionHash]; !exists { + localRawTransactions[e.TransactionHash] = indexer.RawTransaction{ + Hash: tx.Hash, + BlockHash: b.Hash, + BlockTimestamp: b.Timestamp, + BlockNumber: tx.BlockNumber, + FromAddress: tx.FromAddress, + ToAddress: tx.ToAddress, + Gas: tx.Gas, + GasPrice: tx.GasPrice, + Input: tx.Input, + Nonce: tx.Nonce, + MaxFeePerGas: tx.MaxFeePerGas, + MaxPriorityFeePerGas: tx.MaxPriorityFeePerGas, + TransactionIndex: tx.TransactionIndex, + TransactionType: tx.TransactionType, + Value: tx.Value, + {{if .IsSideChain -}} L1BlockNumber: &b.L1BlockNumber, {{end}} + } + } // Convert event to label eventLabel := indexer.EventLabel{ Label: label, @@ -862,6 +902,9 @@ func (c *Client) DecodeProtoEntireBlockToLabels(rawData *bytes.Buffer, abiMap ma labelsMutex.Lock() labels = append(labels, localEventLabels...) txLabels = append(txLabels, localTxLabels...) + for _, rawTransaction := range localRawTransactions { + rawTransactions = append(rawTransactions, rawTransaction) + } labelsMutex.Unlock() }(b) } @@ -877,10 +920,10 @@ func (c *Client) DecodeProtoEntireBlockToLabels(rawData *bytes.Buffer, abiMap ma // If any errors occurred, return them if len(errorMessages) > 0 { - return nil, nil, fmt.Errorf("errors occurred during processing:\n%s", strings.Join(errorMessages, "\n")) + return nil, nil, nil, fmt.Errorf("errors occurred during processing:\n%s", strings.Join(errorMessages, "\n")) } - return labels, txLabels, nil + return labels, txLabels, rawTransactions, nil } func (c *Client) DecodeProtoTransactionsToLabels(transactions []string, blocksCache map[uint64]uint64, abiMap map[string]map[string]*indexer.AbiEntry) ([]indexer.TransactionLabel, error) { diff --git a/blockchain/ethereum/ethereum.go b/blockchain/ethereum/ethereum.go index 8b8fbfd..a19a1bb 100644 --- a/blockchain/ethereum/ethereum.go +++ b/blockchain/ethereum/ethereum.go @@ -652,19 +652,20 @@ func (c *Client) DecodeProtoEntireBlockToJson(rawData *bytes.Buffer) (*seer_comm return blocksBatchJson, nil } -func (c *Client) DecodeProtoEntireBlockToLabels(rawData *bytes.Buffer, abiMap map[string]map[string]*indexer.AbiEntry, threads int) ([]indexer.EventLabel, []indexer.TransactionLabel, error) { +func (c *Client) DecodeProtoEntireBlockToLabels(rawData *bytes.Buffer, abiMap map[string]map[string]*indexer.AbiEntry, threads int) ([]indexer.EventLabel, []indexer.TransactionLabel, []indexer.RawTransaction, error) { var protoBlocksBatch EthereumBlocksBatch dataBytes := rawData.Bytes() err := proto.Unmarshal(dataBytes, &protoBlocksBatch) if err != nil { - return nil, nil, fmt.Errorf("failed to unmarshal data: %v", err) + return nil, nil, nil, fmt.Errorf("failed to unmarshal data: %v", err) } // Shared slices to collect labels var labels []indexer.EventLabel var txLabels []indexer.TransactionLabel + var rawTransactions []indexer.RawTransaction var labelsMutex sync.Mutex var decodeErr error @@ -689,7 +690,7 @@ func (c *Client) DecodeProtoEntireBlockToLabels(rawData *bytes.Buffer, abiMap ma // Local slices to collect labels for this block var localEventLabels []indexer.EventLabel var localTxLabels []indexer.TransactionLabel - + localRawTransactions := make(map[string]indexer.RawTransaction) for _, tx := range b.Transactions { var decodedArgsTx map[string]interface{} @@ -757,6 +758,24 @@ func (c *Client) DecodeProtoEntireBlockToLabels(rawData *bytes.Buffer, abiMap ma continue } + localRawTransactions[tx.Hash] = indexer.RawTransaction{ + Hash: tx.Hash, + BlockHash: b.Hash, + BlockTimestamp: b.Timestamp, + BlockNumber: tx.BlockNumber, + FromAddress: tx.FromAddress, + ToAddress: tx.ToAddress, + Gas: tx.Gas, + GasPrice: tx.GasPrice, + Input: tx.Input, + Nonce: tx.Nonce, + MaxFeePerGas: tx.MaxFeePerGas, + MaxPriorityFeePerGas: tx.MaxPriorityFeePerGas, + TransactionIndex: tx.TransactionIndex, + TransactionType: tx.TransactionType, + Value: tx.Value, + } + // Convert transaction to label transactionLabel := indexer.TransactionLabel{ Address: tx.ToAddress, @@ -825,6 +844,25 @@ func (c *Client) DecodeProtoEntireBlockToLabels(rawData *bytes.Buffer, abiMap ma errorChan <- fmt.Errorf("error converting decodedArgsLogs to JSON for tx %s: %v", e.TransactionHash, err) continue } + if _, exists := localRawTransactions[e.TransactionHash]; !exists { + localRawTransactions[e.TransactionHash] = indexer.RawTransaction{ + Hash: tx.Hash, + BlockHash: b.Hash, + BlockTimestamp: b.Timestamp, + BlockNumber: tx.BlockNumber, + FromAddress: tx.FromAddress, + ToAddress: tx.ToAddress, + Gas: tx.Gas, + GasPrice: tx.GasPrice, + Input: tx.Input, + Nonce: tx.Nonce, + MaxFeePerGas: tx.MaxFeePerGas, + MaxPriorityFeePerGas: tx.MaxPriorityFeePerGas, + TransactionIndex: tx.TransactionIndex, + TransactionType: tx.TransactionType, + Value: tx.Value, + } + } // Convert event to label eventLabel := indexer.EventLabel{ Label: label, @@ -848,6 +886,9 @@ func (c *Client) DecodeProtoEntireBlockToLabels(rawData *bytes.Buffer, abiMap ma labelsMutex.Lock() labels = append(labels, localEventLabels...) txLabels = append(txLabels, localTxLabels...) + for _, rawTransaction := range localRawTransactions { + rawTransactions = append(rawTransactions, rawTransaction) + } labelsMutex.Unlock() }(b) } @@ -863,10 +904,10 @@ func (c *Client) DecodeProtoEntireBlockToLabels(rawData *bytes.Buffer, abiMap ma // If any errors occurred, return them if len(errorMessages) > 0 { - return nil, nil, fmt.Errorf("errors occurred during processing:\n%s", strings.Join(errorMessages, "\n")) + return nil, nil, nil, fmt.Errorf("errors occurred during processing:\n%s", strings.Join(errorMessages, "\n")) } - return labels, txLabels, nil + return labels, txLabels, rawTransactions, nil } func (c *Client) DecodeProtoTransactionsToLabels(transactions []string, blocksCache map[uint64]uint64, abiMap map[string]map[string]*indexer.AbiEntry) ([]indexer.TransactionLabel, error) { diff --git a/blockchain/game7/game7.go b/blockchain/game7/game7.go index e2f4eea..abb4a92 100644 --- a/blockchain/game7/game7.go +++ b/blockchain/game7/game7.go @@ -662,19 +662,20 @@ func (c *Client) DecodeProtoEntireBlockToJson(rawData *bytes.Buffer) (*seer_comm return blocksBatchJson, nil } -func (c *Client) DecodeProtoEntireBlockToLabels(rawData *bytes.Buffer, abiMap map[string]map[string]*indexer.AbiEntry, threads int) ([]indexer.EventLabel, []indexer.TransactionLabel, error) { +func (c *Client) DecodeProtoEntireBlockToLabels(rawData *bytes.Buffer, abiMap map[string]map[string]*indexer.AbiEntry, threads int) ([]indexer.EventLabel, []indexer.TransactionLabel, []indexer.RawTransaction, error) { var protoBlocksBatch Game7BlocksBatch dataBytes := rawData.Bytes() err := proto.Unmarshal(dataBytes, &protoBlocksBatch) if err != nil { - return nil, nil, fmt.Errorf("failed to unmarshal data: %v", err) + return nil, nil, nil, fmt.Errorf("failed to unmarshal data: %v", err) } // Shared slices to collect labels var labels []indexer.EventLabel var txLabels []indexer.TransactionLabel + var rawTransactions []indexer.RawTransaction var labelsMutex sync.Mutex var decodeErr error @@ -699,7 +700,7 @@ func (c *Client) DecodeProtoEntireBlockToLabels(rawData *bytes.Buffer, abiMap ma // Local slices to collect labels for this block var localEventLabels []indexer.EventLabel var localTxLabels []indexer.TransactionLabel - + localRawTransactions := make(map[string]indexer.RawTransaction) for _, tx := range b.Transactions { var decodedArgsTx map[string]interface{} @@ -767,6 +768,25 @@ func (c *Client) DecodeProtoEntireBlockToLabels(rawData *bytes.Buffer, abiMap ma continue } + localRawTransactions[tx.Hash] = indexer.RawTransaction{ + Hash: tx.Hash, + BlockHash: b.Hash, + BlockTimestamp: b.Timestamp, + BlockNumber: tx.BlockNumber, + FromAddress: tx.FromAddress, + ToAddress: tx.ToAddress, + Gas: tx.Gas, + GasPrice: tx.GasPrice, + Input: tx.Input, + Nonce: tx.Nonce, + MaxFeePerGas: tx.MaxFeePerGas, + MaxPriorityFeePerGas: tx.MaxPriorityFeePerGas, + TransactionIndex: tx.TransactionIndex, + TransactionType: tx.TransactionType, + Value: tx.Value, + L1BlockNumber: &b.L1BlockNumber, + } + // Convert transaction to label transactionLabel := indexer.TransactionLabel{ Address: tx.ToAddress, @@ -835,6 +855,26 @@ func (c *Client) DecodeProtoEntireBlockToLabels(rawData *bytes.Buffer, abiMap ma errorChan <- fmt.Errorf("error converting decodedArgsLogs to JSON for tx %s: %v", e.TransactionHash, err) continue } + if _, exists := localRawTransactions[e.TransactionHash]; !exists { + localRawTransactions[e.TransactionHash] = indexer.RawTransaction{ + Hash: tx.Hash, + BlockHash: b.Hash, + BlockTimestamp: b.Timestamp, + BlockNumber: tx.BlockNumber, + FromAddress: tx.FromAddress, + ToAddress: tx.ToAddress, + Gas: tx.Gas, + GasPrice: tx.GasPrice, + Input: tx.Input, + Nonce: tx.Nonce, + MaxFeePerGas: tx.MaxFeePerGas, + MaxPriorityFeePerGas: tx.MaxPriorityFeePerGas, + TransactionIndex: tx.TransactionIndex, + TransactionType: tx.TransactionType, + Value: tx.Value, + L1BlockNumber: &b.L1BlockNumber, + } + } // Convert event to label eventLabel := indexer.EventLabel{ Label: label, @@ -858,6 +898,9 @@ func (c *Client) DecodeProtoEntireBlockToLabels(rawData *bytes.Buffer, abiMap ma labelsMutex.Lock() labels = append(labels, localEventLabels...) txLabels = append(txLabels, localTxLabels...) + for _, rawTransaction := range localRawTransactions { + rawTransactions = append(rawTransactions, rawTransaction) + } labelsMutex.Unlock() }(b) } @@ -873,10 +916,10 @@ func (c *Client) DecodeProtoEntireBlockToLabels(rawData *bytes.Buffer, abiMap ma // If any errors occurred, return them if len(errorMessages) > 0 { - return nil, nil, fmt.Errorf("errors occurred during processing:\n%s", strings.Join(errorMessages, "\n")) + return nil, nil, nil, fmt.Errorf("errors occurred during processing:\n%s", strings.Join(errorMessages, "\n")) } - return labels, txLabels, nil + return labels, txLabels, rawTransactions, nil } func (c *Client) DecodeProtoTransactionsToLabels(transactions []string, blocksCache map[uint64]uint64, abiMap map[string]map[string]*indexer.AbiEntry) ([]indexer.TransactionLabel, error) { diff --git a/blockchain/game7_orbit_arbitrum_sepolia/game7_orbit_arbitrum_sepolia.go b/blockchain/game7_orbit_arbitrum_sepolia/game7_orbit_arbitrum_sepolia.go index 8c74484..0a42e57 100644 --- a/blockchain/game7_orbit_arbitrum_sepolia/game7_orbit_arbitrum_sepolia.go +++ b/blockchain/game7_orbit_arbitrum_sepolia/game7_orbit_arbitrum_sepolia.go @@ -662,19 +662,20 @@ func (c *Client) DecodeProtoEntireBlockToJson(rawData *bytes.Buffer) (*seer_comm return blocksBatchJson, nil } -func (c *Client) DecodeProtoEntireBlockToLabels(rawData *bytes.Buffer, abiMap map[string]map[string]*indexer.AbiEntry, threads int) ([]indexer.EventLabel, []indexer.TransactionLabel, error) { +func (c *Client) DecodeProtoEntireBlockToLabels(rawData *bytes.Buffer, abiMap map[string]map[string]*indexer.AbiEntry, threads int) ([]indexer.EventLabel, []indexer.TransactionLabel, []indexer.RawTransaction, error) { var protoBlocksBatch Game7OrbitArbitrumSepoliaBlocksBatch dataBytes := rawData.Bytes() err := proto.Unmarshal(dataBytes, &protoBlocksBatch) if err != nil { - return nil, nil, fmt.Errorf("failed to unmarshal data: %v", err) + return nil, nil, nil, fmt.Errorf("failed to unmarshal data: %v", err) } // Shared slices to collect labels var labels []indexer.EventLabel var txLabels []indexer.TransactionLabel + var rawTransactions []indexer.RawTransaction var labelsMutex sync.Mutex var decodeErr error @@ -699,7 +700,7 @@ func (c *Client) DecodeProtoEntireBlockToLabels(rawData *bytes.Buffer, abiMap ma // Local slices to collect labels for this block var localEventLabels []indexer.EventLabel var localTxLabels []indexer.TransactionLabel - + localRawTransactions := make(map[string]indexer.RawTransaction) for _, tx := range b.Transactions { var decodedArgsTx map[string]interface{} @@ -767,6 +768,25 @@ func (c *Client) DecodeProtoEntireBlockToLabels(rawData *bytes.Buffer, abiMap ma continue } + localRawTransactions[tx.Hash] = indexer.RawTransaction{ + Hash: tx.Hash, + BlockHash: b.Hash, + BlockTimestamp: b.Timestamp, + BlockNumber: tx.BlockNumber, + FromAddress: tx.FromAddress, + ToAddress: tx.ToAddress, + Gas: tx.Gas, + GasPrice: tx.GasPrice, + Input: tx.Input, + Nonce: tx.Nonce, + MaxFeePerGas: tx.MaxFeePerGas, + MaxPriorityFeePerGas: tx.MaxPriorityFeePerGas, + TransactionIndex: tx.TransactionIndex, + TransactionType: tx.TransactionType, + Value: tx.Value, + L1BlockNumber: &b.L1BlockNumber, + } + // Convert transaction to label transactionLabel := indexer.TransactionLabel{ Address: tx.ToAddress, @@ -835,6 +855,26 @@ func (c *Client) DecodeProtoEntireBlockToLabels(rawData *bytes.Buffer, abiMap ma errorChan <- fmt.Errorf("error converting decodedArgsLogs to JSON for tx %s: %v", e.TransactionHash, err) continue } + if _, exists := localRawTransactions[e.TransactionHash]; !exists { + localRawTransactions[e.TransactionHash] = indexer.RawTransaction{ + Hash: tx.Hash, + BlockHash: b.Hash, + BlockTimestamp: b.Timestamp, + BlockNumber: tx.BlockNumber, + FromAddress: tx.FromAddress, + ToAddress: tx.ToAddress, + Gas: tx.Gas, + GasPrice: tx.GasPrice, + Input: tx.Input, + Nonce: tx.Nonce, + MaxFeePerGas: tx.MaxFeePerGas, + MaxPriorityFeePerGas: tx.MaxPriorityFeePerGas, + TransactionIndex: tx.TransactionIndex, + TransactionType: tx.TransactionType, + Value: tx.Value, + L1BlockNumber: &b.L1BlockNumber, + } + } // Convert event to label eventLabel := indexer.EventLabel{ Label: label, @@ -858,6 +898,9 @@ func (c *Client) DecodeProtoEntireBlockToLabels(rawData *bytes.Buffer, abiMap ma labelsMutex.Lock() labels = append(labels, localEventLabels...) txLabels = append(txLabels, localTxLabels...) + for _, rawTransaction := range localRawTransactions { + rawTransactions = append(rawTransactions, rawTransaction) + } labelsMutex.Unlock() }(b) } @@ -873,10 +916,10 @@ func (c *Client) DecodeProtoEntireBlockToLabels(rawData *bytes.Buffer, abiMap ma // If any errors occurred, return them if len(errorMessages) > 0 { - return nil, nil, fmt.Errorf("errors occurred during processing:\n%s", strings.Join(errorMessages, "\n")) + return nil, nil, nil, fmt.Errorf("errors occurred during processing:\n%s", strings.Join(errorMessages, "\n")) } - return labels, txLabels, nil + return labels, txLabels, rawTransactions, nil } func (c *Client) DecodeProtoTransactionsToLabels(transactions []string, blocksCache map[uint64]uint64, abiMap map[string]map[string]*indexer.AbiEntry) ([]indexer.TransactionLabel, error) { diff --git a/blockchain/game7_testnet/game7_testnet.go b/blockchain/game7_testnet/game7_testnet.go index d2f98e8..8162920 100644 --- a/blockchain/game7_testnet/game7_testnet.go +++ b/blockchain/game7_testnet/game7_testnet.go @@ -662,19 +662,20 @@ func (c *Client) DecodeProtoEntireBlockToJson(rawData *bytes.Buffer) (*seer_comm return blocksBatchJson, nil } -func (c *Client) DecodeProtoEntireBlockToLabels(rawData *bytes.Buffer, abiMap map[string]map[string]*indexer.AbiEntry, threads int) ([]indexer.EventLabel, []indexer.TransactionLabel, error) { +func (c *Client) DecodeProtoEntireBlockToLabels(rawData *bytes.Buffer, abiMap map[string]map[string]*indexer.AbiEntry, threads int) ([]indexer.EventLabel, []indexer.TransactionLabel, []indexer.RawTransaction, error) { var protoBlocksBatch Game7TestnetBlocksBatch dataBytes := rawData.Bytes() err := proto.Unmarshal(dataBytes, &protoBlocksBatch) if err != nil { - return nil, nil, fmt.Errorf("failed to unmarshal data: %v", err) + return nil, nil, nil, fmt.Errorf("failed to unmarshal data: %v", err) } // Shared slices to collect labels var labels []indexer.EventLabel var txLabels []indexer.TransactionLabel + var rawTransactions []indexer.RawTransaction var labelsMutex sync.Mutex var decodeErr error @@ -699,7 +700,7 @@ func (c *Client) DecodeProtoEntireBlockToLabels(rawData *bytes.Buffer, abiMap ma // Local slices to collect labels for this block var localEventLabels []indexer.EventLabel var localTxLabels []indexer.TransactionLabel - + localRawTransactions := make(map[string]indexer.RawTransaction) for _, tx := range b.Transactions { var decodedArgsTx map[string]interface{} @@ -767,6 +768,25 @@ func (c *Client) DecodeProtoEntireBlockToLabels(rawData *bytes.Buffer, abiMap ma continue } + localRawTransactions[tx.Hash] = indexer.RawTransaction{ + Hash: tx.Hash, + BlockHash: b.Hash, + BlockTimestamp: b.Timestamp, + BlockNumber: tx.BlockNumber, + FromAddress: tx.FromAddress, + ToAddress: tx.ToAddress, + Gas: tx.Gas, + GasPrice: tx.GasPrice, + Input: tx.Input, + Nonce: tx.Nonce, + MaxFeePerGas: tx.MaxFeePerGas, + MaxPriorityFeePerGas: tx.MaxPriorityFeePerGas, + TransactionIndex: tx.TransactionIndex, + TransactionType: tx.TransactionType, + Value: tx.Value, + L1BlockNumber: &b.L1BlockNumber, + } + // Convert transaction to label transactionLabel := indexer.TransactionLabel{ Address: tx.ToAddress, @@ -835,6 +855,26 @@ func (c *Client) DecodeProtoEntireBlockToLabels(rawData *bytes.Buffer, abiMap ma errorChan <- fmt.Errorf("error converting decodedArgsLogs to JSON for tx %s: %v", e.TransactionHash, err) continue } + if _, exists := localRawTransactions[e.TransactionHash]; !exists { + localRawTransactions[e.TransactionHash] = indexer.RawTransaction{ + Hash: tx.Hash, + BlockHash: b.Hash, + BlockTimestamp: b.Timestamp, + BlockNumber: tx.BlockNumber, + FromAddress: tx.FromAddress, + ToAddress: tx.ToAddress, + Gas: tx.Gas, + GasPrice: tx.GasPrice, + Input: tx.Input, + Nonce: tx.Nonce, + MaxFeePerGas: tx.MaxFeePerGas, + MaxPriorityFeePerGas: tx.MaxPriorityFeePerGas, + TransactionIndex: tx.TransactionIndex, + TransactionType: tx.TransactionType, + Value: tx.Value, + L1BlockNumber: &b.L1BlockNumber, + } + } // Convert event to label eventLabel := indexer.EventLabel{ Label: label, @@ -858,6 +898,9 @@ func (c *Client) DecodeProtoEntireBlockToLabels(rawData *bytes.Buffer, abiMap ma labelsMutex.Lock() labels = append(labels, localEventLabels...) txLabels = append(txLabels, localTxLabels...) + for _, rawTransaction := range localRawTransactions { + rawTransactions = append(rawTransactions, rawTransaction) + } labelsMutex.Unlock() }(b) } @@ -873,10 +916,10 @@ func (c *Client) DecodeProtoEntireBlockToLabels(rawData *bytes.Buffer, abiMap ma // If any errors occurred, return them if len(errorMessages) > 0 { - return nil, nil, fmt.Errorf("errors occurred during processing:\n%s", strings.Join(errorMessages, "\n")) + return nil, nil, nil, fmt.Errorf("errors occurred during processing:\n%s", strings.Join(errorMessages, "\n")) } - return labels, txLabels, nil + return labels, txLabels, rawTransactions, nil } func (c *Client) DecodeProtoTransactionsToLabels(transactions []string, blocksCache map[uint64]uint64, abiMap map[string]map[string]*indexer.AbiEntry) ([]indexer.TransactionLabel, error) { diff --git a/blockchain/handlers.go b/blockchain/handlers.go index 0e23119..6d7e18f 100644 --- a/blockchain/handlers.go +++ b/blockchain/handlers.go @@ -110,7 +110,7 @@ type BlockchainClient interface { FetchAsProtoBlocksWithEvents(*big.Int, *big.Int, bool, int) ([]proto.Message, []indexer.BlockIndex, uint64, error) ProcessBlocksToBatch([]proto.Message) (proto.Message, error) DecodeProtoEntireBlockToJson(*bytes.Buffer) (*seer_common.BlocksBatchJson, error) - DecodeProtoEntireBlockToLabels(*bytes.Buffer, map[string]map[string]*indexer.AbiEntry, int) ([]indexer.EventLabel, []indexer.TransactionLabel, error) + DecodeProtoEntireBlockToLabels(*bytes.Buffer, map[string]map[string]*indexer.AbiEntry, int) ([]indexer.EventLabel, []indexer.TransactionLabel, []indexer.RawTransaction, error) DecodeProtoTransactionsToLabels([]string, map[uint64]uint64, map[string]map[string]*indexer.AbiEntry) ([]indexer.TransactionLabel, error) ChainType() string GetCode(context.Context, common.Address, uint64) ([]byte, error) diff --git a/blockchain/imx_zkevm/imx_zkevm.go b/blockchain/imx_zkevm/imx_zkevm.go index f9b880c..f12ec99 100644 --- a/blockchain/imx_zkevm/imx_zkevm.go +++ b/blockchain/imx_zkevm/imx_zkevm.go @@ -652,19 +652,20 @@ func (c *Client) DecodeProtoEntireBlockToJson(rawData *bytes.Buffer) (*seer_comm return blocksBatchJson, nil } -func (c *Client) DecodeProtoEntireBlockToLabels(rawData *bytes.Buffer, abiMap map[string]map[string]*indexer.AbiEntry, threads int) ([]indexer.EventLabel, []indexer.TransactionLabel, error) { +func (c *Client) DecodeProtoEntireBlockToLabels(rawData *bytes.Buffer, abiMap map[string]map[string]*indexer.AbiEntry, threads int) ([]indexer.EventLabel, []indexer.TransactionLabel, []indexer.RawTransaction, error) { var protoBlocksBatch ImxZkevmBlocksBatch dataBytes := rawData.Bytes() err := proto.Unmarshal(dataBytes, &protoBlocksBatch) if err != nil { - return nil, nil, fmt.Errorf("failed to unmarshal data: %v", err) + return nil, nil, nil, fmt.Errorf("failed to unmarshal data: %v", err) } // Shared slices to collect labels var labels []indexer.EventLabel var txLabels []indexer.TransactionLabel + var rawTransactions []indexer.RawTransaction var labelsMutex sync.Mutex var decodeErr error @@ -689,7 +690,7 @@ func (c *Client) DecodeProtoEntireBlockToLabels(rawData *bytes.Buffer, abiMap ma // Local slices to collect labels for this block var localEventLabels []indexer.EventLabel var localTxLabels []indexer.TransactionLabel - + localRawTransactions := make(map[string]indexer.RawTransaction) for _, tx := range b.Transactions { var decodedArgsTx map[string]interface{} @@ -757,6 +758,24 @@ func (c *Client) DecodeProtoEntireBlockToLabels(rawData *bytes.Buffer, abiMap ma continue } + localRawTransactions[tx.Hash] = indexer.RawTransaction{ + Hash: tx.Hash, + BlockHash: b.Hash, + BlockTimestamp: b.Timestamp, + BlockNumber: tx.BlockNumber, + FromAddress: tx.FromAddress, + ToAddress: tx.ToAddress, + Gas: tx.Gas, + GasPrice: tx.GasPrice, + Input: tx.Input, + Nonce: tx.Nonce, + MaxFeePerGas: tx.MaxFeePerGas, + MaxPriorityFeePerGas: tx.MaxPriorityFeePerGas, + TransactionIndex: tx.TransactionIndex, + TransactionType: tx.TransactionType, + Value: tx.Value, + } + // Convert transaction to label transactionLabel := indexer.TransactionLabel{ Address: tx.ToAddress, @@ -825,6 +844,25 @@ func (c *Client) DecodeProtoEntireBlockToLabels(rawData *bytes.Buffer, abiMap ma errorChan <- fmt.Errorf("error converting decodedArgsLogs to JSON for tx %s: %v", e.TransactionHash, err) continue } + if _, exists := localRawTransactions[e.TransactionHash]; !exists { + localRawTransactions[e.TransactionHash] = indexer.RawTransaction{ + Hash: tx.Hash, + BlockHash: b.Hash, + BlockTimestamp: b.Timestamp, + BlockNumber: tx.BlockNumber, + FromAddress: tx.FromAddress, + ToAddress: tx.ToAddress, + Gas: tx.Gas, + GasPrice: tx.GasPrice, + Input: tx.Input, + Nonce: tx.Nonce, + MaxFeePerGas: tx.MaxFeePerGas, + MaxPriorityFeePerGas: tx.MaxPriorityFeePerGas, + TransactionIndex: tx.TransactionIndex, + TransactionType: tx.TransactionType, + Value: tx.Value, + } + } // Convert event to label eventLabel := indexer.EventLabel{ Label: label, @@ -848,6 +886,9 @@ func (c *Client) DecodeProtoEntireBlockToLabels(rawData *bytes.Buffer, abiMap ma labelsMutex.Lock() labels = append(labels, localEventLabels...) txLabels = append(txLabels, localTxLabels...) + for _, rawTransaction := range localRawTransactions { + rawTransactions = append(rawTransactions, rawTransaction) + } labelsMutex.Unlock() }(b) } @@ -863,10 +904,10 @@ func (c *Client) DecodeProtoEntireBlockToLabels(rawData *bytes.Buffer, abiMap ma // If any errors occurred, return them if len(errorMessages) > 0 { - return nil, nil, fmt.Errorf("errors occurred during processing:\n%s", strings.Join(errorMessages, "\n")) + return nil, nil, nil, fmt.Errorf("errors occurred during processing:\n%s", strings.Join(errorMessages, "\n")) } - return labels, txLabels, nil + return labels, txLabels, rawTransactions, nil } func (c *Client) DecodeProtoTransactionsToLabels(transactions []string, blocksCache map[uint64]uint64, abiMap map[string]map[string]*indexer.AbiEntry) ([]indexer.TransactionLabel, error) { diff --git a/blockchain/imx_zkevm_sepolia/imx_zkevm_sepolia.go b/blockchain/imx_zkevm_sepolia/imx_zkevm_sepolia.go index 3a3af5a..8035291 100644 --- a/blockchain/imx_zkevm_sepolia/imx_zkevm_sepolia.go +++ b/blockchain/imx_zkevm_sepolia/imx_zkevm_sepolia.go @@ -652,19 +652,20 @@ func (c *Client) DecodeProtoEntireBlockToJson(rawData *bytes.Buffer) (*seer_comm return blocksBatchJson, nil } -func (c *Client) DecodeProtoEntireBlockToLabels(rawData *bytes.Buffer, abiMap map[string]map[string]*indexer.AbiEntry, threads int) ([]indexer.EventLabel, []indexer.TransactionLabel, error) { +func (c *Client) DecodeProtoEntireBlockToLabels(rawData *bytes.Buffer, abiMap map[string]map[string]*indexer.AbiEntry, threads int) ([]indexer.EventLabel, []indexer.TransactionLabel, []indexer.RawTransaction, error) { var protoBlocksBatch ImxZkevmSepoliaBlocksBatch dataBytes := rawData.Bytes() err := proto.Unmarshal(dataBytes, &protoBlocksBatch) if err != nil { - return nil, nil, fmt.Errorf("failed to unmarshal data: %v", err) + return nil, nil, nil, fmt.Errorf("failed to unmarshal data: %v", err) } // Shared slices to collect labels var labels []indexer.EventLabel var txLabels []indexer.TransactionLabel + var rawTransactions []indexer.RawTransaction var labelsMutex sync.Mutex var decodeErr error @@ -689,7 +690,7 @@ func (c *Client) DecodeProtoEntireBlockToLabels(rawData *bytes.Buffer, abiMap ma // Local slices to collect labels for this block var localEventLabels []indexer.EventLabel var localTxLabels []indexer.TransactionLabel - + localRawTransactions := make(map[string]indexer.RawTransaction) for _, tx := range b.Transactions { var decodedArgsTx map[string]interface{} @@ -757,6 +758,24 @@ func (c *Client) DecodeProtoEntireBlockToLabels(rawData *bytes.Buffer, abiMap ma continue } + localRawTransactions[tx.Hash] = indexer.RawTransaction{ + Hash: tx.Hash, + BlockHash: b.Hash, + BlockTimestamp: b.Timestamp, + BlockNumber: tx.BlockNumber, + FromAddress: tx.FromAddress, + ToAddress: tx.ToAddress, + Gas: tx.Gas, + GasPrice: tx.GasPrice, + Input: tx.Input, + Nonce: tx.Nonce, + MaxFeePerGas: tx.MaxFeePerGas, + MaxPriorityFeePerGas: tx.MaxPriorityFeePerGas, + TransactionIndex: tx.TransactionIndex, + TransactionType: tx.TransactionType, + Value: tx.Value, + } + // Convert transaction to label transactionLabel := indexer.TransactionLabel{ Address: tx.ToAddress, @@ -825,6 +844,25 @@ func (c *Client) DecodeProtoEntireBlockToLabels(rawData *bytes.Buffer, abiMap ma errorChan <- fmt.Errorf("error converting decodedArgsLogs to JSON for tx %s: %v", e.TransactionHash, err) continue } + if _, exists := localRawTransactions[e.TransactionHash]; !exists { + localRawTransactions[e.TransactionHash] = indexer.RawTransaction{ + Hash: tx.Hash, + BlockHash: b.Hash, + BlockTimestamp: b.Timestamp, + BlockNumber: tx.BlockNumber, + FromAddress: tx.FromAddress, + ToAddress: tx.ToAddress, + Gas: tx.Gas, + GasPrice: tx.GasPrice, + Input: tx.Input, + Nonce: tx.Nonce, + MaxFeePerGas: tx.MaxFeePerGas, + MaxPriorityFeePerGas: tx.MaxPriorityFeePerGas, + TransactionIndex: tx.TransactionIndex, + TransactionType: tx.TransactionType, + Value: tx.Value, + } + } // Convert event to label eventLabel := indexer.EventLabel{ Label: label, @@ -848,6 +886,9 @@ func (c *Client) DecodeProtoEntireBlockToLabels(rawData *bytes.Buffer, abiMap ma labelsMutex.Lock() labels = append(labels, localEventLabels...) txLabels = append(txLabels, localTxLabels...) + for _, rawTransaction := range localRawTransactions { + rawTransactions = append(rawTransactions, rawTransaction) + } labelsMutex.Unlock() }(b) } @@ -863,10 +904,10 @@ func (c *Client) DecodeProtoEntireBlockToLabels(rawData *bytes.Buffer, abiMap ma // If any errors occurred, return them if len(errorMessages) > 0 { - return nil, nil, fmt.Errorf("errors occurred during processing:\n%s", strings.Join(errorMessages, "\n")) + return nil, nil, nil, fmt.Errorf("errors occurred during processing:\n%s", strings.Join(errorMessages, "\n")) } - return labels, txLabels, nil + return labels, txLabels, rawTransactions, nil } func (c *Client) DecodeProtoTransactionsToLabels(transactions []string, blocksCache map[uint64]uint64, abiMap map[string]map[string]*indexer.AbiEntry) ([]indexer.TransactionLabel, error) { diff --git a/blockchain/mantle/mantle.go b/blockchain/mantle/mantle.go index 1222076..d56f77d 100644 --- a/blockchain/mantle/mantle.go +++ b/blockchain/mantle/mantle.go @@ -652,19 +652,20 @@ func (c *Client) DecodeProtoEntireBlockToJson(rawData *bytes.Buffer) (*seer_comm return blocksBatchJson, nil } -func (c *Client) DecodeProtoEntireBlockToLabels(rawData *bytes.Buffer, abiMap map[string]map[string]*indexer.AbiEntry, threads int) ([]indexer.EventLabel, []indexer.TransactionLabel, error) { +func (c *Client) DecodeProtoEntireBlockToLabels(rawData *bytes.Buffer, abiMap map[string]map[string]*indexer.AbiEntry, threads int) ([]indexer.EventLabel, []indexer.TransactionLabel, []indexer.RawTransaction, error) { var protoBlocksBatch MantleBlocksBatch dataBytes := rawData.Bytes() err := proto.Unmarshal(dataBytes, &protoBlocksBatch) if err != nil { - return nil, nil, fmt.Errorf("failed to unmarshal data: %v", err) + return nil, nil, nil, fmt.Errorf("failed to unmarshal data: %v", err) } // Shared slices to collect labels var labels []indexer.EventLabel var txLabels []indexer.TransactionLabel + var rawTransactions []indexer.RawTransaction var labelsMutex sync.Mutex var decodeErr error @@ -689,7 +690,7 @@ func (c *Client) DecodeProtoEntireBlockToLabels(rawData *bytes.Buffer, abiMap ma // Local slices to collect labels for this block var localEventLabels []indexer.EventLabel var localTxLabels []indexer.TransactionLabel - + localRawTransactions := make(map[string]indexer.RawTransaction) for _, tx := range b.Transactions { var decodedArgsTx map[string]interface{} @@ -757,6 +758,24 @@ func (c *Client) DecodeProtoEntireBlockToLabels(rawData *bytes.Buffer, abiMap ma continue } + localRawTransactions[tx.Hash] = indexer.RawTransaction{ + Hash: tx.Hash, + BlockHash: b.Hash, + BlockTimestamp: b.Timestamp, + BlockNumber: tx.BlockNumber, + FromAddress: tx.FromAddress, + ToAddress: tx.ToAddress, + Gas: tx.Gas, + GasPrice: tx.GasPrice, + Input: tx.Input, + Nonce: tx.Nonce, + MaxFeePerGas: tx.MaxFeePerGas, + MaxPriorityFeePerGas: tx.MaxPriorityFeePerGas, + TransactionIndex: tx.TransactionIndex, + TransactionType: tx.TransactionType, + Value: tx.Value, + } + // Convert transaction to label transactionLabel := indexer.TransactionLabel{ Address: tx.ToAddress, @@ -825,6 +844,25 @@ func (c *Client) DecodeProtoEntireBlockToLabels(rawData *bytes.Buffer, abiMap ma errorChan <- fmt.Errorf("error converting decodedArgsLogs to JSON for tx %s: %v", e.TransactionHash, err) continue } + if _, exists := localRawTransactions[e.TransactionHash]; !exists { + localRawTransactions[e.TransactionHash] = indexer.RawTransaction{ + Hash: tx.Hash, + BlockHash: b.Hash, + BlockTimestamp: b.Timestamp, + BlockNumber: tx.BlockNumber, + FromAddress: tx.FromAddress, + ToAddress: tx.ToAddress, + Gas: tx.Gas, + GasPrice: tx.GasPrice, + Input: tx.Input, + Nonce: tx.Nonce, + MaxFeePerGas: tx.MaxFeePerGas, + MaxPriorityFeePerGas: tx.MaxPriorityFeePerGas, + TransactionIndex: tx.TransactionIndex, + TransactionType: tx.TransactionType, + Value: tx.Value, + } + } // Convert event to label eventLabel := indexer.EventLabel{ Label: label, @@ -848,6 +886,9 @@ func (c *Client) DecodeProtoEntireBlockToLabels(rawData *bytes.Buffer, abiMap ma labelsMutex.Lock() labels = append(labels, localEventLabels...) txLabels = append(txLabels, localTxLabels...) + for _, rawTransaction := range localRawTransactions { + rawTransactions = append(rawTransactions, rawTransaction) + } labelsMutex.Unlock() }(b) } @@ -863,10 +904,10 @@ func (c *Client) DecodeProtoEntireBlockToLabels(rawData *bytes.Buffer, abiMap ma // If any errors occurred, return them if len(errorMessages) > 0 { - return nil, nil, fmt.Errorf("errors occurred during processing:\n%s", strings.Join(errorMessages, "\n")) + return nil, nil, nil, fmt.Errorf("errors occurred during processing:\n%s", strings.Join(errorMessages, "\n")) } - return labels, txLabels, nil + return labels, txLabels, rawTransactions, nil } func (c *Client) DecodeProtoTransactionsToLabels(transactions []string, blocksCache map[uint64]uint64, abiMap map[string]map[string]*indexer.AbiEntry) ([]indexer.TransactionLabel, error) { diff --git a/blockchain/mantle_sepolia/mantle_sepolia.go b/blockchain/mantle_sepolia/mantle_sepolia.go index d82d870..ee2bd01 100644 --- a/blockchain/mantle_sepolia/mantle_sepolia.go +++ b/blockchain/mantle_sepolia/mantle_sepolia.go @@ -652,19 +652,20 @@ func (c *Client) DecodeProtoEntireBlockToJson(rawData *bytes.Buffer) (*seer_comm return blocksBatchJson, nil } -func (c *Client) DecodeProtoEntireBlockToLabels(rawData *bytes.Buffer, abiMap map[string]map[string]*indexer.AbiEntry, threads int) ([]indexer.EventLabel, []indexer.TransactionLabel, error) { +func (c *Client) DecodeProtoEntireBlockToLabels(rawData *bytes.Buffer, abiMap map[string]map[string]*indexer.AbiEntry, threads int) ([]indexer.EventLabel, []indexer.TransactionLabel, []indexer.RawTransaction, error) { var protoBlocksBatch MantleSepoliaBlocksBatch dataBytes := rawData.Bytes() err := proto.Unmarshal(dataBytes, &protoBlocksBatch) if err != nil { - return nil, nil, fmt.Errorf("failed to unmarshal data: %v", err) + return nil, nil, nil, fmt.Errorf("failed to unmarshal data: %v", err) } // Shared slices to collect labels var labels []indexer.EventLabel var txLabels []indexer.TransactionLabel + var rawTransactions []indexer.RawTransaction var labelsMutex sync.Mutex var decodeErr error @@ -689,7 +690,7 @@ func (c *Client) DecodeProtoEntireBlockToLabels(rawData *bytes.Buffer, abiMap ma // Local slices to collect labels for this block var localEventLabels []indexer.EventLabel var localTxLabels []indexer.TransactionLabel - + localRawTransactions := make(map[string]indexer.RawTransaction) for _, tx := range b.Transactions { var decodedArgsTx map[string]interface{} @@ -757,6 +758,24 @@ func (c *Client) DecodeProtoEntireBlockToLabels(rawData *bytes.Buffer, abiMap ma continue } + localRawTransactions[tx.Hash] = indexer.RawTransaction{ + Hash: tx.Hash, + BlockHash: b.Hash, + BlockTimestamp: b.Timestamp, + BlockNumber: tx.BlockNumber, + FromAddress: tx.FromAddress, + ToAddress: tx.ToAddress, + Gas: tx.Gas, + GasPrice: tx.GasPrice, + Input: tx.Input, + Nonce: tx.Nonce, + MaxFeePerGas: tx.MaxFeePerGas, + MaxPriorityFeePerGas: tx.MaxPriorityFeePerGas, + TransactionIndex: tx.TransactionIndex, + TransactionType: tx.TransactionType, + Value: tx.Value, + } + // Convert transaction to label transactionLabel := indexer.TransactionLabel{ Address: tx.ToAddress, @@ -825,6 +844,25 @@ func (c *Client) DecodeProtoEntireBlockToLabels(rawData *bytes.Buffer, abiMap ma errorChan <- fmt.Errorf("error converting decodedArgsLogs to JSON for tx %s: %v", e.TransactionHash, err) continue } + if _, exists := localRawTransactions[e.TransactionHash]; !exists { + localRawTransactions[e.TransactionHash] = indexer.RawTransaction{ + Hash: tx.Hash, + BlockHash: b.Hash, + BlockTimestamp: b.Timestamp, + BlockNumber: tx.BlockNumber, + FromAddress: tx.FromAddress, + ToAddress: tx.ToAddress, + Gas: tx.Gas, + GasPrice: tx.GasPrice, + Input: tx.Input, + Nonce: tx.Nonce, + MaxFeePerGas: tx.MaxFeePerGas, + MaxPriorityFeePerGas: tx.MaxPriorityFeePerGas, + TransactionIndex: tx.TransactionIndex, + TransactionType: tx.TransactionType, + Value: tx.Value, + } + } // Convert event to label eventLabel := indexer.EventLabel{ Label: label, @@ -848,6 +886,9 @@ func (c *Client) DecodeProtoEntireBlockToLabels(rawData *bytes.Buffer, abiMap ma labelsMutex.Lock() labels = append(labels, localEventLabels...) txLabels = append(txLabels, localTxLabels...) + for _, rawTransaction := range localRawTransactions { + rawTransactions = append(rawTransactions, rawTransaction) + } labelsMutex.Unlock() }(b) } @@ -863,10 +904,10 @@ func (c *Client) DecodeProtoEntireBlockToLabels(rawData *bytes.Buffer, abiMap ma // If any errors occurred, return them if len(errorMessages) > 0 { - return nil, nil, fmt.Errorf("errors occurred during processing:\n%s", strings.Join(errorMessages, "\n")) + return nil, nil, nil, fmt.Errorf("errors occurred during processing:\n%s", strings.Join(errorMessages, "\n")) } - return labels, txLabels, nil + return labels, txLabels, rawTransactions, nil } func (c *Client) DecodeProtoTransactionsToLabels(transactions []string, blocksCache map[uint64]uint64, abiMap map[string]map[string]*indexer.AbiEntry) ([]indexer.TransactionLabel, error) { diff --git a/blockchain/polygon/polygon.go b/blockchain/polygon/polygon.go index 69ae2a1..fa4c39b 100644 --- a/blockchain/polygon/polygon.go +++ b/blockchain/polygon/polygon.go @@ -652,19 +652,20 @@ func (c *Client) DecodeProtoEntireBlockToJson(rawData *bytes.Buffer) (*seer_comm return blocksBatchJson, nil } -func (c *Client) DecodeProtoEntireBlockToLabels(rawData *bytes.Buffer, abiMap map[string]map[string]*indexer.AbiEntry, threads int) ([]indexer.EventLabel, []indexer.TransactionLabel, error) { +func (c *Client) DecodeProtoEntireBlockToLabels(rawData *bytes.Buffer, abiMap map[string]map[string]*indexer.AbiEntry, threads int) ([]indexer.EventLabel, []indexer.TransactionLabel, []indexer.RawTransaction, error) { var protoBlocksBatch PolygonBlocksBatch dataBytes := rawData.Bytes() err := proto.Unmarshal(dataBytes, &protoBlocksBatch) if err != nil { - return nil, nil, fmt.Errorf("failed to unmarshal data: %v", err) + return nil, nil, nil, fmt.Errorf("failed to unmarshal data: %v", err) } // Shared slices to collect labels var labels []indexer.EventLabel var txLabels []indexer.TransactionLabel + var rawTransactions []indexer.RawTransaction var labelsMutex sync.Mutex var decodeErr error @@ -689,7 +690,7 @@ func (c *Client) DecodeProtoEntireBlockToLabels(rawData *bytes.Buffer, abiMap ma // Local slices to collect labels for this block var localEventLabels []indexer.EventLabel var localTxLabels []indexer.TransactionLabel - + localRawTransactions := make(map[string]indexer.RawTransaction) for _, tx := range b.Transactions { var decodedArgsTx map[string]interface{} @@ -757,6 +758,24 @@ func (c *Client) DecodeProtoEntireBlockToLabels(rawData *bytes.Buffer, abiMap ma continue } + localRawTransactions[tx.Hash] = indexer.RawTransaction{ + Hash: tx.Hash, + BlockHash: b.Hash, + BlockTimestamp: b.Timestamp, + BlockNumber: tx.BlockNumber, + FromAddress: tx.FromAddress, + ToAddress: tx.ToAddress, + Gas: tx.Gas, + GasPrice: tx.GasPrice, + Input: tx.Input, + Nonce: tx.Nonce, + MaxFeePerGas: tx.MaxFeePerGas, + MaxPriorityFeePerGas: tx.MaxPriorityFeePerGas, + TransactionIndex: tx.TransactionIndex, + TransactionType: tx.TransactionType, + Value: tx.Value, + } + // Convert transaction to label transactionLabel := indexer.TransactionLabel{ Address: tx.ToAddress, @@ -825,6 +844,25 @@ func (c *Client) DecodeProtoEntireBlockToLabels(rawData *bytes.Buffer, abiMap ma errorChan <- fmt.Errorf("error converting decodedArgsLogs to JSON for tx %s: %v", e.TransactionHash, err) continue } + if _, exists := localRawTransactions[e.TransactionHash]; !exists { + localRawTransactions[e.TransactionHash] = indexer.RawTransaction{ + Hash: tx.Hash, + BlockHash: b.Hash, + BlockTimestamp: b.Timestamp, + BlockNumber: tx.BlockNumber, + FromAddress: tx.FromAddress, + ToAddress: tx.ToAddress, + Gas: tx.Gas, + GasPrice: tx.GasPrice, + Input: tx.Input, + Nonce: tx.Nonce, + MaxFeePerGas: tx.MaxFeePerGas, + MaxPriorityFeePerGas: tx.MaxPriorityFeePerGas, + TransactionIndex: tx.TransactionIndex, + TransactionType: tx.TransactionType, + Value: tx.Value, + } + } // Convert event to label eventLabel := indexer.EventLabel{ Label: label, @@ -848,6 +886,9 @@ func (c *Client) DecodeProtoEntireBlockToLabels(rawData *bytes.Buffer, abiMap ma labelsMutex.Lock() labels = append(labels, localEventLabels...) txLabels = append(txLabels, localTxLabels...) + for _, rawTransaction := range localRawTransactions { + rawTransactions = append(rawTransactions, rawTransaction) + } labelsMutex.Unlock() }(b) } @@ -863,10 +904,10 @@ func (c *Client) DecodeProtoEntireBlockToLabels(rawData *bytes.Buffer, abiMap ma // If any errors occurred, return them if len(errorMessages) > 0 { - return nil, nil, fmt.Errorf("errors occurred during processing:\n%s", strings.Join(errorMessages, "\n")) + return nil, nil, nil, fmt.Errorf("errors occurred during processing:\n%s", strings.Join(errorMessages, "\n")) } - return labels, txLabels, nil + return labels, txLabels, rawTransactions, nil } func (c *Client) DecodeProtoTransactionsToLabels(transactions []string, blocksCache map[uint64]uint64, abiMap map[string]map[string]*indexer.AbiEntry) ([]indexer.TransactionLabel, error) { diff --git a/blockchain/ronin/ronin.go b/blockchain/ronin/ronin.go index 8899a56..1b66265 100644 --- a/blockchain/ronin/ronin.go +++ b/blockchain/ronin/ronin.go @@ -652,19 +652,20 @@ func (c *Client) DecodeProtoEntireBlockToJson(rawData *bytes.Buffer) (*seer_comm return blocksBatchJson, nil } -func (c *Client) DecodeProtoEntireBlockToLabels(rawData *bytes.Buffer, abiMap map[string]map[string]*indexer.AbiEntry, threads int) ([]indexer.EventLabel, []indexer.TransactionLabel, error) { +func (c *Client) DecodeProtoEntireBlockToLabels(rawData *bytes.Buffer, abiMap map[string]map[string]*indexer.AbiEntry, threads int) ([]indexer.EventLabel, []indexer.TransactionLabel, []indexer.RawTransaction, error) { var protoBlocksBatch RoninBlocksBatch dataBytes := rawData.Bytes() err := proto.Unmarshal(dataBytes, &protoBlocksBatch) if err != nil { - return nil, nil, fmt.Errorf("failed to unmarshal data: %v", err) + return nil, nil, nil, fmt.Errorf("failed to unmarshal data: %v", err) } // Shared slices to collect labels var labels []indexer.EventLabel var txLabels []indexer.TransactionLabel + var rawTransactions []indexer.RawTransaction var labelsMutex sync.Mutex var decodeErr error @@ -689,7 +690,7 @@ func (c *Client) DecodeProtoEntireBlockToLabels(rawData *bytes.Buffer, abiMap ma // Local slices to collect labels for this block var localEventLabels []indexer.EventLabel var localTxLabels []indexer.TransactionLabel - + localRawTransactions := make(map[string]indexer.RawTransaction) for _, tx := range b.Transactions { var decodedArgsTx map[string]interface{} @@ -757,6 +758,24 @@ func (c *Client) DecodeProtoEntireBlockToLabels(rawData *bytes.Buffer, abiMap ma continue } + localRawTransactions[tx.Hash] = indexer.RawTransaction{ + Hash: tx.Hash, + BlockHash: b.Hash, + BlockTimestamp: b.Timestamp, + BlockNumber: tx.BlockNumber, + FromAddress: tx.FromAddress, + ToAddress: tx.ToAddress, + Gas: tx.Gas, + GasPrice: tx.GasPrice, + Input: tx.Input, + Nonce: tx.Nonce, + MaxFeePerGas: tx.MaxFeePerGas, + MaxPriorityFeePerGas: tx.MaxPriorityFeePerGas, + TransactionIndex: tx.TransactionIndex, + TransactionType: tx.TransactionType, + Value: tx.Value, + } + // Convert transaction to label transactionLabel := indexer.TransactionLabel{ Address: tx.ToAddress, @@ -825,6 +844,25 @@ func (c *Client) DecodeProtoEntireBlockToLabels(rawData *bytes.Buffer, abiMap ma errorChan <- fmt.Errorf("error converting decodedArgsLogs to JSON for tx %s: %v", e.TransactionHash, err) continue } + if _, exists := localRawTransactions[e.TransactionHash]; !exists { + localRawTransactions[e.TransactionHash] = indexer.RawTransaction{ + Hash: tx.Hash, + BlockHash: b.Hash, + BlockTimestamp: b.Timestamp, + BlockNumber: tx.BlockNumber, + FromAddress: tx.FromAddress, + ToAddress: tx.ToAddress, + Gas: tx.Gas, + GasPrice: tx.GasPrice, + Input: tx.Input, + Nonce: tx.Nonce, + MaxFeePerGas: tx.MaxFeePerGas, + MaxPriorityFeePerGas: tx.MaxPriorityFeePerGas, + TransactionIndex: tx.TransactionIndex, + TransactionType: tx.TransactionType, + Value: tx.Value, + } + } // Convert event to label eventLabel := indexer.EventLabel{ Label: label, @@ -848,6 +886,9 @@ func (c *Client) DecodeProtoEntireBlockToLabels(rawData *bytes.Buffer, abiMap ma labelsMutex.Lock() labels = append(labels, localEventLabels...) txLabels = append(txLabels, localTxLabels...) + for _, rawTransaction := range localRawTransactions { + rawTransactions = append(rawTransactions, rawTransaction) + } labelsMutex.Unlock() }(b) } @@ -863,10 +904,10 @@ func (c *Client) DecodeProtoEntireBlockToLabels(rawData *bytes.Buffer, abiMap ma // If any errors occurred, return them if len(errorMessages) > 0 { - return nil, nil, fmt.Errorf("errors occurred during processing:\n%s", strings.Join(errorMessages, "\n")) + return nil, nil, nil, fmt.Errorf("errors occurred during processing:\n%s", strings.Join(errorMessages, "\n")) } - return labels, txLabels, nil + return labels, txLabels, rawTransactions, nil } func (c *Client) DecodeProtoTransactionsToLabels(transactions []string, blocksCache map[uint64]uint64, abiMap map[string]map[string]*indexer.AbiEntry) ([]indexer.TransactionLabel, error) { diff --git a/blockchain/ronin_saigon/ronin_saigon.go b/blockchain/ronin_saigon/ronin_saigon.go index f45b56f..647a46c 100644 --- a/blockchain/ronin_saigon/ronin_saigon.go +++ b/blockchain/ronin_saigon/ronin_saigon.go @@ -652,19 +652,20 @@ func (c *Client) DecodeProtoEntireBlockToJson(rawData *bytes.Buffer) (*seer_comm return blocksBatchJson, nil } -func (c *Client) DecodeProtoEntireBlockToLabels(rawData *bytes.Buffer, abiMap map[string]map[string]*indexer.AbiEntry, threads int) ([]indexer.EventLabel, []indexer.TransactionLabel, error) { +func (c *Client) DecodeProtoEntireBlockToLabels(rawData *bytes.Buffer, abiMap map[string]map[string]*indexer.AbiEntry, threads int) ([]indexer.EventLabel, []indexer.TransactionLabel, []indexer.RawTransaction, error) { var protoBlocksBatch RoninSaigonBlocksBatch dataBytes := rawData.Bytes() err := proto.Unmarshal(dataBytes, &protoBlocksBatch) if err != nil { - return nil, nil, fmt.Errorf("failed to unmarshal data: %v", err) + return nil, nil, nil, fmt.Errorf("failed to unmarshal data: %v", err) } // Shared slices to collect labels var labels []indexer.EventLabel var txLabels []indexer.TransactionLabel + var rawTransactions []indexer.RawTransaction var labelsMutex sync.Mutex var decodeErr error @@ -689,7 +690,7 @@ func (c *Client) DecodeProtoEntireBlockToLabels(rawData *bytes.Buffer, abiMap ma // Local slices to collect labels for this block var localEventLabels []indexer.EventLabel var localTxLabels []indexer.TransactionLabel - + localRawTransactions := make(map[string]indexer.RawTransaction) for _, tx := range b.Transactions { var decodedArgsTx map[string]interface{} @@ -757,6 +758,24 @@ func (c *Client) DecodeProtoEntireBlockToLabels(rawData *bytes.Buffer, abiMap ma continue } + localRawTransactions[tx.Hash] = indexer.RawTransaction{ + Hash: tx.Hash, + BlockHash: b.Hash, + BlockTimestamp: b.Timestamp, + BlockNumber: tx.BlockNumber, + FromAddress: tx.FromAddress, + ToAddress: tx.ToAddress, + Gas: tx.Gas, + GasPrice: tx.GasPrice, + Input: tx.Input, + Nonce: tx.Nonce, + MaxFeePerGas: tx.MaxFeePerGas, + MaxPriorityFeePerGas: tx.MaxPriorityFeePerGas, + TransactionIndex: tx.TransactionIndex, + TransactionType: tx.TransactionType, + Value: tx.Value, + } + // Convert transaction to label transactionLabel := indexer.TransactionLabel{ Address: tx.ToAddress, @@ -825,6 +844,25 @@ func (c *Client) DecodeProtoEntireBlockToLabels(rawData *bytes.Buffer, abiMap ma errorChan <- fmt.Errorf("error converting decodedArgsLogs to JSON for tx %s: %v", e.TransactionHash, err) continue } + if _, exists := localRawTransactions[e.TransactionHash]; !exists { + localRawTransactions[e.TransactionHash] = indexer.RawTransaction{ + Hash: tx.Hash, + BlockHash: b.Hash, + BlockTimestamp: b.Timestamp, + BlockNumber: tx.BlockNumber, + FromAddress: tx.FromAddress, + ToAddress: tx.ToAddress, + Gas: tx.Gas, + GasPrice: tx.GasPrice, + Input: tx.Input, + Nonce: tx.Nonce, + MaxFeePerGas: tx.MaxFeePerGas, + MaxPriorityFeePerGas: tx.MaxPriorityFeePerGas, + TransactionIndex: tx.TransactionIndex, + TransactionType: tx.TransactionType, + Value: tx.Value, + } + } // Convert event to label eventLabel := indexer.EventLabel{ Label: label, @@ -848,6 +886,9 @@ func (c *Client) DecodeProtoEntireBlockToLabels(rawData *bytes.Buffer, abiMap ma labelsMutex.Lock() labels = append(labels, localEventLabels...) txLabels = append(txLabels, localTxLabels...) + for _, rawTransaction := range localRawTransactions { + rawTransactions = append(rawTransactions, rawTransaction) + } labelsMutex.Unlock() }(b) } @@ -863,10 +904,10 @@ func (c *Client) DecodeProtoEntireBlockToLabels(rawData *bytes.Buffer, abiMap ma // If any errors occurred, return them if len(errorMessages) > 0 { - return nil, nil, fmt.Errorf("errors occurred during processing:\n%s", strings.Join(errorMessages, "\n")) + return nil, nil, nil, fmt.Errorf("errors occurred during processing:\n%s", strings.Join(errorMessages, "\n")) } - return labels, txLabels, nil + return labels, txLabels, rawTransactions, nil } func (c *Client) DecodeProtoTransactionsToLabels(transactions []string, blocksCache map[uint64]uint64, abiMap map[string]map[string]*indexer.AbiEntry) ([]indexer.TransactionLabel, error) { diff --git a/blockchain/sepolia/sepolia.go b/blockchain/sepolia/sepolia.go index 895847a..e8d21c7 100644 --- a/blockchain/sepolia/sepolia.go +++ b/blockchain/sepolia/sepolia.go @@ -652,19 +652,20 @@ func (c *Client) DecodeProtoEntireBlockToJson(rawData *bytes.Buffer) (*seer_comm return blocksBatchJson, nil } -func (c *Client) DecodeProtoEntireBlockToLabels(rawData *bytes.Buffer, abiMap map[string]map[string]*indexer.AbiEntry, threads int) ([]indexer.EventLabel, []indexer.TransactionLabel, error) { +func (c *Client) DecodeProtoEntireBlockToLabels(rawData *bytes.Buffer, abiMap map[string]map[string]*indexer.AbiEntry, threads int) ([]indexer.EventLabel, []indexer.TransactionLabel, []indexer.RawTransaction, error) { var protoBlocksBatch SepoliaBlocksBatch dataBytes := rawData.Bytes() err := proto.Unmarshal(dataBytes, &protoBlocksBatch) if err != nil { - return nil, nil, fmt.Errorf("failed to unmarshal data: %v", err) + return nil, nil, nil, fmt.Errorf("failed to unmarshal data: %v", err) } // Shared slices to collect labels var labels []indexer.EventLabel var txLabels []indexer.TransactionLabel + var rawTransactions []indexer.RawTransaction var labelsMutex sync.Mutex var decodeErr error @@ -689,7 +690,7 @@ func (c *Client) DecodeProtoEntireBlockToLabels(rawData *bytes.Buffer, abiMap ma // Local slices to collect labels for this block var localEventLabels []indexer.EventLabel var localTxLabels []indexer.TransactionLabel - + localRawTransactions := make(map[string]indexer.RawTransaction) for _, tx := range b.Transactions { var decodedArgsTx map[string]interface{} @@ -757,6 +758,24 @@ func (c *Client) DecodeProtoEntireBlockToLabels(rawData *bytes.Buffer, abiMap ma continue } + localRawTransactions[tx.Hash] = indexer.RawTransaction{ + Hash: tx.Hash, + BlockHash: b.Hash, + BlockTimestamp: b.Timestamp, + BlockNumber: tx.BlockNumber, + FromAddress: tx.FromAddress, + ToAddress: tx.ToAddress, + Gas: tx.Gas, + GasPrice: tx.GasPrice, + Input: tx.Input, + Nonce: tx.Nonce, + MaxFeePerGas: tx.MaxFeePerGas, + MaxPriorityFeePerGas: tx.MaxPriorityFeePerGas, + TransactionIndex: tx.TransactionIndex, + TransactionType: tx.TransactionType, + Value: tx.Value, + } + // Convert transaction to label transactionLabel := indexer.TransactionLabel{ Address: tx.ToAddress, @@ -825,6 +844,25 @@ func (c *Client) DecodeProtoEntireBlockToLabels(rawData *bytes.Buffer, abiMap ma errorChan <- fmt.Errorf("error converting decodedArgsLogs to JSON for tx %s: %v", e.TransactionHash, err) continue } + if _, exists := localRawTransactions[e.TransactionHash]; !exists { + localRawTransactions[e.TransactionHash] = indexer.RawTransaction{ + Hash: tx.Hash, + BlockHash: b.Hash, + BlockTimestamp: b.Timestamp, + BlockNumber: tx.BlockNumber, + FromAddress: tx.FromAddress, + ToAddress: tx.ToAddress, + Gas: tx.Gas, + GasPrice: tx.GasPrice, + Input: tx.Input, + Nonce: tx.Nonce, + MaxFeePerGas: tx.MaxFeePerGas, + MaxPriorityFeePerGas: tx.MaxPriorityFeePerGas, + TransactionIndex: tx.TransactionIndex, + TransactionType: tx.TransactionType, + Value: tx.Value, + } + } // Convert event to label eventLabel := indexer.EventLabel{ Label: label, @@ -848,6 +886,9 @@ func (c *Client) DecodeProtoEntireBlockToLabels(rawData *bytes.Buffer, abiMap ma labelsMutex.Lock() labels = append(labels, localEventLabels...) txLabels = append(txLabels, localTxLabels...) + for _, rawTransaction := range localRawTransactions { + rawTransactions = append(rawTransactions, rawTransaction) + } labelsMutex.Unlock() }(b) } @@ -863,10 +904,10 @@ func (c *Client) DecodeProtoEntireBlockToLabels(rawData *bytes.Buffer, abiMap ma // If any errors occurred, return them if len(errorMessages) > 0 { - return nil, nil, fmt.Errorf("errors occurred during processing:\n%s", strings.Join(errorMessages, "\n")) + return nil, nil, nil, fmt.Errorf("errors occurred during processing:\n%s", strings.Join(errorMessages, "\n")) } - return labels, txLabels, nil + return labels, txLabels, rawTransactions, nil } func (c *Client) DecodeProtoTransactionsToLabels(transactions []string, blocksCache map[uint64]uint64, abiMap map[string]map[string]*indexer.AbiEntry) ([]indexer.TransactionLabel, error) { diff --git a/blockchain/xai/xai.go b/blockchain/xai/xai.go index b2dccf4..3b14ebd 100644 --- a/blockchain/xai/xai.go +++ b/blockchain/xai/xai.go @@ -662,19 +662,20 @@ func (c *Client) DecodeProtoEntireBlockToJson(rawData *bytes.Buffer) (*seer_comm return blocksBatchJson, nil } -func (c *Client) DecodeProtoEntireBlockToLabels(rawData *bytes.Buffer, abiMap map[string]map[string]*indexer.AbiEntry, threads int) ([]indexer.EventLabel, []indexer.TransactionLabel, error) { +func (c *Client) DecodeProtoEntireBlockToLabels(rawData *bytes.Buffer, abiMap map[string]map[string]*indexer.AbiEntry, threads int) ([]indexer.EventLabel, []indexer.TransactionLabel, []indexer.RawTransaction, error) { var protoBlocksBatch XaiBlocksBatch dataBytes := rawData.Bytes() err := proto.Unmarshal(dataBytes, &protoBlocksBatch) if err != nil { - return nil, nil, fmt.Errorf("failed to unmarshal data: %v", err) + return nil, nil, nil, fmt.Errorf("failed to unmarshal data: %v", err) } // Shared slices to collect labels var labels []indexer.EventLabel var txLabels []indexer.TransactionLabel + var rawTransactions []indexer.RawTransaction var labelsMutex sync.Mutex var decodeErr error @@ -699,7 +700,7 @@ func (c *Client) DecodeProtoEntireBlockToLabels(rawData *bytes.Buffer, abiMap ma // Local slices to collect labels for this block var localEventLabels []indexer.EventLabel var localTxLabels []indexer.TransactionLabel - + localRawTransactions := make(map[string]indexer.RawTransaction) for _, tx := range b.Transactions { var decodedArgsTx map[string]interface{} @@ -767,6 +768,25 @@ func (c *Client) DecodeProtoEntireBlockToLabels(rawData *bytes.Buffer, abiMap ma continue } + localRawTransactions[tx.Hash] = indexer.RawTransaction{ + Hash: tx.Hash, + BlockHash: b.Hash, + BlockTimestamp: b.Timestamp, + BlockNumber: tx.BlockNumber, + FromAddress: tx.FromAddress, + ToAddress: tx.ToAddress, + Gas: tx.Gas, + GasPrice: tx.GasPrice, + Input: tx.Input, + Nonce: tx.Nonce, + MaxFeePerGas: tx.MaxFeePerGas, + MaxPriorityFeePerGas: tx.MaxPriorityFeePerGas, + TransactionIndex: tx.TransactionIndex, + TransactionType: tx.TransactionType, + Value: tx.Value, + L1BlockNumber: &b.L1BlockNumber, + } + // Convert transaction to label transactionLabel := indexer.TransactionLabel{ Address: tx.ToAddress, @@ -835,6 +855,26 @@ func (c *Client) DecodeProtoEntireBlockToLabels(rawData *bytes.Buffer, abiMap ma errorChan <- fmt.Errorf("error converting decodedArgsLogs to JSON for tx %s: %v", e.TransactionHash, err) continue } + if _, exists := localRawTransactions[e.TransactionHash]; !exists { + localRawTransactions[e.TransactionHash] = indexer.RawTransaction{ + Hash: tx.Hash, + BlockHash: b.Hash, + BlockTimestamp: b.Timestamp, + BlockNumber: tx.BlockNumber, + FromAddress: tx.FromAddress, + ToAddress: tx.ToAddress, + Gas: tx.Gas, + GasPrice: tx.GasPrice, + Input: tx.Input, + Nonce: tx.Nonce, + MaxFeePerGas: tx.MaxFeePerGas, + MaxPriorityFeePerGas: tx.MaxPriorityFeePerGas, + TransactionIndex: tx.TransactionIndex, + TransactionType: tx.TransactionType, + Value: tx.Value, + L1BlockNumber: &b.L1BlockNumber, + } + } // Convert event to label eventLabel := indexer.EventLabel{ Label: label, @@ -858,6 +898,9 @@ func (c *Client) DecodeProtoEntireBlockToLabels(rawData *bytes.Buffer, abiMap ma labelsMutex.Lock() labels = append(labels, localEventLabels...) txLabels = append(txLabels, localTxLabels...) + for _, rawTransaction := range localRawTransactions { + rawTransactions = append(rawTransactions, rawTransaction) + } labelsMutex.Unlock() }(b) } @@ -873,10 +916,10 @@ func (c *Client) DecodeProtoEntireBlockToLabels(rawData *bytes.Buffer, abiMap ma // If any errors occurred, return them if len(errorMessages) > 0 { - return nil, nil, fmt.Errorf("errors occurred during processing:\n%s", strings.Join(errorMessages, "\n")) + return nil, nil, nil, fmt.Errorf("errors occurred during processing:\n%s", strings.Join(errorMessages, "\n")) } - return labels, txLabels, nil + return labels, txLabels, rawTransactions, nil } func (c *Client) DecodeProtoTransactionsToLabels(transactions []string, blocksCache map[uint64]uint64, abiMap map[string]map[string]*indexer.AbiEntry) ([]indexer.TransactionLabel, error) { diff --git a/blockchain/xai_sepolia/xai_sepolia.go b/blockchain/xai_sepolia/xai_sepolia.go index d2b5518..8010174 100644 --- a/blockchain/xai_sepolia/xai_sepolia.go +++ b/blockchain/xai_sepolia/xai_sepolia.go @@ -662,19 +662,20 @@ func (c *Client) DecodeProtoEntireBlockToJson(rawData *bytes.Buffer) (*seer_comm return blocksBatchJson, nil } -func (c *Client) DecodeProtoEntireBlockToLabels(rawData *bytes.Buffer, abiMap map[string]map[string]*indexer.AbiEntry, threads int) ([]indexer.EventLabel, []indexer.TransactionLabel, error) { +func (c *Client) DecodeProtoEntireBlockToLabels(rawData *bytes.Buffer, abiMap map[string]map[string]*indexer.AbiEntry, threads int) ([]indexer.EventLabel, []indexer.TransactionLabel, []indexer.RawTransaction, error) { var protoBlocksBatch XaiSepoliaBlocksBatch dataBytes := rawData.Bytes() err := proto.Unmarshal(dataBytes, &protoBlocksBatch) if err != nil { - return nil, nil, fmt.Errorf("failed to unmarshal data: %v", err) + return nil, nil, nil, fmt.Errorf("failed to unmarshal data: %v", err) } // Shared slices to collect labels var labels []indexer.EventLabel var txLabels []indexer.TransactionLabel + var rawTransactions []indexer.RawTransaction var labelsMutex sync.Mutex var decodeErr error @@ -699,7 +700,7 @@ func (c *Client) DecodeProtoEntireBlockToLabels(rawData *bytes.Buffer, abiMap ma // Local slices to collect labels for this block var localEventLabels []indexer.EventLabel var localTxLabels []indexer.TransactionLabel - + localRawTransactions := make(map[string]indexer.RawTransaction) for _, tx := range b.Transactions { var decodedArgsTx map[string]interface{} @@ -767,6 +768,25 @@ func (c *Client) DecodeProtoEntireBlockToLabels(rawData *bytes.Buffer, abiMap ma continue } + localRawTransactions[tx.Hash] = indexer.RawTransaction{ + Hash: tx.Hash, + BlockHash: b.Hash, + BlockTimestamp: b.Timestamp, + BlockNumber: tx.BlockNumber, + FromAddress: tx.FromAddress, + ToAddress: tx.ToAddress, + Gas: tx.Gas, + GasPrice: tx.GasPrice, + Input: tx.Input, + Nonce: tx.Nonce, + MaxFeePerGas: tx.MaxFeePerGas, + MaxPriorityFeePerGas: tx.MaxPriorityFeePerGas, + TransactionIndex: tx.TransactionIndex, + TransactionType: tx.TransactionType, + Value: tx.Value, + L1BlockNumber: &b.L1BlockNumber, + } + // Convert transaction to label transactionLabel := indexer.TransactionLabel{ Address: tx.ToAddress, @@ -835,6 +855,26 @@ func (c *Client) DecodeProtoEntireBlockToLabels(rawData *bytes.Buffer, abiMap ma errorChan <- fmt.Errorf("error converting decodedArgsLogs to JSON for tx %s: %v", e.TransactionHash, err) continue } + if _, exists := localRawTransactions[e.TransactionHash]; !exists { + localRawTransactions[e.TransactionHash] = indexer.RawTransaction{ + Hash: tx.Hash, + BlockHash: b.Hash, + BlockTimestamp: b.Timestamp, + BlockNumber: tx.BlockNumber, + FromAddress: tx.FromAddress, + ToAddress: tx.ToAddress, + Gas: tx.Gas, + GasPrice: tx.GasPrice, + Input: tx.Input, + Nonce: tx.Nonce, + MaxFeePerGas: tx.MaxFeePerGas, + MaxPriorityFeePerGas: tx.MaxPriorityFeePerGas, + TransactionIndex: tx.TransactionIndex, + TransactionType: tx.TransactionType, + Value: tx.Value, + L1BlockNumber: &b.L1BlockNumber, + } + } // Convert event to label eventLabel := indexer.EventLabel{ Label: label, @@ -858,6 +898,9 @@ func (c *Client) DecodeProtoEntireBlockToLabels(rawData *bytes.Buffer, abiMap ma labelsMutex.Lock() labels = append(labels, localEventLabels...) txLabels = append(txLabels, localTxLabels...) + for _, rawTransaction := range localRawTransactions { + rawTransactions = append(rawTransactions, rawTransaction) + } labelsMutex.Unlock() }(b) } @@ -873,10 +916,10 @@ func (c *Client) DecodeProtoEntireBlockToLabels(rawData *bytes.Buffer, abiMap ma // If any errors occurred, return them if len(errorMessages) > 0 { - return nil, nil, fmt.Errorf("errors occurred during processing:\n%s", strings.Join(errorMessages, "\n")) + return nil, nil, nil, fmt.Errorf("errors occurred during processing:\n%s", strings.Join(errorMessages, "\n")) } - return labels, txLabels, nil + return labels, txLabels, rawTransactions, nil } func (c *Client) DecodeProtoTransactionsToLabels(transactions []string, blocksCache map[uint64]uint64, abiMap map[string]map[string]*indexer.AbiEntry) ([]indexer.TransactionLabel, error) { diff --git a/cmd.go b/cmd.go index 4dd3744..6f5c312 100644 --- a/cmd.go +++ b/cmd.go @@ -417,21 +417,25 @@ func CreateInspectorCommand() *cobra.Command { targetFilePath := filepath.Join(basePath, batch, "data.proto") rawData, readErr := storageInstance.Read(targetFilePath) if readErr != nil { + log.Printf("Failed to read proto file: %v", readErr) return readErr } client, cleintErr := seer_blockchain.NewClient(chain, crawler.BlockchainURLs[chain], timeout) if cleintErr != nil { + log.Printf("Failed to create client: %v", cleintErr) return cleintErr } output, decErr := client.DecodeProtoEntireBlockToJson(&rawData) if decErr != nil { + log.Printf("Failed to decode proto file: %v", decErr) return decErr } jsonOutput, marErr := json.Marshal(output) if marErr != nil { + log.Printf("Failed to marshal json: %v", marErr) return marErr } diff --git a/go.mod b/go.mod index 3ade577..4a12913 100644 --- a/go.mod +++ b/go.mod @@ -28,6 +28,7 @@ require ( github.com/StackExchange/wmi v1.2.1 // indirect github.com/bits-and-blooms/bitset v1.13.0 // indirect github.com/btcsuite/btcd/btcec/v2 v2.3.4 // indirect + github.com/bugout-dev/bugout-go v0.4.6 // indirect github.com/consensys/bavard v0.1.13 // indirect github.com/consensys/gnark-crypto v0.12.1 // indirect github.com/crate-crypto/go-ipa v0.0.0-20240223125850-b1e8a79f509c // indirect diff --git a/go.sum b/go.sum index e51d5aa..6d900f9 100644 --- a/go.sum +++ b/go.sum @@ -1,36 +1,62 @@ cloud.google.com/go v0.26.0/go.mod h1:aQUYkXzVsufM+DwF1aE+0xfcU+56JwCaLick0ClmMTw= +cloud.google.com/go v0.34.0/go.mod h1:aQUYkXzVsufM+DwF1aE+0xfcU+56JwCaLick0ClmMTw= +cloud.google.com/go v0.38.0/go.mod h1:990N+gfupTy94rShfmMCWGDn0LpTmnzTp2qbd1dvSRU= +cloud.google.com/go v0.44.1/go.mod h1:iSa0KzasP4Uvy3f1mN/7PiObzGgflwredwwASm/v6AU= +cloud.google.com/go v0.44.2/go.mod h1:60680Gw3Yr4ikxnPRS/oxxkBccT6SA1yMk63TGekxKY= +cloud.google.com/go v0.45.1/go.mod h1:RpBamKRgapWJb87xiFSdk4g1CME7QZg3uwTez+TSTjc= +cloud.google.com/go v0.46.3/go.mod h1:a6bKKbmY7er1mI7TEI4lsAkts/mkhTSZK8w33B4RAg0= cloud.google.com/go v0.112.1 h1:uJSeirPke5UNZHIb4SxfZklVSiWWVqW4oXlETwZziwM= cloud.google.com/go v0.112.1/go.mod h1:+Vbu+Y1UU+I1rjmzeMOb/8RfkKJK2Gyxi1X6jJCZLo4= +cloud.google.com/go/bigquery v1.0.1/go.mod h1:i/xbL2UlR5RvWAURpBYZTtm/cXjCha9lbfbpx4poX+o= cloud.google.com/go/compute v1.24.0 h1:phWcR2eWzRJaL/kOiJwfFsPs4BaKq1j6vnpZrc1YlVg= cloud.google.com/go/compute v1.24.0/go.mod h1:kw1/T+h/+tK2LJK0wiPPx1intgdAM3j/g3hFDlscY40= cloud.google.com/go/compute/metadata v0.2.3 h1:mg4jlk7mCAj6xXp9UJ4fjI9VUI5rubuGBW5aJ7UnBMY= cloud.google.com/go/compute/metadata v0.2.3/go.mod h1:VAV5nSsACxMJvgaAuX6Pk2AawlZn8kiOGuCv6gTkwuA= +cloud.google.com/go/datastore v1.0.0/go.mod h1:LXYbyblFSglQ5pkeyhO+Qmw7ukd3C+pD7TKLgZqpHYE= +cloud.google.com/go/firestore v1.1.0/go.mod h1:ulACoGHTpvq5r8rxGJ4ddJZBZqakUQqClKRT5SZwBmk= cloud.google.com/go/iam v1.1.6 h1:bEa06k05IO4f4uJonbB5iAgKTPpABy1ayxaIZV/GHVc= cloud.google.com/go/iam v1.1.6/go.mod h1:O0zxdPeGBoFdWW3HWmBxJsk0pfvNM/p/qa82rWOGTwI= +cloud.google.com/go/pubsub v1.0.1/go.mod h1:R0Gpsv3s54REJCy4fxDixWD93lHJMoZTyQ2kNxGRt3I= +cloud.google.com/go/storage v1.0.0/go.mod h1:IhtSnM/ZTZV8YYJWCY8RULGVqBDmpoyjwiyrjsg+URw= cloud.google.com/go/storage v1.39.1 h1:MvraqHKhogCOTXTlct/9C3K3+Uy2jBmFYb3/Sp6dVtY= cloud.google.com/go/storage v1.39.1/go.mod h1:xK6xZmxZmo+fyP7+DEF6FhNc24/JAe95OLyOHCXFH1o= +dmitri.shuralyov.com/gpu/mtl v0.0.0-20190408044501-666a987793e9/go.mod h1:H6x//7gZCb22OMCxBHrMx7a5I7Hp++hsVxbQ4BYO7hU= github.com/BurntSushi/toml v0.3.1/go.mod h1:xHWCNGjB5oqiDr8zfno3MHue2Ht5sIBksp03qcyfWMU= +github.com/BurntSushi/xgb v0.0.0-20160522181843-27f122750802/go.mod h1:IVnqGOEym/WlBOVXweHU+Q+/VP0lqqI8lqeDx9IjBqo= github.com/DataDog/zstd v1.4.5 h1:EndNeuB0l9syBZhut0wns3gV1hL8zX8LIu6ZiVHWLIQ= github.com/DataDog/zstd v1.4.5/go.mod h1:1jcaCB/ufaK+sKp1NBhlGmpz41jOoPQ35bpF36t7BBo= github.com/Microsoft/go-winio v0.6.2 h1:F2VQgta7ecxGYO8k3ZZz3RS8fVIXVxONVUPlNERoyfY= github.com/Microsoft/go-winio v0.6.2/go.mod h1:yd8OoFMLzJbo9gZq8j5qaps8bJ9aShtEA8Ipt1oGCvU= +github.com/OneOfOne/xxhash v1.2.2/go.mod h1:HSdplMjZKSmBqAxg5vPj2TmRDmfkzw+cTzAElWljhcU= github.com/StackExchange/wmi v1.2.1 h1:VIkavFPXSjcnS+O8yTq7NI32k0R5Aj+v39y29VYDOSA= github.com/StackExchange/wmi v1.2.1/go.mod h1:rcmrprowKIVzvc+NUiLncP2uuArMWLCbu9SBzvHz7e8= github.com/VictoriaMetrics/fastcache v1.12.2 h1:N0y9ASrJ0F6h0QaC3o6uJb3NIZ9VKLjCM7NQbSmF7WI= github.com/VictoriaMetrics/fastcache v1.12.2/go.mod h1:AmC+Nzz1+3G2eCPapF6UcsnkThDcMsQicp4xDukwJYI= +github.com/alecthomas/template v0.0.0-20160405071501-a0175ee3bccc/go.mod h1:LOuyumcjzFXgccqObfd/Ljyb9UuFJ6TxHnclSeseNhc= +github.com/alecthomas/units v0.0.0-20151022065526-2efee857e7cf/go.mod h1:ybxpYRFXyAe+OPACYpWeL0wqObRcbAqCMya13uyzqw0= +github.com/armon/circbuf v0.0.0-20150827004946-bbbad097214e/go.mod h1:3U/XgcO3hCbHZ8TKRvWD2dDTCfh9M9ya+I9JpbB7O8o= +github.com/armon/go-metrics v0.0.0-20180917152333-f0300d1749da/go.mod h1:Q73ZrmVTwzkszR9V5SSuryQ31EELlFMUz1kKyl939pY= +github.com/armon/go-radix v0.0.0-20180808171621-7fddfc383310/go.mod h1:ufUuZ+zHj4x4TnLV4JWEpy2hxWSpsRywHrMgIH9cCH8= github.com/aws/aws-sdk-go v1.51.4 h1:yOVfGhRJyReBrACK0alLosJl8iXhWkNY1vrePYmhHdw= github.com/aws/aws-sdk-go v1.51.4/go.mod h1:LF8svs817+Nz+DmiMQKTO3ubZ/6IaTpq3TjupRn3Eqk= +github.com/beorn7/perks v0.0.0-20180321164747-3a771d992973/go.mod h1:Dwedo/Wpr24TaqPxmxbtue+5NUziq4I4S80YR8gNf3Q= +github.com/beorn7/perks v1.0.0/go.mod h1:KWe93zE9D1o94FZ5RNwFwVgaQK1VOXiVxmqh+CedLV8= github.com/beorn7/perks v1.0.1 h1:VlbKKnNfV8bJzeqoa4cOKqO6bYr3WgKZxO8Z16+hsOM= github.com/beorn7/perks v1.0.1/go.mod h1:G2ZrVWU2WbWT9wwq4/hrbKbnv/1ERSJQ0ibhJ6rlkpw= +github.com/bgentry/speakeasy v0.1.0/go.mod h1:+zsyZBPWlz7T6j88CTgSN5bM796AkVf0kBD4zp0CCIs= github.com/bits-and-blooms/bitset v1.13.0 h1:bAQ9OPNFYbGHV6Nez0tmNI0RiEu7/hxlYJRUA0wFAVE= github.com/bits-and-blooms/bitset v1.13.0/go.mod h1:7hO7Gc7Pp1vODcmWvKMRA9BNmbv6a/7QIWpPxHddWR8= +github.com/bketelsen/crypt v0.0.3-0.20200106085610-5cbc8cc4026c/go.mod h1:MKsuJmJgSg28kpZDP6UIiPt0e0Oz0kqKNGyRaWEPv84= github.com/btcsuite/btcd/btcec/v2 v2.3.4 h1:3EJjcN70HCu/mwqlUsGK8GcNVyLVxFDlWurTXGPFfiQ= github.com/btcsuite/btcd/btcec/v2 v2.3.4/go.mod h1:zYzJ8etWJQIv1Ogk7OzpWjowwOdXY1W/17j2MW85J04= github.com/btcsuite/btcd/chaincfg/chainhash v1.0.1 h1:q0rUy8C/TYNBQS1+CGKw68tLOFYSNEs0TFnxxnS9+4U= github.com/btcsuite/btcd/chaincfg/chainhash v1.0.1/go.mod h1:7SFka0XMvUgj3hfZtydOrQY2mwhPclbT2snogU7SQQc= +github.com/bugout-dev/bugout-go v0.4.6 h1:HaXoVNVZYqd6BaPwlQGhWKBYdGc2lhF3BRxIgyL+1SY= +github.com/bugout-dev/bugout-go v0.4.6/go.mod h1:P4+788iHtt/32u2wIaRTaiXTWpvSVBYxZ01qQ8N7eB8= github.com/census-instrumentation/opencensus-proto v0.2.1/go.mod h1:f6KPmirojxKA12rnyqOA5BBL4O983OfeGPqjHWSTneU= github.com/cespare/cp v0.1.0 h1:SE+dxFebS7Iik5LK0tsi1k9ZCxEaFX4AjQmoyA+1dJk= github.com/cespare/cp v0.1.0/go.mod h1:SOGHArjBr4JWaSDEVpWpo/hNg6RoKrls6Oh40hiwW+s= +github.com/cespare/xxhash v1.1.0/go.mod h1:XrSqR1VqqWfGrhpAt58auRo0WTKS1nRRg3ghfAqPWnc= github.com/cespare/xxhash/v2 v2.3.0 h1:UL815xU9SqsFlibzuggzjXhog7bL6oX9BbNZnL2UFvs= github.com/cespare/xxhash/v2 v2.3.0/go.mod h1:VGX0DQ3Q6kWi7AoAeZDth3/j3BFtOZR5XLFGgcrjCOs= github.com/client9/misspell v0.3.4/go.mod h1:qj6jICC3Q7zFZvVWo7KLAzC3yx5G7kyvSDkc90ppPyw= @@ -53,6 +79,12 @@ github.com/consensys/bavard v0.1.13 h1:oLhMLOFGTLdlda/kma4VOJazblc7IM5y5QPd2A/Yj github.com/consensys/bavard v0.1.13/go.mod h1:9ItSMtA/dXMAiL7BG6bqW2m3NdSEObYWoH223nGHukI= github.com/consensys/gnark-crypto v0.12.1 h1:lHH39WuuFgVHONRl3J0LRBtuYdQTumFSDtJF7HpyG8M= github.com/consensys/gnark-crypto v0.12.1/go.mod h1:v2Gy7L/4ZRosZ7Ivs+9SfUDr0f5UlG+EM5t7MPHiLuY= +github.com/coreos/bbolt v1.3.2/go.mod h1:iRUV2dpdMOn7Bo10OQBFzIJO9kkE559Wcmn+qkEiiKk= +github.com/coreos/etcd v3.3.13+incompatible/go.mod h1:uF7uidLiAD3TWHmW31ZFd/JWoc32PjwdhPthX9715RE= +github.com/coreos/go-semver v0.3.0/go.mod h1:nnelYz7RCh+5ahJtPPxZlU+153eP4D4r3EedlOD2RNk= +github.com/coreos/go-systemd v0.0.0-20190321100706-95778dfbb74e/go.mod h1:F5haX7vjVVG0kc13fIWeqUViNPyEJxv/OmvnBo0Yme4= +github.com/coreos/pkg v0.0.0-20180928190104-399ea9e2e55f/go.mod h1:E3G3o1h8I7cfcXa63jLwjI0eiQQMgzzUDFVpN/nH/eA= +github.com/cpuguy83/go-md2man/v2 v2.0.0/go.mod h1:maD7wRr/U5Z6m/iR4s+kqSMx2CaBsrgA7czyZG/E6dU= github.com/cpuguy83/go-md2man/v2 v2.0.3 h1:qMCsGGgs+MAzDFyp9LpAe1Lqy/fY/qCovCm0qnXZOBM= github.com/cpuguy83/go-md2man/v2 v2.0.3/go.mod h1:tgQtvFlXSQOSOSIRvRPT7W67SCa46tRHOmNcaadrF8o= github.com/crate-crypto/go-ipa v0.0.0-20240223125850-b1e8a79f509c h1:uQYC5Z1mdLRPrZhHjHxufI8+2UG/i25QG92j0Er9p6I= @@ -68,6 +100,8 @@ github.com/decred/dcrd/crypto/blake256 v1.0.0 h1:/8DMNYp9SGi5f0w7uCm6d6M4OU2rGFK github.com/decred/dcrd/crypto/blake256 v1.0.0/go.mod h1:sQl2p6Y26YV+ZOcSTP6thNdn47hh8kt6rqSlvmrXFAc= github.com/decred/dcrd/dcrec/secp256k1/v4 v4.0.1 h1:YLtO71vCjJRCBcrPMtQ9nqBsqpA1m5sE92cU+pd5Mcc= github.com/decred/dcrd/dcrec/secp256k1/v4 v4.0.1/go.mod h1:hyedUtir6IdtD/7lIxGeCxkaw7y45JueMRL4DIyJDKs= +github.com/dgrijalva/jwt-go v3.2.0+incompatible/go.mod h1:E3ru+11k8xSBh+hMPgOLZmtrrCbhqsmaPHjLKYnJCaQ= +github.com/dgryski/go-sip13 v0.0.0-20181026042036-e10d5fee7954/go.mod h1:vAd38F8PWV+bWy6jNmig1y/TA+kYO4g3RSRF0IAv0no= github.com/envoyproxy/go-control-plane v0.9.0/go.mod h1:YTl/9mNaCwkRvm6d1a2C3ymFceY/DCBVvsKhRF0iEA4= github.com/envoyproxy/go-control-plane v0.9.1-0.20191026205805-5f8ba28d4473/go.mod h1:YTl/9mNaCwkRvm6d1a2C3ymFceY/DCBVvsKhRF0iEA4= github.com/envoyproxy/go-control-plane v0.9.4/go.mod h1:6rpuAdCZL397s3pYoYcLgu1mIlRU8Am5FuJP05cCM98= @@ -80,14 +114,21 @@ github.com/ethereum/go-ethereum v1.14.10 h1:kC24WjYeRjDy86LVo6MfF5Xs7nnUu+XG4Aja github.com/ethereum/go-ethereum v1.14.10/go.mod h1:+l/fr42Mma+xBnhefL/+z11/hcmJ2egl+ScIVPjhc7E= github.com/ethereum/go-verkle v0.1.1-0.20240829091221-dffa7562dbe9 h1:8NfxH2iXvJ60YRB8ChToFTUzl8awsc3cJ8CbLjGIl/A= github.com/ethereum/go-verkle v0.1.1-0.20240829091221-dffa7562dbe9/go.mod h1:M3b90YRnzqKyyzBEWJGqj8Qff4IDeXnzFw0P9bFw3uk= +github.com/fatih/color v1.7.0/go.mod h1:Zm6kSWBoL9eyXnKyktHP6abPY2pDugNf5KwzbycvMj4= github.com/felixge/httpsnoop v1.0.4 h1:NFTV2Zj1bL4mc9sqWACXbQFVBBg2W3GPvqp8/ESS2Wg= github.com/felixge/httpsnoop v1.0.4/go.mod h1:m8KPJKqk1gH5J9DgRY2ASl2lWCfGKXixSwevea8zH2U= +github.com/fsnotify/fsnotify v1.4.7/go.mod h1:jwhsz4b93w/PPRr/qN1Yymfu8t87LnFCMoQvtojpjFo= github.com/fsnotify/fsnotify v1.6.0 h1:n+5WquG0fcWoWp6xPWfHdbskMCQaFnG6PfBrh1Ky4HY= github.com/fsnotify/fsnotify v1.6.0/go.mod h1:sl3t1tCWJFWoRz9R8WJCbQihKKwmorjAbSClcnxKAGw= github.com/gballet/go-libpcsclite v0.0.0-20190607065134-2772fd86a8ff h1:tY80oXqGNY4FhTFhk+o9oFHGINQ/+vhlm8HFzi6znCI= github.com/gballet/go-libpcsclite v0.0.0-20190607065134-2772fd86a8ff/go.mod h1:x7DCsMOv1taUwEWCzT4cmDeAkigA5/QCwUodaVOe8Ww= github.com/getsentry/sentry-go v0.27.0 h1:Pv98CIbtB3LkMWmXi4Joa5OOcwbmnX88sF5qbK3r3Ps= github.com/getsentry/sentry-go v0.27.0/go.mod h1:lc76E2QywIyW8WuBnwl8Lc4bkmQH4+w1gwTf25trprY= +github.com/ghodss/yaml v1.0.0/go.mod h1:4dBDuWmgqj2HViK6kFavaiC9ZROes6MMH2rRYeMEF04= +github.com/go-gl/glfw v0.0.0-20190409004039-e6da0acd62b1/go.mod h1:vR7hzQXu2zJy9AVAgeJqvqgH9Q5CA+iKCZ2gyEVpxRU= +github.com/go-kit/kit v0.8.0/go.mod h1:xBxKIO96dXMWWy0MnWVtmwkA9/13aqxPnvrjFYMA2as= +github.com/go-logfmt/logfmt v0.3.0/go.mod h1:Qt1PoO58o5twSAckw1HlFXLmHsOX5/0LbT9GBnD5lWE= +github.com/go-logfmt/logfmt v0.4.0/go.mod h1:3RMwSq7FuexP4Kalkev3ejPJsZTpXXBr9+V4qmtdjCk= github.com/go-logr/logr v1.2.2/go.mod h1:jdQByPbusPIv2/zmleS9BjJVeZ6kBagPoEUsqbVz/1A= github.com/go-logr/logr v1.4.1 h1:pKouT5E8xu9zeFC39JXRDukb6JFQPXM5p5I91188VAQ= github.com/go-logr/logr v1.4.1/go.mod h1:9T104GzyrTigFIr8wt5mBrctHMim0Nb2HLGrmQ40KvY= @@ -96,18 +137,25 @@ github.com/go-logr/stdr v1.2.2/go.mod h1:mMo/vtBO5dYbehREoey6XUKy/eSumjCCveDpRre github.com/go-ole/go-ole v1.2.5/go.mod h1:pprOEPIfldk/42T2oK7lQ4v4JSDwmV0As9GaiUsvbm0= github.com/go-ole/go-ole v1.3.0 h1:Dt6ye7+vXGIKZ7Xtk4s6/xVdGDQynvom7xCFEdWr6uE= github.com/go-ole/go-ole v1.3.0/go.mod h1:5LS6F96DhAwUc7C+1HLexzMXY1xGRSryjyPPKW6zv78= +github.com/go-stack/stack v1.8.0/go.mod h1:v0f6uXyyMGvRgIKkXu+yp6POWl0qKG85gN/melR3HDY= github.com/gofrs/flock v0.8.1 h1:+gYjHKf32LDeiEEFhQaotPbLuUXjY5ZqxKgXy7n59aw= github.com/gofrs/flock v0.8.1/go.mod h1:F1TvTiK9OcQqauNUHlbJvyl9Qa1QvF/gOUDKA14jxHU= +github.com/gogo/protobuf v1.1.1/go.mod h1:r8qH/GZQm5c6nD/R0oafs1akxWv10x8SbQlK7atdtwQ= +github.com/gogo/protobuf v1.2.1/go.mod h1:hp+jE20tsWTFYpLwKvXlhS1hjn+gTNwPg2I6zVXpSg4= github.com/gogo/protobuf v1.3.2 h1:Ov1cvc58UF3b5XjBnZv7+opcTcQFZebYjWzi34vdm4Q= github.com/gogo/protobuf v1.3.2/go.mod h1:P1XiOD3dCwIKUDQYPy72D8LYyHL2YPYrpS2s69NZV8Q= github.com/golang-jwt/jwt/v4 v4.5.0 h1:7cYmW1XlMY7h7ii7UhUyChSgS5wUJEnm9uZVTGqOWzg= github.com/golang-jwt/jwt/v4 v4.5.0/go.mod h1:m21LjoU+eqJr34lmDMbreY2eSTRJ1cv77w39/MY0Ch0= github.com/golang/glog v0.0.0-20160126235308-23def4e6c14b/go.mod h1:SBH7ygxi8pfUlaOkMMuAQtPIUF8ecWP5IEl/CR7VP2Q= +github.com/golang/groupcache v0.0.0-20190129154638-5b532d6fd5ef/go.mod h1:cIg4eruTrX1D+g88fzRXU5OdNfaM+9IcxsU14FzY7Hc= github.com/golang/groupcache v0.0.0-20200121045136-8c9f03a8e57e/go.mod h1:cIg4eruTrX1D+g88fzRXU5OdNfaM+9IcxsU14FzY7Hc= github.com/golang/groupcache v0.0.0-20210331224755-41bb18bfe9da h1:oI5xCqsCo564l8iNU+DwB5epxmsaqB+rhGL0m5jtYqE= github.com/golang/groupcache v0.0.0-20210331224755-41bb18bfe9da/go.mod h1:cIg4eruTrX1D+g88fzRXU5OdNfaM+9IcxsU14FzY7Hc= github.com/golang/mock v1.1.1/go.mod h1:oTYuIxOrZwtPieC+H1uAHpcLFnEyAGVDL/k47Jfbm0A= +github.com/golang/mock v1.2.0/go.mod h1:oTYuIxOrZwtPieC+H1uAHpcLFnEyAGVDL/k47Jfbm0A= +github.com/golang/mock v1.3.1/go.mod h1:sBzyDLLjw3U8JLTeZvSv8jJB+tU5PVekmnlKIyFUx0Y= github.com/golang/protobuf v1.2.0/go.mod h1:6lQm79b+lXiMfvg/cZm0SGofjICqVBUtrP5yJMmIC1U= +github.com/golang/protobuf v1.3.1/go.mod h1:6lQm79b+lXiMfvg/cZm0SGofjICqVBUtrP5yJMmIC1U= github.com/golang/protobuf v1.3.2/go.mod h1:6lQm79b+lXiMfvg/cZm0SGofjICqVBUtrP5yJMmIC1U= github.com/golang/protobuf v1.4.0-rc.1/go.mod h1:ceaxUfeHdC40wWswd/P6IGgMaK3YpKi5j83Wpe3EHw8= github.com/golang/protobuf v1.4.0-rc.1.0.20200221234624-67d41d38c208/go.mod h1:xKAWHe0F5eneWXFV3EuXVDTCmh+JuBKY0li0aMyXATA= @@ -122,6 +170,8 @@ github.com/golang/protobuf v1.5.4 h1:i7eJL8qZTpSEXOPTxNKhASYpMn+8e5Q6AdndVa1dWek github.com/golang/protobuf v1.5.4/go.mod h1:lnTiLA8Wa4RWRcIUkrtSVa5nRhsEGBg48fD6rSs7xps= github.com/golang/snappy v0.0.5-0.20220116011046-fa5810519dcb h1:PBC98N2aIaM3XXiurYmW7fx4GZkL8feAMVq7nEjURHk= github.com/golang/snappy v0.0.5-0.20220116011046-fa5810519dcb/go.mod h1:/XxbfmMg8lxefKM7IXC3fBNl/7bRcc72aCRzEWrmP2Q= +github.com/google/btree v0.0.0-20180813153112-4030bb1f1f0c/go.mod h1:lNA+9X1NB3Zf8V7Ke586lFgjr2dZNuvo3lPJSGZ5JPQ= +github.com/google/btree v1.0.0/go.mod h1:lNA+9X1NB3Zf8V7Ke586lFgjr2dZNuvo3lPJSGZ5JPQ= github.com/google/go-cmp v0.2.0/go.mod h1:oXzfMopK8JAjlY9xF4vHSVASa0yLyX7SntLO5aqRK0M= github.com/google/go-cmp v0.3.0/go.mod h1:8QqcDgzrUqlUb/G2PQTWiueGozuR1884gddMywk6iLU= github.com/google/go-cmp v0.3.1/go.mod h1:8QqcDgzrUqlUb/G2PQTWiueGozuR1884gddMywk6iLU= @@ -133,8 +183,12 @@ github.com/google/go-cmp v0.6.0 h1:ofyhxvXcZhMsU5ulbFiLKl/XBFqE1GSq7atu8tAmTRI= github.com/google/go-cmp v0.6.0/go.mod h1:17dUlkBOakJ0+DkrSSNjCkIjxS6bF9zb3elmeNGIjoY= github.com/google/gofuzz v1.2.0 h1:xRy4A+RhZaiKjJ1bPfwQ8sedCA+YS2YcCHW6ec7JMi0= github.com/google/gofuzz v1.2.0/go.mod h1:dBl0BpW6vV/+mYPU4Po3pmUjxk6FQPldtuIdl/M65Eg= +github.com/google/martian v2.1.0+incompatible/go.mod h1:9I4somxYTbIHy5NJKHRl3wXiIaQGbYVAs8BPL6v8lEs= github.com/google/martian/v3 v3.3.2 h1:IqNFLAmvJOgVlpdEBiQbDc2EwKW77amAycfTuWKdfvw= github.com/google/martian/v3 v3.3.2/go.mod h1:oBOf6HBosgwRXnUGWUB05QECsc6uvmMiJ3+6W4l/CUk= +github.com/google/pprof v0.0.0-20181206194817-3ea8567a2e57/go.mod h1:zfwlbNMJ+OItoe0UupaVj+oy1omPYYDuagoSzA8v9mc= +github.com/google/pprof v0.0.0-20190515194954-54271f7e092f/go.mod h1:zfwlbNMJ+OItoe0UupaVj+oy1omPYYDuagoSzA8v9mc= +github.com/google/renameio v0.1.0/go.mod h1:KWCgfxg9yswjAJkECMjeO8J8rahYeXnNhOm40UhjYkI= github.com/google/s2a-go v0.1.7 h1:60BLSyTrOV4/haCDW4zb1guZItoSq8foHCXrAnjBo/o= github.com/google/s2a-go v0.1.7/go.mod h1:50CgR4k1jNlWBu4UfS4AcfhVe1r6pdZPygJ3R8F0Qdw= github.com/google/subcommands v1.2.0/go.mod h1:ZjhPrFU+Olkh9WazFPsl27BQ4UPiG37m3yTrtFlrHVk= @@ -143,12 +197,38 @@ github.com/google/uuid v1.6.0 h1:NIvaJDMOsjHA8n1jAhLSgzrAzy1Hgr+hNrb57e+94F0= github.com/google/uuid v1.6.0/go.mod h1:TIyPZe4MgqvfeYDBFedMoGGpEw/LqOeaOT+nhxU+yHo= github.com/googleapis/enterprise-certificate-proxy v0.3.2 h1:Vie5ybvEvT75RniqhfFxPRy3Bf7vr3h0cechB90XaQs= github.com/googleapis/enterprise-certificate-proxy v0.3.2/go.mod h1:VLSiSSBs/ksPL8kq3OBOQ6WRI2QnaFynd1DCjZ62+V0= +github.com/googleapis/gax-go/v2 v2.0.4/go.mod h1:0Wqv26UfaUD9n4G6kQubkQ+KchISgw+vpHVxEJEs9eg= +github.com/googleapis/gax-go/v2 v2.0.5/go.mod h1:DWXyrwAJ9X0FpwwEdw+IPEYBICEFu5mhpdKc/us6bOk= github.com/googleapis/gax-go/v2 v2.12.2 h1:mhN09QQW1jEWeMF74zGR81R30z4VJzjZsfkUhuHF+DA= github.com/googleapis/gax-go/v2 v2.12.2/go.mod h1:61M8vcyyXR2kqKFxKrfA22jaA8JGF7Dc8App1U3H6jc= +github.com/gopherjs/gopherjs v0.0.0-20181017120253-0766667cb4d1/go.mod h1:wJfORRmW1u3UXTncJ5qlYoELFm8eSnnEO6hX4iZ3EWY= github.com/gorilla/websocket v1.4.2 h1:+/TMaTYc4QFitKJxsQ7Yye35DkWvkdLcvGKqM+x0Ufc= github.com/gorilla/websocket v1.4.2/go.mod h1:YR8l580nyteQvAITg2hZ9XVh4b55+EU/adAjf1fMHhE= +github.com/grpc-ecosystem/go-grpc-middleware v1.0.0/go.mod h1:FiyG127CGDf3tlThmgyCl78X/SZQqEOJBCDaAfeWzPs= +github.com/grpc-ecosystem/go-grpc-prometheus v1.2.0/go.mod h1:8NvIoxWQoOIhqOTXgfV/d3M/q6VIi02HzZEHgUlZvzk= +github.com/grpc-ecosystem/grpc-gateway v1.9.0/go.mod h1:vNeuVxBJEsws4ogUvrchl83t/GYV9WGTSLVdBhOQFDY= +github.com/hashicorp/consul/api v1.1.0/go.mod h1:VmuI/Lkw1nC05EYQWNKwWGbkg+FbDBtguAZLlVdkD9Q= +github.com/hashicorp/consul/sdk v0.1.1/go.mod h1:VKf9jXwCTEY1QZP2MOLRhb5i/I/ssyNV1vwHyQBF0x8= +github.com/hashicorp/errwrap v1.0.0/go.mod h1:YH+1FKiLXxHSkmPseP+kNlulaMuP3n2brvKWEqk/Jc4= github.com/hashicorp/go-bexpr v0.1.10 h1:9kuI5PFotCboP3dkDYFr/wi0gg0QVbSNz5oFRpxn4uE= github.com/hashicorp/go-bexpr v0.1.10/go.mod h1:oxlubA2vC/gFVfX1A6JGp7ls7uCDlfJn732ehYYg+g0= +github.com/hashicorp/go-cleanhttp v0.5.1/go.mod h1:JpRdi6/HCYpAwUzNwuwqhbovhLtngrth3wmdIIUrZ80= +github.com/hashicorp/go-immutable-radix v1.0.0/go.mod h1:0y9vanUI8NX6FsYoO3zeMjhV/C5i9g4Q3DwcSNZ4P60= +github.com/hashicorp/go-msgpack v0.5.3/go.mod h1:ahLV/dePpqEmjfWmKiqvPkv/twdG7iPBM1vqhUKIvfM= +github.com/hashicorp/go-multierror v1.0.0/go.mod h1:dHtQlpGsu+cZNNAkkCN/P3hoUDHhCYQXV3UM06sGGrk= +github.com/hashicorp/go-rootcerts v1.0.0/go.mod h1:K6zTfqpRlCUIjkwsN4Z+hiSfzSTQa6eBIzfwKfwNnHU= +github.com/hashicorp/go-sockaddr v1.0.0/go.mod h1:7Xibr9yA9JjQq1JpNB2Vw7kxv8xerXegt+ozgdvDeDU= +github.com/hashicorp/go-syslog v1.0.0/go.mod h1:qPfqrKkXGihmCqbJM2mZgkZGvKG1dFdvsLplgctolz4= +github.com/hashicorp/go-uuid v1.0.0/go.mod h1:6SBZvOh/SIDV7/2o3Jml5SYk/TvGqwFJ/bN7x4byOro= +github.com/hashicorp/go-uuid v1.0.1/go.mod h1:6SBZvOh/SIDV7/2o3Jml5SYk/TvGqwFJ/bN7x4byOro= +github.com/hashicorp/go.net v0.0.1/go.mod h1:hjKkEWcCURg++eb33jQU7oqQcI9XDCnUzHA0oac0k90= +github.com/hashicorp/golang-lru v0.5.0/go.mod h1:/m3WP610KZHVQ1SGc6re/UDhFvYD7pJ4Ao+sR/qLZy8= +github.com/hashicorp/golang-lru v0.5.1/go.mod h1:/m3WP610KZHVQ1SGc6re/UDhFvYD7pJ4Ao+sR/qLZy8= +github.com/hashicorp/hcl v1.0.0/go.mod h1:E5yfLk+7swimpb2L/Alb/PJmXilQ/rhwaUYs4T20WEQ= +github.com/hashicorp/logutils v1.0.0/go.mod h1:QIAnNjmIWmVIIkWDTG1z5v++HQmx9WQRO+LraFDTW64= +github.com/hashicorp/mdns v1.0.0/go.mod h1:tL+uN++7HEJ6SQLQ2/p+z2pH24WQKWjBPkE0mNTz8vQ= +github.com/hashicorp/memberlist v0.1.3/go.mod h1:ajVTdAv/9Im8oMAAj5G31PhhMCZJV2pPBoIllUwCN7I= +github.com/hashicorp/serf v0.8.2/go.mod h1:6hOLApaqBFA1NXqRQAsxw9QxuDEvNxSQRwA/JwenrHc= github.com/holiman/billy v0.0.0-20240216141850-2abb0c79d3c4 h1:X4egAf/gcS1zATw6wn4Ej8vjuVGxeHdan+bRb2ebyv4= github.com/holiman/billy v0.0.0-20240216141850-2abb0c79d3c4/go.mod h1:5GuXa7vkL8u9FkFuWdVvfR5ix8hRB7DbOAaYULamFpc= github.com/holiman/bloomfilter/v2 v2.0.3 h1:73e0e/V0tCydx14a0SCYS/EWCxgwLZ18CZcZKVu0fao= @@ -159,6 +239,7 @@ github.com/huin/goupnp v1.3.0 h1:UvLUlWDNpoUdYzb2TCn+MuTWtcjXKSza2n6CBdQ0xXc= github.com/huin/goupnp v1.3.0/go.mod h1:gnGPsThkYa7bFi/KWmEysQRf48l2dvR5bxr2OFckNX8= github.com/iancoleman/strcase v0.3.0 h1:nTXanmYxhfFAMjZL34Ov6gkzEsSJZ5DbhxWjvSASxEI= github.com/iancoleman/strcase v0.3.0/go.mod h1:iwCmte+B7n89clKwxIoIXy/HfoL7AsD47ZCWhYzw7ho= +github.com/inconshreveable/mousetrap v1.0.0/go.mod h1:PxqpIevigyE2G7u3NXJIT2ANytuPF1OarO4DADm73n8= github.com/inconshreveable/mousetrap v1.1.0 h1:wN+x4NVGpMsO7ErUn/mUI3vEoE6Jt13X2s0bqwp9tc8= github.com/inconshreveable/mousetrap v1.1.0/go.mod h1:vpF70FUmC8bwa3OWnCshd2FqLfsEA9PFc4w1p2J65bw= github.com/jackc/pgpassfile v1.0.0 h1:/6Hmqy13Ss2zCq62VdNG8tM1wchn8zjSGOBJ6icpsIM= @@ -175,24 +256,49 @@ github.com/jmespath/go-jmespath v0.4.0 h1:BEgLn5cpjn8UN1mAw4NjwDrS35OdebyEtFe+9Y github.com/jmespath/go-jmespath v0.4.0/go.mod h1:T8mJZnbsbmF+m6zOOFylbeCJqk5+pHWvzYPziyZiYoo= github.com/jmespath/go-jmespath/internal/testify v1.5.1 h1:shLQSRRSCCPj3f2gpwzGwWFoC7ycTf1rcQZHOlsJ6N8= github.com/jmespath/go-jmespath/internal/testify v1.5.1/go.mod h1:L3OGu8Wl2/fWfCI6z80xFu9LTZmf1ZRjMHUOPmWr69U= +github.com/jonboulle/clockwork v0.1.0/go.mod h1:Ii8DK3G1RaLaWxj9trq07+26W01tbo22gdxWY5EU2bo= +github.com/json-iterator/go v1.1.6/go.mod h1:+SdeFBvtyEkXs7REEP0seUULqWtbJapLOCVDaaPEHmU= +github.com/jstemmer/go-junit-report v0.0.0-20190106144839-af01ea7f8024/go.mod h1:6v2b51hI/fHJwM22ozAgKL4VKDeJcHhJFhtBdhmNjmU= +github.com/jtolds/gls v4.20.0+incompatible/go.mod h1:QJZ7F/aHp+rZTRtaJ1ow/lLfFfVYBRgL+9YlvaHOwJU= +github.com/julienschmidt/httprouter v1.2.0/go.mod h1:SYymIcj16QtmaHHD7aYtjjsJG7VTCxuUUipMqKk8s4w= +github.com/kisielk/errcheck v1.1.0/go.mod h1:EZBBE59ingxPouuu3KfxchcWSUPOHkagtvWXihfKN4Q= +github.com/kisielk/gotool v1.0.0/go.mod h1:XhKaO+MFFWcvkIS/tQcRk01m1F5IRFswLeQ+oQHNcck= github.com/klauspost/compress v1.16.0 h1:iULayQNOReoYUe+1qtKOqw9CwJv3aNQu8ivo7lw1HU4= github.com/klauspost/compress v1.16.0/go.mod h1:ntbaceVETuRiXiv4DpjP66DpAtAGkEQskQzEyD//IeE= +github.com/konsorten/go-windows-terminal-sequences v1.0.1/go.mod h1:T0+1ngSBFLxvqU3pZ+m/2kptfBszLMUkC4ZK/EgS/cQ= +github.com/kr/logfmt v0.0.0-20140226030751-b84e30acd515/go.mod h1:+0opPa2QZZtGFBFZlji/RkVcI2GknAs/DXo4wKdlNEc= +github.com/kr/pretty v0.1.0/go.mod h1:dAy3ld7l9f0ibDNOQOHHMYYIIbhfbHSm3C4ZsoJORNo= github.com/kr/pretty v0.3.1 h1:flRD4NNwYAUpkphVc1HcthR4KEIFJ65n8Mw5qdRn3LE= github.com/kr/pretty v0.3.1/go.mod h1:hoEshYVHaxMs3cyo3Yncou5ZscifuDolrwPKZanG3xk= +github.com/kr/pty v1.1.1/go.mod h1:pFQYn66WHrOpPYNljwOMqo10TkYh1fy3cYio2l3bCsQ= +github.com/kr/text v0.1.0/go.mod h1:4Jbv+DJW3UT/LiOwJeYQe1efqtUx/iVham/4vfdArNI= github.com/kr/text v0.2.0 h1:5Nx0Ya0ZqY2ygV366QzturHI13Jq95ApcVaJBhpS+AY= github.com/kr/text v0.2.0/go.mod h1:eLer722TekiGuMkidMxC/pM04lWEeraHUUmBw8l2grE= github.com/kylelemons/godebug v1.1.0 h1:RPNrshWIDI6G2gRW9EHilWtl7Z6Sb1BR0xunSBf0SNc= github.com/kylelemons/godebug v1.1.0/go.mod h1:9/0rRGxNHcop5bhtWyNeEfOS8JIWk580+fNqagV/RAw= github.com/leanovate/gopter v0.2.9 h1:fQjYxZaynp97ozCzfOyOuAGOU4aU/z37zf/tOujFk7c= github.com/leanovate/gopter v0.2.9/go.mod h1:U2L/78B+KVFIx2VmW6onHJQzXtFb+p5y3y2Sh+Jxxv8= +github.com/magiconair/properties v1.8.1/go.mod h1:PppfXfuXeibc/6YijjN8zIbojt8czPbwD3XqdrwzmxQ= +github.com/mattn/go-colorable v0.0.9/go.mod h1:9vuHe8Xs5qXnSaW/c/ABM9alt+Vo+STaOChaDxuIBZU= github.com/mattn/go-colorable v0.1.13 h1:fFA4WZxdEF4tXPZVKMLwD8oUnCTTo08duU7wxecdEvA= github.com/mattn/go-colorable v0.1.13/go.mod h1:7S9/ev0klgBDR4GtXTXX8a3vIGJpMovkB8vQcUbaXHg= +github.com/mattn/go-isatty v0.0.3/go.mod h1:M+lRXTBqGeGNdLjl/ufCoiOlB5xdOkqRJdNxMWT7Zi4= github.com/mattn/go-isatty v0.0.20 h1:xfD0iDuEKnDkl03q4limB+vH+GxLEtL/jb4xVJSWWEY= github.com/mattn/go-isatty v0.0.20/go.mod h1:W+V8PltTTMOvKvAeJH7IuucS94S2C6jfK/D7dTCTo3Y= github.com/mattn/go-runewidth v0.0.13 h1:lTGmDsbAYt5DmK6OnoV7EuIF1wEIFAcxld6ypU4OSgU= github.com/mattn/go-runewidth v0.0.13/go.mod h1:Jdepj2loyihRzMpdS35Xk/zdY8IAYHsh153qUoGf23w= +github.com/matttproud/golang_protobuf_extensions v1.0.1/go.mod h1:D8He9yQNgCq6Z5Ld7szi9bcBfOoFv/3dc6xSMkL2PC0= github.com/matttproud/golang_protobuf_extensions v1.0.2-0.20181231171920-c182affec369 h1:I0XW9+e1XWDxdcEniV4rQAIOPUGDq67JSCiRCgGCZLI= github.com/matttproud/golang_protobuf_extensions v1.0.2-0.20181231171920-c182affec369/go.mod h1:BSXmuO+STAnVfrANrmjBb36TMTDstsz7MSK+HVaYKv4= +github.com/miekg/dns v1.0.14/go.mod h1:W1PPwlIAgtquWBMBEV9nkV9Cazfe8ScdGz/Lj7v3Nrg= +github.com/mitchellh/cli v1.0.0/go.mod h1:hNIlj7HEI86fIcpObd7a0FcrxTWetlwJDGcceTlRvqc= +github.com/mitchellh/go-homedir v1.0.0/go.mod h1:SfyaCUpYCn1Vlf4IUYiD9fPX4A5wJrkLzIz1N1q0pr0= +github.com/mitchellh/go-homedir v1.1.0/go.mod h1:SfyaCUpYCn1Vlf4IUYiD9fPX4A5wJrkLzIz1N1q0pr0= +github.com/mitchellh/go-testing-interface v1.0.0/go.mod h1:kRemZodwjscx+RGhAo8eIhFbs2+BFgRtFPeD/KE+zxI= +github.com/mitchellh/gox v0.4.0/go.mod h1:Sd9lOJ0+aimLBi73mGofS1ycjY8lL3uZM3JPS42BGNg= +github.com/mitchellh/iochan v1.0.0/go.mod h1:JwYml1nuB7xOzsp52dPpHFffvOCDupsG0QubkSMEySY= +github.com/mitchellh/mapstructure v0.0.0-20160808181253-ca63d7c062ee/go.mod h1:FVVH3fgwuzCH5S8UJGiWEs2h04kUh9fWfEaFds41c1Y= +github.com/mitchellh/mapstructure v1.1.2/go.mod h1:FVVH3fgwuzCH5S8UJGiWEs2h04kUh9fWfEaFds41c1Y= github.com/mitchellh/mapstructure v1.4.1 h1:CpVNEelQCZBooIPDn+AR3NpivK/TIKU8bDxdASFVQag= github.com/mitchellh/mapstructure v1.4.1/go.mod h1:bFUtVrKA4DC2yAKiSyO/QUcy7e+RRV2QTWOzhPopBRo= github.com/mitchellh/pointerstructure v1.2.0 h1:O+i9nHnXS3l/9Wu7r4NrEdwA2VFTicjUEN1uBnDo34A= @@ -200,40 +306,77 @@ github.com/mitchellh/pointerstructure v1.2.0/go.mod h1:BRAsLI5zgXmw97Lf6s25bs8oh github.com/mmcloughlin/addchain v0.4.0 h1:SobOdjm2xLj1KkXN5/n0xTIWyZA2+s99UCY1iPfkHRY= github.com/mmcloughlin/addchain v0.4.0/go.mod h1:A86O+tHqZLMNO4w6ZZ4FlVQEadcoqkyU72HC5wJ4RlU= github.com/mmcloughlin/profile v0.1.1/go.mod h1:IhHD7q1ooxgwTgjxQYkACGA77oFTDdFVejUS1/tS/qU= +github.com/modern-go/concurrent v0.0.0-20180306012644-bacd9c7ef1dd/go.mod h1:6dJC0mAP4ikYIbvyc7fijjWJddQyLn8Ig3JB5CqoB9Q= +github.com/modern-go/reflect2 v1.0.1/go.mod h1:bx2lNnkwVCuqBIxFjflWJWanXIb3RllmbCylyMrvgv0= +github.com/mwitkow/go-conntrack v0.0.0-20161129095857-cc309e4a2223/go.mod h1:qRWi+5nqEBWmkhHvq77mSJWrCKwh8bxhgT7d/eI7P4U= +github.com/oklog/ulid v1.3.1/go.mod h1:CirwcVhetQ6Lv90oh/F+FBtV6XMibvdAFo93nm5qn4U= github.com/olekukonko/tablewriter v0.0.5 h1:P2Ga83D34wi1o9J6Wh1mRuqd4mF/x/lgBS7N7AbDhec= github.com/olekukonko/tablewriter v0.0.5/go.mod h1:hPp6KlRPjbx+hW8ykQs1w3UBbZlj6HuIJcUGPhkA7kY= +github.com/pascaldekloe/goe v0.0.0-20180627143212-57f6aae5913c/go.mod h1:lzWF7FIEvWOWxwDKqyGYQf6ZUaNfKdP144TG7ZOy1lc= +github.com/pelletier/go-toml v1.2.0/go.mod h1:5z9KED0ma1S8pY6P1sdut58dfprrGBbd/94hg7ilaic= +github.com/pkg/errors v0.8.0/go.mod h1:bwawxfHBFNV+L2hUp1rHADufV3IMtnDRdf1r5NINEl0= +github.com/pkg/errors v0.8.1/go.mod h1:bwawxfHBFNV+L2hUp1rHADufV3IMtnDRdf1r5NINEl0= github.com/pkg/errors v0.9.1 h1:FEBLx1zS214owpjy7qsBeixbURkuhQAwrK5UwLGTwt4= github.com/pkg/errors v0.9.1/go.mod h1:bwawxfHBFNV+L2hUp1rHADufV3IMtnDRdf1r5NINEl0= github.com/pmezard/go-difflib v1.0.0 h1:4DBwDE0NGyQoBHbLQYPwSUPoCMWR5BEzIk/f1lZbAQM= github.com/pmezard/go-difflib v1.0.0/go.mod h1:iKH77koFhYxTK1pcRnkKkqfTogsbg7gZNVY4sRDYZ/4= +github.com/posener/complete v1.1.1/go.mod h1:em0nMJCgc9GFtwrmVmEMR/ZL6WyhyjMBndrE9hABlRI= +github.com/prometheus/client_golang v0.9.1/go.mod h1:7SWBe2y4D6OKWSNQJUaRYU/AaXPKyh/dDVn+NZz0KFw= +github.com/prometheus/client_golang v0.9.3/go.mod h1:/TN21ttK/J9q6uSwhBd54HahCDft0ttaMvbicHlPoso= github.com/prometheus/client_golang v1.12.0 h1:C+UIj/QWtmqY13Arb8kwMt5j34/0Z2iKamrJ+ryC0Gg= github.com/prometheus/client_golang v1.12.0/go.mod h1:3Z9XVyYiZYEO+YQWt3RD2R3jrbd179Rt297l4aS6nDY= +github.com/prometheus/client_model v0.0.0-20180712105110-5c3871d89910/go.mod h1:MbSGuTsp3dbXC40dX6PRTWyKYBIrTGTE9sqQNg2J8bo= +github.com/prometheus/client_model v0.0.0-20190129233127-fd36f4220a90/go.mod h1:xMI15A0UPsDsEKsMN9yxemIoYk6Tm2C1GtYGdfGttqA= github.com/prometheus/client_model v0.0.0-20190812154241-14fe0d1b01d4/go.mod h1:xMI15A0UPsDsEKsMN9yxemIoYk6Tm2C1GtYGdfGttqA= github.com/prometheus/client_model v0.2.1-0.20210607210712-147c58e9608a h1:CmF68hwI0XsOQ5UwlBopMi2Ow4Pbg32akc4KIVCOm+Y= github.com/prometheus/client_model v0.2.1-0.20210607210712-147c58e9608a/go.mod h1:LDGWKZIo7rky3hgvBe+caln+Dr3dPggB5dvjtD7w9+w= +github.com/prometheus/common v0.0.0-20181113130724-41aa239b4cce/go.mod h1:daVV7qP5qjZbuso7PdcryaAu0sAZbrN9i7WWcTMWvro= +github.com/prometheus/common v0.4.0/go.mod h1:TNfzLD0ON7rHzMJeJkieUDPYmFC7Snx/y86RQel1bk4= github.com/prometheus/common v0.32.1 h1:hWIdL3N2HoUx3B8j3YN9mWor0qhY/NlEKZEaXxuIRh4= github.com/prometheus/common v0.32.1/go.mod h1:vu+V0TpY+O6vW9J44gczi3Ap/oXXR10b+M/gUGO4Hls= +github.com/prometheus/procfs v0.0.0-20181005140218-185b4288413d/go.mod h1:c3At6R/oaqEKCNdg8wHV1ftS6bRYblBhIjjI8uT2IGk= +github.com/prometheus/procfs v0.0.0-20190507164030-5867b95ac084/go.mod h1:TjEm7ze935MbeOT/UhFTIMYKhuLP4wbCsTZCD3I8kEA= github.com/prometheus/procfs v0.7.3 h1:4jVXhlkAyzOScmCkXBTOLRLTz8EeU+eyjrwB/EPq0VU= github.com/prometheus/procfs v0.7.3/go.mod h1:cz+aTbrPOrUb4q7XlbU9ygM+/jj0fzG6c1xBZuNvfVA= +github.com/prometheus/tsdb v0.7.1/go.mod h1:qhTCs0VvXwvX/y3TZrWD7rabWM+ijKTux40TwIPHuXU= github.com/rivo/uniseg v0.2.0 h1:S1pD9weZBuJdFmowNwbpi7BJ8TNftyUImj/0WQi72jY= github.com/rivo/uniseg v0.2.0/go.mod h1:J6wj4VEh+S6ZtnVlnTBMWIodfgj8LQOQFoIToxlJtxc= +github.com/rogpeppe/fastuuid v0.0.0-20150106093220-6724a57986af/go.mod h1:XWv6SoW27p1b0cqNHllgS5HIMJraePCO15w5zCzIWYg= +github.com/rogpeppe/go-internal v1.3.0/go.mod h1:M8bDsm7K2OlrFYOpmOWEs/qY81heoFRclV5y23lUDJ4= github.com/rogpeppe/go-internal v1.9.0 h1:73kH8U+JUqXU8lRuOHeVHaa/SZPifC7BkcraZVejAe8= github.com/rogpeppe/go-internal v1.9.0/go.mod h1:WtVeX8xhTBvf0smdhujwtBcq4Qrzq/fJaraNFVN+nFs= github.com/rs/cors v1.7.0 h1:+88SsELBHx5r+hZ8TCkggzSstaWNbDvThkVK8H6f9ik= github.com/rs/cors v1.7.0/go.mod h1:gFx+x8UowdsKA9AchylcLynDq+nNFfI8FkUZdN/jGCU= +github.com/russross/blackfriday/v2 v2.0.1/go.mod h1:+Rmxgy9KzJVeS9/2gXHxylqXiyQDYRxCVz55jmeOWTM= github.com/russross/blackfriday/v2 v2.1.0 h1:JIOH55/0cWyOuilr9/qlrm0BSXldqnqwMsf35Ld67mk= github.com/russross/blackfriday/v2 v2.1.0/go.mod h1:+Rmxgy9KzJVeS9/2gXHxylqXiyQDYRxCVz55jmeOWTM= +github.com/ryanuber/columnize v0.0.0-20160712163229-9b3edd62028f/go.mod h1:sm1tb6uqfes/u+d4ooFouqFdy9/2g9QGwK3SQygK0Ts= +github.com/sean-/seed v0.0.0-20170313163322-e2103e2c3529/go.mod h1:DxrIzT+xaE7yg65j358z/aeFdxmN0P9QXhEzd20vsDc= github.com/shirou/gopsutil v3.21.4-0.20210419000835-c7a38de76ee5+incompatible h1:Bn1aCHHRnjv4Bl16T8rcaFjYSrGrIZvpiGO6P3Q4GpU= github.com/shirou/gopsutil v3.21.4-0.20210419000835-c7a38de76ee5+incompatible/go.mod h1:5b4v6he4MtMOwMlS0TUMTu2PcXUg8+E1lC7eC3UO/RA= +github.com/shurcooL/sanitized_anchor_name v1.0.0/go.mod h1:1NzhyTcUVG4SuEtjjoZeVRXNmyL/1OwPU0+IJeTBvfc= +github.com/sirupsen/logrus v1.2.0/go.mod h1:LxeOpSwHxABJmUn/MG1IvRgCAasNZTLOkJPxbbu5VWo= +github.com/smartystreets/assertions v0.0.0-20180927180507-b2de0cb4f26d/go.mod h1:OnSkiWE9lh6wB0YB77sQom3nweQdgAjqCqsofrRNTgc= +github.com/smartystreets/goconvey v1.6.4/go.mod h1:syvi0/a8iFYH4r/RixwvyeAJjdLS9QV7WQ/tjFTllLA= +github.com/soheilhy/cmux v0.1.4/go.mod h1:IM3LyeVVIOuxMH7sFAkER9+bJ4dT7Ms6E4xg4kGIyLM= +github.com/spaolacci/murmur3 v0.0.0-20180118202830-f09979ecbc72/go.mod h1:JwIasOWyU6f++ZhiEuf87xNszmSA2myDM2Kzu9HwQUA= +github.com/spf13/afero v1.1.2/go.mod h1:j4pytiNVoe2o6bmDsKpLACNPDBIoEAkihy7loJ1B0CQ= +github.com/spf13/cast v1.3.0/go.mod h1:Qx5cxh0v+4UWYiBimWS+eyWzqEqokIECu5etghLkUJE= +github.com/spf13/cobra v1.1.1/go.mod h1:WnodtKOvamDL/PwE2M4iKs8aMDBZ5Q5klgD3qfVJQMI= github.com/spf13/cobra v1.8.0 h1:7aJaZx1B85qltLMc546zn58BxxfZdR/W22ej9CFoEf0= github.com/spf13/cobra v1.8.0/go.mod h1:WXLWApfZ71AjXPya3WOlMsY9yMs7YeiHhFVlvLyhcho= +github.com/spf13/jwalterweatherman v1.0.0/go.mod h1:cQK4TGJAtQXfYWX+Ddv3mKDzgVb68N+wFjFa4jdeBTo= +github.com/spf13/pflag v1.0.3/go.mod h1:DYY7MBk1bdzusC3SYhjObp+wFpr4gzcvqqNjLnInEg4= github.com/spf13/pflag v1.0.5 h1:iy+VFUOCP1a+8yFto/drg2CJ5u0yRoB7fZw3DKv/JXA= github.com/spf13/pflag v1.0.5/go.mod h1:McXfInJRrz4CZXVZOBLb0bTZqETkiAhM9Iw0y3An2Bg= +github.com/spf13/viper v1.7.0/go.mod h1:8WkrPz2fc9jxqZNCJI/76HCieCp4Q8HaLFoCha5qpdg= github.com/status-im/keycard-go v0.2.0 h1:QDLFswOQu1r5jsycloeQh3bVU8n/NatHHaZobtDnDzA= github.com/status-im/keycard-go v0.2.0/go.mod h1:wlp8ZLbsmrF6g6WjugPAx+IzoLrkdf9+mHxBEeo3Hbg= github.com/stretchr/objx v0.1.0/go.mod h1:HFkY916IF+rwdDfMAkV7OtwuqBVzrE8GR6GFx+wExME= +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= github.com/stretchr/objx v0.5.0/go.mod h1:Yh+to48EsGEfYuaHDzXPcE3xhTkx73EhmCGUpEOglKo= +github.com/stretchr/testify v1.2.2/go.mod h1:a8OnRcib4nhh0OaRAV+Yts87kKdq0PP7pXfy6kDkUVs= github.com/stretchr/testify v1.3.0/go.mod h1:M5WIy9Dh21IEIfnGCwXGc5bZfKNJtfHm1UVUgZn+9EI= github.com/stretchr/testify v1.7.0/go.mod h1:6Fq8oRcR53rry900zMqJjRRixrwX3KX962/h/Wwjteg= github.com/stretchr/testify v1.7.1/go.mod h1:6Fq8oRcR53rry900zMqJjRRixrwX3KX962/h/Wwjteg= @@ -241,6 +384,7 @@ github.com/stretchr/testify v1.8.0/go.mod h1:yNjHg4UonilssWZ8iaSj1OCr/vHnekPRkoO github.com/stretchr/testify v1.8.1/go.mod h1:w2LPCIKwWwSfY2zedu0+kehJoqGctiVI29o6fzry7u4= github.com/stretchr/testify v1.9.0 h1:HtqpIVDClZ4nwg75+f6Lvsy/wHu+3BoSGCbBAcpTsTg= github.com/stretchr/testify v1.9.0/go.mod h1:r2ic/lqez/lEtzL7wO/rwa5dbSLXVDPFyf8C91i36aY= +github.com/subosito/gotenv v1.2.0/go.mod h1:N0PQaV/YGNqwC0u51sEeR/aUtSLEXKX9iv69rRypqCw= github.com/supranational/blst v0.3.13 h1:AYeSxdOMacwu7FBmpfloBz5pbFXDmJL33RuwnKtmTjk= github.com/supranational/blst v0.3.13/go.mod h1:jZJtfjgudtNl4en1tzwPIV3KjUnQUvG3/j+w+fVonLw= github.com/syndtr/goleveldb v1.0.1-0.20210819022825-2ae1ddf74ef7 h1:epCh84lMvA70Z7CTTCmYQn2CKbY8j86K7/FAIr141uY= @@ -249,13 +393,18 @@ github.com/tklauser/go-sysconf v0.3.12 h1:0QaGUFOdQaIVdPgfITYzaTegZvdCjmYO52cSFA github.com/tklauser/go-sysconf v0.3.12/go.mod h1:Ho14jnntGE1fpdOqQEEaiKRpvIavV0hSfmBq8nJbHYI= github.com/tklauser/numcpus v0.6.1 h1:ng9scYS7az0Bk4OZLvrNXNSAO2Pxr1XXRAPyjhIx+Fk= github.com/tklauser/numcpus v0.6.1/go.mod h1:1XfjsgE2zo8GVw7POkMbHENHzVg3GzmoZ9fESEdAacY= +github.com/tmc/grpc-websocket-proxy v0.0.0-20190109142713-0ad062ec5ee5/go.mod h1:ncp9v5uamzpCO7NfCPTXjqaC+bZgJeR0sMTm6dMHP7U= github.com/tyler-smith/go-bip39 v1.1.0 h1:5eUemwrMargf3BSLRRCalXT93Ns6pQJIjYQN2nyfOP8= github.com/tyler-smith/go-bip39 v1.1.0/go.mod h1:gUYDtqQw1JS3ZJ8UWVcGTGqqr6YIN3CWg+kkNaLt55U= github.com/urfave/cli/v2 v2.25.7 h1:VAzn5oq403l5pHjc4OhD54+XGO9cdKVL/7lDjF+iKUs= github.com/urfave/cli/v2 v2.25.7/go.mod h1:8qnjx1vcq5s2/wpsqoZFndg2CE5tNFyrTvS6SinrnYQ= +github.com/xiang90/probing v0.0.0-20190116061207-43a291ad63a2/go.mod h1:UETIi67q53MR2AWcXfiuqkDkRtnGDLqkBTpCHuJHxtU= github.com/xrash/smetrics v0.0.0-20201216005158-039620a65673 h1:bAn7/zixMGCfxrRTfdpNzjtPYqr8smhKouy9mxVdGPU= github.com/xrash/smetrics v0.0.0-20201216005158-039620a65673/go.mod h1:N3UwUGtsrSj3ccvlPHLoLsHnpR27oXr4ZE984MbSER8= github.com/yuin/goldmark v1.4.13/go.mod h1:6yULJ656Px+3vBD8DxQVa3kxgyrAnzto9xy5taEt/CY= +go.etcd.io/bbolt v1.3.2/go.mod h1:IbVyRI1SCnLcuJnV2u8VeU0CEYM7e686BmAb1XKL+uU= +go.opencensus.io v0.21.0/go.mod h1:mSImk1erAIZhrmZN+AvHh14ztQfjbGwt4TtuofqLduU= +go.opencensus.io v0.22.0/go.mod h1:+kGneAE2xo2IficOXnaByMWTGM9T73dGwxeWcUqIpI8= go.opencensus.io v0.24.0 h1:y73uSU6J157QMP2kn2r30vwW1A2W2WFwSCGnAVxeaD0= go.opencensus.io v0.24.0/go.mod h1:vNK8G9p7aAivkbmorf4v+7Hgx+Zs0yY+0fOtgBfjQKo= go.opentelemetry.io/contrib/instrumentation/google.golang.org/grpc/otelgrpc v0.48.0 h1:P+/g8GpuJGYbOp2tAdKrIPUX9JO02q8Q0YNlHolpibA= @@ -270,25 +419,54 @@ go.opentelemetry.io/otel/sdk v1.22.0 h1:6coWHw9xw7EfClIC/+O31R8IY3/+EiRFHevmHafB go.opentelemetry.io/otel/sdk v1.22.0/go.mod h1:iu7luyVGYovrRpe2fmj3CVKouQNdTOkxtLzPvPz1DOc= go.opentelemetry.io/otel/trace v1.23.0 h1:37Ik5Ib7xfYVb4V1UtnT97T1jI+AoIYkJyPkuL4iJgI= go.opentelemetry.io/otel/trace v1.23.0/go.mod h1:GSGTbIClEsuZrGIzoEHqsVfxgn5UkggkflQwDScNUsk= +go.uber.org/atomic v1.4.0/go.mod h1:gD2HeocX3+yG+ygLZcrzQJaqmWj9AIm7n08wl/qW/PE= +go.uber.org/multierr v1.1.0/go.mod h1:wR5kodmAFQ0UK8QlbwjlSNy0Z68gJhDJUG5sjR94q/0= +go.uber.org/zap v1.10.0/go.mod h1:vwi/ZaCAaUcBkycHslxD9B2zi4UTXhF60s6SWpuDF0Q= +golang.org/x/crypto v0.0.0-20180904163835-0709b304e793/go.mod h1:6SG95UA2DQfeDnfUPMdvaQW0Q7yPrPDi9nlGo2tz2b4= +golang.org/x/crypto v0.0.0-20181029021203-45a5f77698d3/go.mod h1:6SG95UA2DQfeDnfUPMdvaQW0Q7yPrPDi9nlGo2tz2b4= golang.org/x/crypto v0.0.0-20190308221718-c2843e01d9a2/go.mod h1:djNgcEr1/C05ACkg1iLfiJU5Ep61QUkGW8qpdssI0+w= +golang.org/x/crypto v0.0.0-20190510104115-cbcb75029529/go.mod h1:yigFU9vqHzYiE8UmvKecakEJjdnWj3jj499lnFckfCI= +golang.org/x/crypto v0.0.0-20190605123033-f99c8df09eb5/go.mod h1:yigFU9vqHzYiE8UmvKecakEJjdnWj3jj499lnFckfCI= golang.org/x/crypto v0.0.0-20200622213623-75b288015ac9/go.mod h1:LzIPMQfyMNhhGPhUkYOs5KpL4U8rLKemX1yGLhDgUto= golang.org/x/crypto v0.0.0-20210921155107-089bfa567519/go.mod h1:GvvjBRRGRdwPK5ydBHafDWAxML/pGHZbMvKqRZ5+Abc= golang.org/x/crypto v0.23.0 h1:dIJU/v2J8Mdglj/8rJ6UUOM3Zc9zLZxVZwwxMooUSAI= golang.org/x/crypto v0.23.0/go.mod h1:CKFgDieR+mRhux2Lsu27y0fO304Db0wZe70UKqHu0v8= golang.org/x/exp v0.0.0-20190121172915-509febef88a4/go.mod h1:CJ0aWSM057203Lf6IL+f9T1iT9GByDxfZKAQTCR3kQA= +golang.org/x/exp v0.0.0-20190306152737-a1d7652674e8/go.mod h1:CJ0aWSM057203Lf6IL+f9T1iT9GByDxfZKAQTCR3kQA= +golang.org/x/exp v0.0.0-20190510132918-efd6b22b2522/go.mod h1:ZjyILWgesfNpC6sMxTJOJm9Kp84zZh5NQWvqDGG3Qr8= +golang.org/x/exp v0.0.0-20190829153037-c13cbed26979/go.mod h1:86+5VVa7VpoJ4kLfm080zCjGlMRFzhUhsZKEZO7MGek= +golang.org/x/exp v0.0.0-20191030013958-a1ab85dbe136/go.mod h1:JXzH8nQsPlswgeRAPE3MuO9GYsAcnJvJ4vnMwN/5qkY= golang.org/x/exp v0.0.0-20231110203233-9a3e6036ecaa h1:FRnLl4eNAQl8hwxVVC17teOw8kdjVDVAiFMtgUdTSRQ= golang.org/x/exp v0.0.0-20231110203233-9a3e6036ecaa/go.mod h1:zk2irFbV9DP96SEBUUAy67IdHUaZuSnrz1n472HUCLE= +golang.org/x/image v0.0.0-20190227222117-0694c2d4d067/go.mod h1:kZ7UVZpmo3dzQBMxlp+ypCbDeSB+sBbTgSJuh5dn5js= +golang.org/x/image v0.0.0-20190802002840-cff245a6509b/go.mod h1:FeLwcggjj3mMvU+oOTbSwawSJRM1uh48EjtB4UJZlP0= golang.org/x/lint v0.0.0-20181026193005-c67002cb31c3/go.mod h1:UVdnD1Gm6xHRNCYTkRU2/jEulfH38KcIWyp/GAMgvoE= golang.org/x/lint v0.0.0-20190227174305-5b3e6a55c961/go.mod h1:wehouNa3lNwaWXcvxsM5YxQ5yQlVC4a0KAMCusXpPoU= +golang.org/x/lint v0.0.0-20190301231843-5614ed5bae6f/go.mod h1:UVdnD1Gm6xHRNCYTkRU2/jEulfH38KcIWyp/GAMgvoE= golang.org/x/lint v0.0.0-20190313153728-d0100b6bd8b3/go.mod h1:6SW0HCj/g11FgYtHlgUYUwCkIfeOF89ocIRzGO/8vkc= +golang.org/x/lint v0.0.0-20190409202823-959b441ac422/go.mod h1:6SW0HCj/g11FgYtHlgUYUwCkIfeOF89ocIRzGO/8vkc= +golang.org/x/lint v0.0.0-20190909230951-414d861bb4ac/go.mod h1:6SW0HCj/g11FgYtHlgUYUwCkIfeOF89ocIRzGO/8vkc= +golang.org/x/lint v0.0.0-20190930215403-16217165b5de/go.mod h1:6SW0HCj/g11FgYtHlgUYUwCkIfeOF89ocIRzGO/8vkc= +golang.org/x/mobile v0.0.0-20190312151609-d3739f865fa6/go.mod h1:z+o9i4GpDbdi3rU15maQ/Ox0txvL9dWGYEHz965HBQE= +golang.org/x/mobile v0.0.0-20190719004257-d2bd2a29d028/go.mod h1:E/iHnbuqvinMTCcRqshq8CkpyQDoeVncDDYHnLhea+o= +golang.org/x/mod v0.0.0-20190513183733-4bf6d317e70e/go.mod h1:mXi4GBBbnImb6dmsKGUJ2LatrhH/nqhxcFungHvyanc= +golang.org/x/mod v0.1.0/go.mod h1:0QHyrYULN0/3qlju5TqG8bIK38QM8yzMo5ekMj3DlcY= golang.org/x/mod v0.6.0-dev.0.20220419223038-86c51ed26bb4/go.mod h1:jJ57K6gSWd91VN4djpZkiMVwK6gcyfeH4XE8wZrZaV4= golang.org/x/mod v0.17.0 h1:zY54UmvipHiNd+pm+m0x9KhZ9hl1/7QNMyxXbc6ICqA= golang.org/x/mod v0.17.0/go.mod h1:hTbmBsO62+eylJbnUtE2MGJUyE7QWk4xUqPFrRgJ+7c= golang.org/x/net v0.0.0-20180724234803-3673e40ba225/go.mod h1:mL1N/T3taQHkDXs73rZJwtUhF3w3ftmwwsq0BUmARs4= golang.org/x/net v0.0.0-20180826012351-8a410e7b638d/go.mod h1:mL1N/T3taQHkDXs73rZJwtUhF3w3ftmwwsq0BUmARs4= +golang.org/x/net v0.0.0-20181023162649-9b4f9f5ad519/go.mod h1:mL1N/T3taQHkDXs73rZJwtUhF3w3ftmwwsq0BUmARs4= +golang.org/x/net v0.0.0-20181114220301-adae6a3d119a/go.mod h1:mL1N/T3taQHkDXs73rZJwtUhF3w3ftmwwsq0BUmARs4= +golang.org/x/net v0.0.0-20181201002055-351d144fa1fc/go.mod h1:mL1N/T3taQHkDXs73rZJwtUhF3w3ftmwwsq0BUmARs4= +golang.org/x/net v0.0.0-20181220203305-927f97764cc3/go.mod h1:mL1N/T3taQHkDXs73rZJwtUhF3w3ftmwwsq0BUmARs4= +golang.org/x/net v0.0.0-20190108225652-1e06a53dbb7e/go.mod h1:mL1N/T3taQHkDXs73rZJwtUhF3w3ftmwwsq0BUmARs4= golang.org/x/net v0.0.0-20190213061140-3a22650c66bd/go.mod h1:mL1N/T3taQHkDXs73rZJwtUhF3w3ftmwwsq0BUmARs4= golang.org/x/net v0.0.0-20190311183353-d8887717615a/go.mod h1:t9HGtf8HONx5eT2rtn7q6eTqICYqUVnKs3thJo3Qplg= golang.org/x/net v0.0.0-20190404232315-eb5bcb51f2a3/go.mod h1:t9HGtf8HONx5eT2rtn7q6eTqICYqUVnKs3thJo3Qplg= +golang.org/x/net v0.0.0-20190501004415-9ce7a6920f09/go.mod h1:t9HGtf8HONx5eT2rtn7q6eTqICYqUVnKs3thJo3Qplg= +golang.org/x/net v0.0.0-20190503192946-f4e77d36d62c/go.mod h1:t9HGtf8HONx5eT2rtn7q6eTqICYqUVnKs3thJo3Qplg= +golang.org/x/net v0.0.0-20190603091049-60506f45cf65/go.mod h1:HSz+uSET+XFnRR8LxR5pz3Of3rY3CfYBVs4xY44aLks= golang.org/x/net v0.0.0-20190620200207-3b0461eec859/go.mod h1:z5CRVTTTmAJ677TzLLGU+0bjPO0LkuOLi4/5GtJWs/s= golang.org/x/net v0.0.0-20201110031124-69a78807bb2b/go.mod h1:sp8m0HH+o8qH0wwXwYZr8TS3Oi6o0r6Gce1SSxlDquU= golang.org/x/net v0.0.0-20210226172049-e18ecbb05110/go.mod h1:m0MpNAwzfU5UDzcl9v0D8zg8gWTRqZa9RBIspLL5mdg= @@ -296,17 +474,31 @@ golang.org/x/net v0.0.0-20220722155237-a158d28d115b/go.mod h1:XRhObCWvk6IyKnWLug golang.org/x/net v0.25.0 h1:d/OCCoBEUq33pjydKrGQhw7IlUPI2Oylr+8qLx49kac= golang.org/x/net v0.25.0/go.mod h1:JkAGAh7GEvH74S6FOH42FLoXpXbE/aqXSrIQjXgsiwM= golang.org/x/oauth2 v0.0.0-20180821212333-d2e6202438be/go.mod h1:N/0e6XlmueqKjAGxoOufVs8QHGRruUQn6yWY3a++T0U= +golang.org/x/oauth2 v0.0.0-20190226205417-e64efc72b421/go.mod h1:gOpvHmFTYa4IltrdGE7lF6nIHvwfUNPOp7c8zoXwtLw= +golang.org/x/oauth2 v0.0.0-20190604053449-0f29369cfe45/go.mod h1:gOpvHmFTYa4IltrdGE7lF6nIHvwfUNPOp7c8zoXwtLw= golang.org/x/oauth2 v0.17.0 h1:6m3ZPmLEFdVxKKWnKq4VqZ60gutO35zm+zrAHVmHyDQ= golang.org/x/oauth2 v0.17.0/go.mod h1:OzPDGQiuQMguemayvdylqddI7qcD9lnSDb+1FiwQ5HA= golang.org/x/sync v0.0.0-20180314180146-1d60e4601c6f/go.mod h1:RxMgew5VJxzue5/jJTE5uejpjVlOe/izrB70Jof72aM= golang.org/x/sync v0.0.0-20181108010431-42b317875d0f/go.mod h1:RxMgew5VJxzue5/jJTE5uejpjVlOe/izrB70Jof72aM= +golang.org/x/sync v0.0.0-20181221193216-37e7f081c4d4/go.mod h1:RxMgew5VJxzue5/jJTE5uejpjVlOe/izrB70Jof72aM= +golang.org/x/sync v0.0.0-20190227155943-e225da77a7e6/go.mod h1:RxMgew5VJxzue5/jJTE5uejpjVlOe/izrB70Jof72aM= golang.org/x/sync v0.0.0-20190423024810-112230192c58/go.mod h1:RxMgew5VJxzue5/jJTE5uejpjVlOe/izrB70Jof72aM= golang.org/x/sync v0.0.0-20220722155255-886fb9371eb4/go.mod h1:RxMgew5VJxzue5/jJTE5uejpjVlOe/izrB70Jof72aM= golang.org/x/sync v0.8.0 h1:3NFvSEYkUoMifnESzZl15y791HH1qU2xm6eCJU5ZPXQ= golang.org/x/sync v0.8.0/go.mod h1:Czt+wKu1gCyEFDUtn0jG5QVvpJ6rzVqr5aXyt9drQfk= +golang.org/x/sys v0.0.0-20180823144017-11551d06cbcc/go.mod h1:STP8DvDyc/dI5b8T5hshtkjS+E42TnysNCUPdjciGhY= golang.org/x/sys v0.0.0-20180830151530-49385e6e1522/go.mod h1:STP8DvDyc/dI5b8T5hshtkjS+E42TnysNCUPdjciGhY= +golang.org/x/sys v0.0.0-20180905080454-ebe1bf3edb33/go.mod h1:STP8DvDyc/dI5b8T5hshtkjS+E42TnysNCUPdjciGhY= +golang.org/x/sys v0.0.0-20181026203630-95b1ffbd15a5/go.mod h1:STP8DvDyc/dI5b8T5hshtkjS+E42TnysNCUPdjciGhY= +golang.org/x/sys v0.0.0-20181107165924-66b7b1311ac8/go.mod h1:STP8DvDyc/dI5b8T5hshtkjS+E42TnysNCUPdjciGhY= +golang.org/x/sys v0.0.0-20181116152217-5ac8a444bdc5/go.mod h1:STP8DvDyc/dI5b8T5hshtkjS+E42TnysNCUPdjciGhY= golang.org/x/sys v0.0.0-20190215142949-d0b11bdaac8a/go.mod h1:STP8DvDyc/dI5b8T5hshtkjS+E42TnysNCUPdjciGhY= +golang.org/x/sys v0.0.0-20190312061237-fead79001313/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20190412213103-97732733099d/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= +golang.org/x/sys v0.0.0-20190502145724-3ef323f4f1fd/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= +golang.org/x/sys v0.0.0-20190507160741-ecd444e8653b/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= +golang.org/x/sys v0.0.0-20190606165138-5da285871e9c/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= +golang.org/x/sys v0.0.0-20190624142023-c5567b49c5d0/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20190916202348-b4ddaad3f8a3/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20200930185726-fdedc70b468f/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= golang.org/x/sys v0.0.0-20201119102817-f84b799fce68/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= @@ -324,18 +516,35 @@ golang.org/x/term v0.0.0-20210927222741-03fcf44c2211/go.mod h1:jbD1KX2456YbFQfuX golang.org/x/term v0.20.0 h1:VnkxpohqXaOBYJtBmEppKUG6mXpi+4O6purfc2+sMhw= golang.org/x/term v0.20.0/go.mod h1:8UkIAJTvZgivsXaD6/pH6U9ecQzZ45awqEOzuCvwpFY= golang.org/x/text v0.3.0/go.mod h1:NqM8EUOU14njkJ3fqMW+pc6Ldnwhi/IjpwHt7yyuwOQ= +golang.org/x/text v0.3.1-0.20180807135948-17ff2d5776d2/go.mod h1:NqM8EUOU14njkJ3fqMW+pc6Ldnwhi/IjpwHt7yyuwOQ= +golang.org/x/text v0.3.2/go.mod h1:bEr9sfX3Q8Zfm5fL9x+3itogRgK3+ptLWKqgva+5dAk= golang.org/x/text v0.3.3/go.mod h1:5Zoc/QRtKVWzQhOtBMvqHzDpF6irO9z98xDceosuGiQ= golang.org/x/text v0.3.7/go.mod h1:u+2+/6zg+i71rQMx5EYifcz6MCKuco9NR6JIITiCfzQ= golang.org/x/text v0.3.8/go.mod h1:E6s5w1FMmriuDzIBO73fBruAKo1PCIq6d2Q6DHfQ8WQ= golang.org/x/text v0.18.0 h1:XvMDiNzPAl0jr17s6W9lcaIhGUfUORdGCNsuLmPG224= golang.org/x/text v0.18.0/go.mod h1:BuEKDfySbSR4drPmRPG/7iBdf8hvFMuRexcpahXilzY= +golang.org/x/time v0.0.0-20181108054448-85acf8d2951c/go.mod h1:tRJNPiyCQ0inRvYxbN9jk5I+vvW/OXSQhTDSoE431IQ= +golang.org/x/time v0.0.0-20190308202827-9d24e82272b4/go.mod h1:tRJNPiyCQ0inRvYxbN9jk5I+vvW/OXSQhTDSoE431IQ= golang.org/x/time v0.5.0 h1:o7cqy6amK/52YcAKIPlM3a+Fpj35zvRj2TP+e1xFSfk= golang.org/x/time v0.5.0/go.mod h1:3BpzKBy/shNhVucY/MWOyx10tF3SFh9QdLuxbVysPQM= +golang.org/x/tools v0.0.0-20180221164845-07fd8470d635/go.mod h1:n7NCudcB/nEzxVGmLbDWY5pfWTLqBcC2KZ6jyYvM4mQ= golang.org/x/tools v0.0.0-20180917221912-90fa682c2a6e/go.mod h1:n7NCudcB/nEzxVGmLbDWY5pfWTLqBcC2KZ6jyYvM4mQ= golang.org/x/tools v0.0.0-20190114222345-bf090417da8b/go.mod h1:n7NCudcB/nEzxVGmLbDWY5pfWTLqBcC2KZ6jyYvM4mQ= golang.org/x/tools v0.0.0-20190226205152-f727befe758c/go.mod h1:9Yl7xja0Znq3iFh3HoIrodX9oNMXvdceNzlUR8zjMvY= golang.org/x/tools v0.0.0-20190311212946-11955173bddd/go.mod h1:LCzVGOaR6xXOjkQ3onu1FJEFr0SW1gC7cKk1uF8kGRs= +golang.org/x/tools v0.0.0-20190312151545-0bb0c0a6e846/go.mod h1:LCzVGOaR6xXOjkQ3onu1FJEFr0SW1gC7cKk1uF8kGRs= +golang.org/x/tools v0.0.0-20190312170243-e65039ee4138/go.mod h1:LCzVGOaR6xXOjkQ3onu1FJEFr0SW1gC7cKk1uF8kGRs= +golang.org/x/tools v0.0.0-20190328211700-ab21143f2384/go.mod h1:LCzVGOaR6xXOjkQ3onu1FJEFr0SW1gC7cKk1uF8kGRs= +golang.org/x/tools v0.0.0-20190425150028-36563e24a262/go.mod h1:RgjU9mgBXZiqYHBnxXauZ1Gv1EHHAz9KjViQ78xBX0Q= +golang.org/x/tools v0.0.0-20190506145303-2d16b83fe98c/go.mod h1:RgjU9mgBXZiqYHBnxXauZ1Gv1EHHAz9KjViQ78xBX0Q= golang.org/x/tools v0.0.0-20190524140312-2c0ae7006135/go.mod h1:RgjU9mgBXZiqYHBnxXauZ1Gv1EHHAz9KjViQ78xBX0Q= +golang.org/x/tools v0.0.0-20190606124116-d0a3d012864b/go.mod h1:/rFqwRUd4F7ZHNgwSSTFct+R/Kf4OFW1sUzUTQQTgfc= +golang.org/x/tools v0.0.0-20190621195816-6e04913cbbac/go.mod h1:/rFqwRUd4F7ZHNgwSSTFct+R/Kf4OFW1sUzUTQQTgfc= +golang.org/x/tools v0.0.0-20190628153133-6cdbf07be9d0/go.mod h1:/rFqwRUd4F7ZHNgwSSTFct+R/Kf4OFW1sUzUTQQTgfc= +golang.org/x/tools v0.0.0-20190816200558-6889da9d5479/go.mod h1:b+2E5dAYhXwXZwtnZ6UAqBI28+e2cm9otk0dWdXHAEo= +golang.org/x/tools v0.0.0-20190911174233-4f2ddba30aff/go.mod h1:b+2E5dAYhXwXZwtnZ6UAqBI28+e2cm9otk0dWdXHAEo= +golang.org/x/tools v0.0.0-20191012152004-8de300cfc20a/go.mod h1:b+2E5dAYhXwXZwtnZ6UAqBI28+e2cm9otk0dWdXHAEo= +golang.org/x/tools v0.0.0-20191112195655-aa38f8e97acc/go.mod h1:b+2E5dAYhXwXZwtnZ6UAqBI28+e2cm9otk0dWdXHAEo= golang.org/x/tools v0.0.0-20191119224855-298f0cb1881e/go.mod h1:b+2E5dAYhXwXZwtnZ6UAqBI28+e2cm9otk0dWdXHAEo= golang.org/x/tools v0.1.12/go.mod h1:hNGJHUnrk76NpqgfD5Aqm5Crs+Hm0VOH/i9J2+nxYbc= golang.org/x/tools v0.21.1-0.20240508182429-e35e4ccd0d2d h1:vU5i/LfpvrRCpgM/VPfJLg5KjxD3E+hfT1SH+d9zLwg= @@ -344,14 +553,28 @@ golang.org/x/xerrors v0.0.0-20190717185122-a985d3407aa7/go.mod h1:I/5z698sn9Ka8T golang.org/x/xerrors v0.0.0-20191204190536-9bdfabe68543/go.mod h1:I/5z698sn9Ka8TeJc9MKroUUfqBBauWjQqLJ2OPfmY0= golang.org/x/xerrors v0.0.0-20231012003039-104605ab7028 h1:+cNy6SZtPcJQH3LJVLOSmiC7MMxXNOb3PU/VUEz+EhU= golang.org/x/xerrors v0.0.0-20231012003039-104605ab7028/go.mod h1:NDW/Ps6MPRej6fsCIbMTohpP40sJ/P/vI1MoTEGwX90= +google.golang.org/api v0.4.0/go.mod h1:8k5glujaEP+g9n7WNsDg8QP6cUVNI86fCNMcbazEtwE= +google.golang.org/api v0.7.0/go.mod h1:WtwebWUNSVBH/HAw79HIFXZNqEvBhG+Ra+ax0hx3E3M= +google.golang.org/api v0.8.0/go.mod h1:o4eAsZoiT+ibD93RtjEohWalFOjRDx6CVaqeizhEnKg= +google.golang.org/api v0.9.0/go.mod h1:o4eAsZoiT+ibD93RtjEohWalFOjRDx6CVaqeizhEnKg= +google.golang.org/api v0.13.0/go.mod h1:iLdEw5Ide6rF15KTC1Kkl0iskquN2gFfn9o9XIsbkAI= google.golang.org/api v0.167.0 h1:CKHrQD1BLRii6xdkatBDXyKzM0mkawt2QP+H3LtPmSE= google.golang.org/api v0.167.0/go.mod h1:4FcBc686KFi7QI/U51/2GKKevfZMpM17sCdibqe/bSA= google.golang.org/appengine v1.1.0/go.mod h1:EbEs0AVv82hx2wNQdGPgUI5lhzA/G0D9YwlJXL52JkM= google.golang.org/appengine v1.4.0/go.mod h1:xpcJRLb0r/rnEns0DIKYYv+WjYCduHsrkT7/EB5XEv4= +google.golang.org/appengine v1.5.0/go.mod h1:xpcJRLb0r/rnEns0DIKYYv+WjYCduHsrkT7/EB5XEv4= +google.golang.org/appengine v1.6.1/go.mod h1:i06prIuMbXzDqacNJfV5OdTW448YApPu5ww/cMBSeb0= google.golang.org/appengine v1.6.8 h1:IhEN5q69dyKagZPYMSdIjS2HqprW324FRQZJcGqPAsM= google.golang.org/appengine v1.6.8/go.mod h1:1jJ3jBArFh5pcgW8gCtRJnepW8FzD1V44FJffLiz/Ds= google.golang.org/genproto v0.0.0-20180817151627-c66870c02cf8/go.mod h1:JiN7NxoALGmiZfu7CAH4rXhgtRTLTxftemlI0sWmxmc= +google.golang.org/genproto v0.0.0-20190307195333-5fe7a883aa19/go.mod h1:VzzqZJRnGkLBvHegQrXjBqPurQTc5/KpmUdxsrq26oE= +google.golang.org/genproto v0.0.0-20190418145605-e7d98fc518a7/go.mod h1:VzzqZJRnGkLBvHegQrXjBqPurQTc5/KpmUdxsrq26oE= +google.golang.org/genproto v0.0.0-20190425155659-357c62f0e4bb/go.mod h1:VzzqZJRnGkLBvHegQrXjBqPurQTc5/KpmUdxsrq26oE= +google.golang.org/genproto v0.0.0-20190502173448-54afdca5d873/go.mod h1:VzzqZJRnGkLBvHegQrXjBqPurQTc5/KpmUdxsrq26oE= +google.golang.org/genproto v0.0.0-20190801165951-fa694d86fc64/go.mod h1:DMBHOl98Agz4BDEuKkezgsaosCRResVns1a3J2ZsMNc= google.golang.org/genproto v0.0.0-20190819201941-24fa4b261c55/go.mod h1:DMBHOl98Agz4BDEuKkezgsaosCRResVns1a3J2ZsMNc= +google.golang.org/genproto v0.0.0-20190911173649-1774047e7e51/go.mod h1:IbNlFCBrqXvoKpeg0TB2l7cyZUmoaFKYIwrEpbDKLA8= +google.golang.org/genproto v0.0.0-20191108220845-16a3f7862a1a/go.mod h1:n3cpQtvxv34hfy77yVDNjmbRyujviMdxYliBSkLhpCc= google.golang.org/genproto v0.0.0-20200526211855-cb27e3aa2013/go.mod h1:NbSheEEYHJ7i3ixzK3sjbqSGDJWnxyFXZblF3eUsNvo= google.golang.org/genproto v0.0.0-20240213162025-012b6fc9bca9 h1:9+tzLLstTlPTRyJTh+ah5wIMsBW5c4tQwGTN3thOW9Y= google.golang.org/genproto v0.0.0-20240213162025-012b6fc9bca9/go.mod h1:mqHbVIp48Muh7Ywss/AD6I5kNVKZMmAa/QEW58Gxp2s= @@ -360,6 +583,8 @@ google.golang.org/genproto/googleapis/api v0.0.0-20240304161311-37d4d3c04a78/go. google.golang.org/genproto/googleapis/rpc v0.0.0-20240228224816-df926f6c8641 h1:DKU1r6Tj5s1vlU/moGhuGz7E3xRfwjdAfDzbsaQJtEY= google.golang.org/genproto/googleapis/rpc v0.0.0-20240228224816-df926f6c8641/go.mod h1:UCOku4NytXMJuLQE5VuqA5lX3PcHCBo8pxNyvkf4xBs= google.golang.org/grpc v1.19.0/go.mod h1:mqu4LbDTu4XGKhr4mRzUsmM4RtVoemTSY81AxZiDr8c= +google.golang.org/grpc v1.20.1/go.mod h1:10oTOabMzJvdu6/UiuZezV6QK5dSlG84ov/aaiqXj38= +google.golang.org/grpc v1.21.1/go.mod h1:oYelfM1adQP15Ek0mdvEgi9Df8B9CZIaU1084ijfRaM= google.golang.org/grpc v1.23.0/go.mod h1:Y5yQAOtifL1yxbo5wqy6BxZv8vAUGQwXBOALyacEbxg= google.golang.org/grpc v1.25.1/go.mod h1:c3i+UQWmh7LiEpx4sFZnkU36qjEYZ0imhYfXVyQciAY= google.golang.org/grpc v1.27.0/go.mod h1:qbnxyOmOxrQa7FizSgH+ReBfzJrCY1pSN7KXBS8abTk= @@ -379,9 +604,17 @@ google.golang.org/protobuf v1.26.0-rc.1/go.mod h1:jlhhOSvTdKEhbULTjvd4ARK9grFBp0 google.golang.org/protobuf v1.26.0/go.mod h1:9q0QmTI4eRPtz6boOQmLYwt+qCgq0jsYwAQnmE0givc= google.golang.org/protobuf v1.34.2 h1:6xV6lTsCfpGD21XK49h7MhtcApnLqkfYgPcdHftf6hg= google.golang.org/protobuf v1.34.2/go.mod h1:qYOHts0dSfpeUzUFpOMr/WGzszTmLH+DiWniOlNbLDw= +gopkg.in/alecthomas/kingpin.v2 v2.2.6/go.mod h1:FMv+mEhP44yOT+4EoQTLFTRgOQ1FBLkstjWtayDeSgw= gopkg.in/check.v1 v0.0.0-20161208181325-20d25e280405/go.mod h1:Co6ibVJAznAaIkqp8huTwlJQCZ016jof/cbN4VW5Yz0= +gopkg.in/check.v1 v1.0.0-20180628173108-788fd7840127/go.mod h1:Co6ibVJAznAaIkqp8huTwlJQCZ016jof/cbN4VW5Yz0= +gopkg.in/errgo.v2 v2.1.0/go.mod h1:hNsd1EY+bozCKY1Ytp96fpM3vjJbqLJn88ws8XvfDNI= +gopkg.in/ini.v1 v1.51.0/go.mod h1:pNLf8WUiyNEtQjuu5G5vTm06TEv9tsIgeAvK8hOrP4k= gopkg.in/natefinch/lumberjack.v2 v2.2.1 h1:bBRl1b0OH9s/DuPhuXpNl+VtCaJXFZ5/uEFST95x9zc= gopkg.in/natefinch/lumberjack.v2 v2.2.1/go.mod h1:YD8tP3GAjkrDg1eZH7EGmyESg/lsYskCTPBJVb9jqSc= +gopkg.in/resty.v1 v1.12.0/go.mod h1:mDo4pnntr5jdWRML875a/NmxYqAlA73dVijT2AXvQQo= +gopkg.in/yaml.v2 v2.0.0-20170812160011-eb3733d160e7/go.mod h1:JAlM8MvJe8wmxCU4Bli9HhUf9+ttbYbLASfIpnQbh74= +gopkg.in/yaml.v2 v2.2.1/go.mod h1:hI93XBmqTisBFMUTm0b8Fm+jr3Dg1NNxqwp+5A1VGuI= +gopkg.in/yaml.v2 v2.2.4/go.mod h1:hI93XBmqTisBFMUTm0b8Fm+jr3Dg1NNxqwp+5A1VGuI= gopkg.in/yaml.v2 v2.2.8/go.mod h1:hI93XBmqTisBFMUTm0b8Fm+jr3Dg1NNxqwp+5A1VGuI= gopkg.in/yaml.v2 v2.4.0 h1:D8xgwECY7CYvx+Y2n4sBz93Jn9JRvxdiyyo8CTfuKaY= gopkg.in/yaml.v2 v2.4.0/go.mod h1:RDklbk79AGWmwhnvt/jBztapEOGDOx6ZbXqjP6csGnQ= @@ -389,6 +622,10 @@ gopkg.in/yaml.v3 v3.0.0-20200313102051-9f266ea9e77c/go.mod h1:K4uyk7z7BCEPqu6E+C gopkg.in/yaml.v3 v3.0.1 h1:fxVm/GzAzEWqLHuvctI91KS9hhNmmWOoWu0XTYJS7CA= gopkg.in/yaml.v3 v3.0.1/go.mod h1:K4uyk7z7BCEPqu6E+C64Yfv1cQ7kz7rIZviUmN+EgEM= honnef.co/go/tools v0.0.0-20190102054323-c2f93a96b099/go.mod h1:rf3lG4BRIbNafJWhAfAdb/ePZxsR/4RtNHQocxwk9r4= +honnef.co/go/tools v0.0.0-20190106161140-3f1c8253044a/go.mod h1:rf3lG4BRIbNafJWhAfAdb/ePZxsR/4RtNHQocxwk9r4= +honnef.co/go/tools v0.0.0-20190418001031-e561f6794a2a/go.mod h1:rf3lG4BRIbNafJWhAfAdb/ePZxsR/4RtNHQocxwk9r4= honnef.co/go/tools v0.0.0-20190523083050-ea95bdfd59fc/go.mod h1:rf3lG4BRIbNafJWhAfAdb/ePZxsR/4RtNHQocxwk9r4= +honnef.co/go/tools v0.0.1-2019.2.3/go.mod h1:a3bituU0lyd329TUQxRnasdCoJDkEUEAqEt0JzvZhAg= +rsc.io/binaryregexp v0.2.0/go.mod h1:qTv7/COck+e2FymRvadv62gMdZztPaShugOCi3I+8D8= rsc.io/tmplfunc v0.0.3 h1:53XFQh69AfOa8Tw0Jm7t+GV7KZhOi6jzsCzTtKbMvzU= rsc.io/tmplfunc v0.0.3/go.mod h1:AG3sTPzElb1Io3Yg4voV9AGZJuleGAwaVRxL9M49PhA= diff --git a/indexer/db.go b/indexer/db.go index fff37c9..3990c50 100644 --- a/indexer/db.go +++ b/indexer/db.go @@ -8,9 +8,10 @@ import ( "fmt" "io/ioutil" "log" + "math/big" "os" - "strconv" "strings" + "reflect" "time" "github.com/ethereum/go-ethereum/accounts/abi" @@ -33,17 +34,28 @@ func TransactionsTableName(blockchain string) string { return fmt.Sprintf(blockchain + "_transactions") } -func hexStringToInt(hexString string) (int64, error) { - // Remove the "0x" prefix from the hexadecimal string - hexString = strings.TrimPrefix(hexString, "0x") +func RawTransactionsTableName(blockchain string) string { + return fmt.Sprintf(blockchain + "_transactions") +} - // Parse the hexadecimal string to an integer - intValue, err := strconv.ParseInt(hexString, 16, 64) - if err != nil { - return 0, err - } - return intValue, nil +// Helper function to convert hex string to nullable big.Int +func hexStringToBigInt(hexString string) (*big.Int, error) { + if hexString == "" { + return nil, nil + } + + // Remove the "0x" prefix + hexString = strings.TrimPrefix(hexString, "0x") + + // Parse hex string to big.Int + value := new(big.Int) + value, success := value.SetString(hexString, 16) + if !success { + return nil, fmt.Errorf("failed to parse hex string: %s", hexString) + } + + return value, nil } // https://klotzandrew.com/blog/postgres-passing-65535-parameter-limit/ insted of batching @@ -250,12 +262,33 @@ func decodeAddress(address string) ([]byte, error) { } // updateValues updates the values in the map for a given key -func updateValues(valuesMap map[string]UnnestInsertValueStruct, key string, value interface{}) { - tmp := valuesMap[key] - tmp.Values = append(tmp.Values, value) - valuesMap[key] = tmp +func updateValues(valuesMap map[string]UnnestInsertValueStruct, key string, val interface{}) { + entry, ok := valuesMap[key] + if !ok { + return + } + + value := determineValue(val) + entry.Values = append(entry.Values, value) + valuesMap[key] = entry } +// determineValue handles type checking and conversion logic +func determineValue(val interface{}) interface{} { + // Handle nil interface + if val == nil { + return nil + } + + rv := reflect.ValueOf(val) + + // Handle typed nil pointer + if rv.Kind() == reflect.Ptr && rv.IsNil() { + return nil + } + // Return value as-is for other types + return val +} func (p *PostgreSQLpgx) WriteIndexes(blockchain string, blocksIndexPack []BlockIndex) error { ctx := context.Background() @@ -313,8 +346,6 @@ func (p *PostgreSQLpgx) executeBatchInsert(tx pgx.Tx, ctx context.Context, table valuesSlice = append(valuesSlice, values[column].Values) } - // track execution time - if _, err := tx.Exec(ctx, query, valuesSlice...); err != nil { log.Println("Error executing bulk insert", err) return fmt.Errorf("error executing bulk insert for batch: %w", err) @@ -785,7 +816,7 @@ func (p *PostgreSQLpgx) WriteLabes( blockchain string, txCalls []TransactionLabel, events []EventLabel, - transactions []RawTransaction, + rawTransactions []RawTransaction, ) error { pool := p.GetPool() @@ -827,6 +858,8 @@ func (p *PostgreSQLpgx) WriteLabes( } } + fmt.Println("Writing events labels ", len(events)) + if len(events) > 0 { err := p.WriteEvents(tx, blockchain, events) if err != nil { @@ -834,15 +867,13 @@ func (p *PostgreSQLpgx) WriteLabes( return err } } - - if len(transactions) > 0 { - err := p.WriteRawTransactions(tx, blockchain, transactions) + if len(rawTransactions) > 0 { + err := p.WriteRawTransactions(tx, blockchain, rawTransactions) if err != nil { log.Println("Error writing raw transactions:", err) return err } } - return err } @@ -1084,6 +1115,191 @@ func (p *PostgreSQLpgx) WriteTxCalls(tx pgx.Tx, blockchain string, transactions return nil } + +func (p *PostgreSQLpgx) WriteRawTransactions(tx pgx.Tx, blockchain string, rawTransactions []RawTransaction) error { + tableName := RawTransactionsTableName(blockchain) + isBlockchainWithL1Chain := IsBlockchainWithL1Chain(blockchain) + + columns := []string{"hash", "block_hash", "block_timestamp", "block_number", + "from_address", "to_address", "gas", "gas_price", "input", "nonce", + "max_fee_per_gas", "max_priority_fee_per_gas", "transaction_index", + "transaction_type", "value"} + + if isBlockchainWithL1Chain { + columns = append(columns, "l1_block_number") + } + + var valuesMap = make(map[string]UnnestInsertValueStruct) + + valuesMap["hash"] = UnnestInsertValueStruct{ + Type: "TEXT", + Values: make([]interface{}, 0), + } + + valuesMap["block_hash"] = UnnestInsertValueStruct{ + Type: "TEXT", + Values: make([]interface{}, 0), + } + + valuesMap["block_timestamp"] = UnnestInsertValueStruct{ + Type: "BIGINT", + Values: make([]interface{}, 0), + } + + valuesMap["block_number"] = UnnestInsertValueStruct{ + Type: "BIGINT", + Values: make([]interface{}, 0), + } + + valuesMap["from_address"] = UnnestInsertValueStruct{ + Type: "BYTEA", + Values: make([]interface{}, 0), + } + + valuesMap["to_address"] = UnnestInsertValueStruct{ + Type: "BYTEA", + Values: make([]interface{}, 0), + } + + valuesMap["gas"] = UnnestInsertValueStruct{ + Type: "NUMERIC", + Values: make([]interface{}, 0), + } + + valuesMap["gas_price"] = UnnestInsertValueStruct{ + Type: "NUMERIC", + Values: make([]interface{}, 0), + } + + valuesMap["input"] = UnnestInsertValueStruct{ + Type: "TEXT", + Values: make([]interface{}, 0), + } + + valuesMap["nonce"] = UnnestInsertValueStruct{ + Type: "TEXT", + Values: make([]interface{}, 0), + } + + valuesMap["max_fee_per_gas"] = UnnestInsertValueStruct{ + Type: "NUMERIC", + Values: make([]interface{}, 0), + } + + valuesMap["max_priority_fee_per_gas"] = UnnestInsertValueStruct{ + Type: "NUMERIC", + Values: make([]interface{}, 0), + } + + valuesMap["transaction_index"] = UnnestInsertValueStruct{ + Type: "BIGINT", + Values: make([]interface{}, 0), + } + + valuesMap["transaction_type"] = UnnestInsertValueStruct{ + Type: "INTEGER", + Values: make([]interface{}, 0), + } + + valuesMap["value"] = UnnestInsertValueStruct{ + Type: "NUMERIC", + Values: make([]interface{}, 0), + } + + valuesMap["indexed_at"] = UnnestInsertValueStruct{ + Type: "TIMESTAMP WITH TIME ZONE", + Values: make([]interface{}, 0), + } + + if isBlockchainWithL1Chain { + valuesMap["l1_block_number"] = UnnestInsertValueStruct{ + Type: "BIGINT", + Values: make([]interface{}, 0), + } + } + + // Now appending to the Values slice works without errors. + for _, rawTransaction := range rawTransactions { + fromAddress, err := decodeAddress(rawTransaction.FromAddress) + if err != nil { + return err + } + + toAddress, err := decodeAddress(rawTransaction.ToAddress) + if err != nil { + return err + } + + gas, err := hexStringToBigInt(rawTransaction.Gas) + if err != nil { + log.Printf("error parsing gas for transaction %s: %v", rawTransaction.Hash, err) + return err + } + gasPrice, err := hexStringToBigInt(rawTransaction.GasPrice) + if err != nil { + log.Printf("error parsing gas price for transaction %s: %v", rawTransaction.Hash, err) + return err + } + + maxFeePerGas, err := hexStringToBigInt(rawTransaction.MaxFeePerGas) + if err != nil { + log.Printf("error parsing max fee per gas for transaction %s: %v", rawTransaction.Hash, err) + return err + } + + maxPriorityFeePerGas, err := hexStringToBigInt(rawTransaction.MaxPriorityFeePerGas) + if err != nil { + log.Printf("error parsing max priority fee per gas for transaction %s: %v", rawTransaction.Hash, err) + return err + } + + + value, err := hexStringToBigInt(rawTransaction.Value) + if err != nil { + log.Printf("error parsing value for transaction %s: %v", rawTransaction.Hash, err) + return err + } + + + + updateValues(valuesMap, "hash", rawTransaction.Hash) + updateValues(valuesMap, "block_hash", rawTransaction.BlockHash) + updateValues(valuesMap, "block_timestamp", rawTransaction.BlockTimestamp) + updateValues(valuesMap, "block_number", rawTransaction.BlockNumber) + updateValues(valuesMap, "from_address", fromAddress) + updateValues(valuesMap, "to_address", toAddress) + updateValues(valuesMap, "gas", gas) + updateValues(valuesMap, "gas_price", gasPrice) + updateValues(valuesMap, "input", rawTransaction.Input) + updateValues(valuesMap, "nonce", rawTransaction.Nonce) + updateValues(valuesMap, "max_fee_per_gas", maxFeePerGas) + updateValues(valuesMap, "max_priority_fee_per_gas", maxPriorityFeePerGas) + updateValues(valuesMap, "transaction_index", rawTransaction.TransactionIndex) + updateValues(valuesMap, "transaction_type", rawTransaction.TransactionType) + updateValues(valuesMap, "value", value) + if isBlockchainWithL1Chain { + var l1Bn interface{} + if rawTransaction.L1BlockNumber != nil { + l1Bn = *rawTransaction.L1BlockNumber + } else { + l1Bn = nil + } + updateValues(valuesMap, "l1_block_number", l1Bn) + } + } + + ctx := context.Background() + + // Insert them in batch + err := p.executeBatchInsert(tx, ctx, tableName, columns, valuesMap, "ON CONFLICT DO NOTHING") + if err != nil { + return err + } + + log.Printf("Saved %d transactions records into %s table", len(rawTransactions), tableName) + return nil +} + func (p *PostgreSQLpgx) CleanIndexes(blockchain string, batchLimit uint64, sleepTime int) error { pool := p.GetPool() diff --git a/indexer/types.go b/indexer/types.go index 1af4043..c792118 100644 --- a/indexer/types.go +++ b/indexer/types.go @@ -121,24 +121,6 @@ type TransactionLabel struct { BlockTimestamp uint64 } -type RawTransaction struct { - L1BlockNumber uint64 - Hash string - BlockTimestamp uint64 - BlockHash string - FromAddress string - ToAddress string - Gas uint64 - GasPrice uint64 - MaxFeePerGas uint64 - MaxPriorityFeePerGas uint64 - Input string - Nonce uint64 - TransactionIndex uint64 - TransactionType int - Value uint64 -} - type AbiJobsDeployInfo struct { DeployedBlockNumber uint64 IDs []string @@ -151,3 +133,27 @@ type AbiEntry struct { AbiType string `json:"abi_type"` Once sync.Once } + +type RawTransaction struct { + // Required fields + Hash string `json:"hash"` + BlockHash string `json:"blockHash"` + BlockTimestamp uint64 `json:"block_timestamp"` + BlockNumber uint64 `json:"blockNumber"` + FromAddress string `json:"from"` + ToAddress string `json:"to"` + Gas string `json:"gas"` + GasPrice string `json:"gasPrice"` + Input string `json:"input"` + Nonce string `json:"nonce"` + Value string `json:"value"` + + // Optional fields that might be zero/empty + MaxFeePerGas string `json:"maxFeePerGas,omitempty"` + MaxPriorityFeePerGas string `json:"maxPriorityFeePerGas,omitempty"` + TransactionIndex uint64 `json:"transactionIndex"` + TransactionType uint64 `json:"transactionType,omitempty"` + + // Chain-specific optional fields + L1BlockNumber *uint64 `json:"l1BlockNumber,omitempty"` // L2 chains only +} \ No newline at end of file diff --git a/synchronizer/synchronizer.go b/synchronizer/synchronizer.go index 17d0ea8..feb5b80 100644 --- a/synchronizer/synchronizer.go +++ b/synchronizer/synchronizer.go @@ -779,13 +779,14 @@ func (d *Synchronizer) processProtoCustomerUpdate( var listDecodedEvents []indexer.EventLabel var listDecodedTransactions []indexer.TransactionLabel - + var listRawTransactions []indexer.RawTransaction for _, rawData := range rawDataList { // Decode the raw data to transactions - decodedEvents, decodedTransactions, err := d.Client.DecodeProtoEntireBlockToLabels(&rawData, update.Abis, d.threads) + decodedEvents, decodedTransactions, rawTransactions, err := d.Client.DecodeProtoEntireBlockToLabels(&rawData, update.Abis, d.threads) listDecodedEvents = append(listDecodedEvents, decodedEvents...) listDecodedTransactions = append(listDecodedTransactions, decodedTransactions...) + listRawTransactions = append(listRawTransactions, rawTransactions...) if err != nil { errChan <- fmt.Errorf("error decoding data for customer %s: %w", update.CustomerID, err) @@ -793,7 +794,7 @@ func (d *Synchronizer) processProtoCustomerUpdate( } } - err = customer.Pgx.WriteLabes(d.blockchain, listDecodedTransactions, listDecodedEvents) + err = customer.Pgx.WriteLabes(d.blockchain, listDecodedTransactions, listDecodedEvents, listRawTransactions) if err != nil { errChan <- fmt.Errorf("error writing labels for customer %s: %w", update.CustomerID, err)