Skip to content

Commit

Permalink
common: warn, don't throw, when subgraph is ahead of chain head
Browse files Browse the repository at this point in the history
  • Loading branch information
tilacog committed Sep 29, 2023
1 parent c725e4b commit 12e9c2f
Showing 1 changed file with 1 addition and 2 deletions.
3 changes: 1 addition & 2 deletions packages/indexer-common/src/subgraphs.ts
Original file line number Diff line number Diff line change
Expand Up @@ -468,8 +468,7 @@ export class SubgraphFreshnessChecker {
if (blockDistance < 0) {
// Invariant violated: Subgraph can't be ahead of network latest block
const errorMsg = `${this.subgraphName}'s latest indexed block (${latestIndexedBlock}) is higher than Network's latest block (${latestNetworkBlock})`
console.error(errorMsg, logInfo)
throw new Error(errorMsg)
console.warn(errorMsg, logInfo)
}

if (blockDistance > this.threshold) {
Expand Down

0 comments on commit 12e9c2f

Please sign in to comment.