Skip to content

Comments

fix: use toBlock sources in preload#379

Merged
Sekhmet merged 1 commit intomasterfrom
sekhmet/preload-sources
Oct 13, 2025
Merged

fix: use toBlock sources in preload#379
Sekhmet merged 1 commit intomasterfrom
sekhmet/preload-sources

Conversation

@Sekhmet
Copy link
Member

@Sekhmet Sekhmet commented Oct 13, 2025

When indexing multiple sources we start from lowest block possible. For example, if we index ContractA from block 1000 and ContractB from block 2500, and preload step would be 1000 blocks we would preload as such:

  1. (1000, 2000) with sources [ContractA]
  2. (2000, 3000) with sources [CotnractA] - because we look at sources from 2000.

With this fix we will actually use end-blocks sources so this won't happen.

When indexing multiple sources we start from lowest block possible.
For example, if we index ContractA from block 1000 and ContractB from
block 2500, and preload step would be 1000 blocks we would preload as
such:
1. (1000, 2000) with sources [ContractA]
2. (2000, 3000) with sources [CotnractA] - because we look at sources
   from 2000.

With this fix we will actually use end-blocks sources so this won't
happen.
@Sekhmet Sekhmet requested a review from bonustrack October 13, 2025 09:52
Copy link
Member

@bonustrack bonustrack left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

utACK

@Sekhmet Sekhmet merged commit f493ab5 into master Oct 13, 2025
1 check passed
@Sekhmet Sekhmet deleted the sekhmet/preload-sources branch October 13, 2025 16:11
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants