Skip to content

Commit

Permalink
updated traceMode to geth
Browse files Browse the repository at this point in the history
  • Loading branch information
Monika-Bitfly committed Oct 30, 2024
1 parent e272839 commit 335b29c
Show file tree
Hide file tree
Showing 5 changed files with 6 additions and 6 deletions.
2 changes: 1 addition & 1 deletion cmd/eth1indexer/main.go
Original file line number Diff line number Diff line change
Expand Up @@ -48,7 +48,7 @@ func main() {
offsetBlocks := flag.Int64("blocks.offset", 100, "Blocks offset")
checkBlocksGaps := flag.Bool("blocks.gaps", false, "Check for gaps in the blocks table")
checkBlocksGapsLookback := flag.Int("blocks.gaps.lookback", 1000000, "Lookback for gaps check of the blocks table")
traceMode := flag.String("blocks.tracemode", "parity/geth", "Trace mode to use, can bei either 'parity', 'geth' or 'parity/geth' for both")
traceMode := flag.String("blocks.tracemode", "geth", "Trace mode to use, can bei either 'parity', 'geth' or 'parity/geth' for both")

concurrencyData := flag.Int64("data.concurrency", 30, "Concurrency to use when indexing data from bigtable")
startData := flag.Int64("data.start", 0, "Block to start indexing")
Expand Down
4 changes: 2 additions & 2 deletions cmd/misc/main.go
Original file line number Diff line number Diff line change
Expand Up @@ -1129,7 +1129,7 @@ func debugBlocks() error {
}
// logrus.WithFields(logrus.Fields{"block": i, "data": fmt.Sprintf("%+v", b)}).Infof("block from bt")

elBlock, _, err := elClient.GetBlock(int64(i), "parity/geth")
elBlock, _, err := elClient.GetBlock(int64(i), "geth")
if err != nil {
return err
}
Expand Down Expand Up @@ -1597,7 +1597,7 @@ func indexMissingBlocks(start uint64, end uint64, bt *db.Bigtable, client *rpc.E
if _, err := db.BigtableClient.GetBlockFromBlocksTable(block); err != nil {
logrus.Infof("could not load [%v] from blocks table, will try to fetch it from the node and save it", block)

bc, _, err := client.GetBlock(int64(block), "parity/geth")
bc, _, err := client.GetBlock(int64(block), "geth")
if err != nil {
utils.LogError(err, fmt.Sprintf("error getting block %v from the node", block), 0)
return
Expand Down
2 changes: 1 addition & 1 deletion db/db_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -85,7 +85,7 @@ func TestTxRevertTransformer(t *testing.T) {
}
for _, tt := range tests {
t.Run(tt.name, func(t *testing.T) {
block, _, err := erigon.GetBlock(tt.block, "parity/geth")
block, _, err := erigon.GetBlock(tt.block, "geth")
if err != nil {
t.Fatal(err)
}
Expand Down
2 changes: 1 addition & 1 deletion eth1data/eth1data_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -87,7 +87,7 @@ func TestGetEth1Transaction(t *testing.T) {
}
for _, tt := range tests {
t.Run(tt.name, func(t *testing.T) {
block, _, err := erigon.GetBlock(tt.block, "parity/geth")
block, _, err := erigon.GetBlock(tt.block, "geth")
if err != nil {
t.Fatal(err)
}
Expand Down
2 changes: 1 addition & 1 deletion handlers/eth1Block.go
Original file line number Diff line number Diff line change
Expand Up @@ -126,7 +126,7 @@ func Eth1Block(w http.ResponseWriter, r *http.Request) {
func GetExecutionBlockPageData(number uint64, limit int) (*types.Eth1BlockPageData, error) {
block, err := db.BigtableClient.GetBlockFromBlocksTable(number)
if diffToHead := int64(services.LatestEth1BlockNumber()) - int64(number); err != nil && diffToHead < 0 && diffToHead >= -5 {
block, _, err = rpc.CurrentErigonClient.GetBlock(int64(number), "parity/geth")
block, _, err = rpc.CurrentErigonClient.GetBlock(int64(number), "geth")
}
if err != nil {
return nil, err
Expand Down

0 comments on commit 335b29c

Please sign in to comment.