Skip to content

Commit

Permalink
hotfix ReindexBlocks
Browse files Browse the repository at this point in the history
  • Loading branch information
altergui committed Sep 9, 2024
1 parent 1eadd31 commit 50aeb10
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 6 deletions.
6 changes: 0 additions & 6 deletions vochain/indexer/indexer.go
Original file line number Diff line number Diff line change
Expand Up @@ -455,14 +455,9 @@ func (idx *Indexer) ReindexBlocks(inTest bool) {
return
}

idxBlockCount, err := idx.CountBlocks()
if err != nil {
log.Warnf("indexer CountBlocks returned error: %s", err)
}
log.Infow("start reindexing",
"blockStoreBase", idx.App.Node.BlockStore().Base(),
"blockStoreHeight", idx.App.Node.BlockStore().Height(),
"indexerBlockCount", idxBlockCount,
)
queries := idx.blockTxQueries()
for height := idx.App.Node.BlockStore().Base(); height <= idx.App.Node.BlockStore().Height(); height++ {
Expand Down Expand Up @@ -515,7 +510,6 @@ func (idx *Indexer) ReindexBlocks(inTest bool) {
log.Infow("finished reindexing",
"blockStoreBase", idx.App.Node.BlockStore().Base(),
"blockStoreHeight", idx.App.Node.BlockStore().Height(),
"indexerBlockCount", idxBlockCount,
)
}

Expand Down
5 changes: 5 additions & 0 deletions vochain/indexer/migrations/0019_dummy.sql
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
-- +goose Up
-- intentionally does nothing

-- This is a no-op command in SQLite, used just to have a valid SQL statement.
SELECT 1;

0 comments on commit 50aeb10

Please sign in to comment.