fix(txm): not process the same block multiple times - #577
Merged
Conversation
This was referenced Apr 1, 2025
Merged
Merged
Merged
Merged
Merged
Contributor
Author
GabrielMartinezRodriguez
marked this pull request as ready for review
April 1, 2025 09:29
11 tasks
aodhgan
reviewed
Apr 1, 2025
GabrielMartinezRodriguez
force-pushed
the
gabriel/fix-block-undefined
branch
from
April 3, 2025 11:18
0cfc909 to
357ffc8
Compare
GabrielMartinezRodriguez
force-pushed
the
gabriel/fix-repeated-blocks
branch
from
April 3, 2025 11:18
295778e to
2493832
Compare
GabrielMartinezRodriguez
force-pushed
the
gabriel/fix-block-undefined
branch
from
April 3, 2025 11:37
357ffc8 to
7776719
Compare
GabrielMartinezRodriguez
force-pushed
the
gabriel/fix-repeated-blocks
branch
from
April 3, 2025 11:37
2493832 to
1b2d737
Compare
GabrielMartinezRodriguez
force-pushed
the
gabriel/fix-block-undefined
branch
from
April 3, 2025 13:08
7776719 to
e914fb7
Compare
GabrielMartinezRodriguez
force-pushed
the
gabriel/fix-repeated-blocks
branch
from
April 3, 2025 13:08
1b2d737 to
38e19fa
Compare
11 tasks
aodhgan
approved these changes
Apr 3, 2025
GabrielMartinezRodriguez
force-pushed
the
gabriel/fix-block-undefined
branch
from
April 10, 2025 08:38
cd47176 to
0f7df60
Compare
GabrielMartinezRodriguez
force-pushed
the
gabriel/fix-repeated-blocks
branch
from
April 10, 2025 08:38
3077915 to
b2d994a
Compare
GabrielMartinezRodriguez
force-pushed
the
gabriel/fix-block-undefined
branch
from
April 10, 2025 08:51
0f7df60 to
dfdc6c0
Compare
GabrielMartinezRodriguez
force-pushed
the
gabriel/fix-repeated-blocks
branch
from
April 10, 2025 08:51
b2d994a to
c2be507
Compare
GabrielMartinezRodriguez
force-pushed
the
gabriel/fix-block-undefined
branch
from
April 10, 2025 09:13
dfdc6c0 to
0f799ad
Compare
GabrielMartinezRodriguez
force-pushed
the
gabriel/fix-repeated-blocks
branch
from
April 10, 2025 09:13
c2be507 to
2e048f8
Compare
GabrielMartinezRodriguez
force-pushed
the
gabriel/fix-block-undefined
branch
from
April 10, 2025 09:56
0f799ad to
f362034
Compare
GabrielMartinezRodriguez
force-pushed
the
gabriel/fix-repeated-blocks
branch
from
April 10, 2025 09:56
2e048f8 to
f814d5b
Compare
GabrielMartinezRodriguez
force-pushed
the
gabriel/fix-block-undefined
branch
from
April 10, 2025 11:51
f362034 to
d817440
Compare
GabrielMartinezRodriguez
force-pushed
the
gabriel/fix-repeated-blocks
branch
from
April 10, 2025 11:51
f814d5b to
b114aa3
Compare
GabrielMartinezRodriguez
force-pushed
the
gabriel/fix-block-undefined
branch
from
April 10, 2025 11:56
d817440 to
b121ba5
Compare
GabrielMartinezRodriguez
force-pushed
the
gabriel/fix-repeated-blocks
branch
from
April 10, 2025 11:56
b114aa3 to
4f0700c
Compare
11 tasks
GabrielMartinezRodriguez
force-pushed
the
gabriel/fix-block-undefined
branch
from
April 13, 2025 21:30
b121ba5 to
650af43
Compare
GabrielMartinezRodriguez
force-pushed
the
gabriel/fix-repeated-blocks
branch
from
April 13, 2025 21:30
4f0700c to
73c7bf7
Compare
GabrielMartinezRodriguez
force-pushed
the
gabriel/fix-block-undefined
branch
from
April 13, 2025 21:36
650af43 to
641e505
Compare
GabrielMartinezRodriguez
force-pushed
the
gabriel/fix-repeated-blocks
branch
from
April 13, 2025 21:36
73c7bf7 to
859e0a0
Compare
GabrielMartinezRodriguez
force-pushed
the
gabriel/fix-block-undefined
branch
from
April 13, 2025 21:38
641e505 to
b61eeba
Compare
GabrielMartinezRodriguez
force-pushed
the
gabriel/fix-repeated-blocks
branch
from
April 13, 2025 21:38
859e0a0 to
d06f52c
Compare
GabrielMartinezRodriguez
force-pushed
the
gabriel/fix-block-undefined
branch
from
April 13, 2025 21:39
b61eeba to
db10c52
Compare
GabrielMartinezRodriguez
force-pushed
the
gabriel/fix-repeated-blocks
branch
from
April 13, 2025 21:39
d06f52c to
63f5395
Compare
GabrielMartinezRodriguez
force-pushed
the
gabriel/fix-repeated-blocks
branch
from
April 13, 2025 21:40
63f5395 to
f46fab6
Compare
This was referenced Apr 21, 2025
Merged
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.

Description
While monitoring the service, I noticed that when we experience network issues, the viem
onErrorcallback is triggered multiple times per block, not just once per network error. This was causing theresetBlockSubscriptionfunction to be called multiple times, leading to race conditions such as processing the same block more than onceI removed the
onErrorcallback to address this since it's unreliable. Additionally, I implemented a mechanism to ensure that already processed blocks are never processed again.Toggle Checklist
Checklist
Basics
norswap/build-system-caching).Reminder: PR review guidelines
Correctness
testnet, mainnet, standalone wallet, ...).
< INDICATE BROWSER, DEMO APP & OTHER ENV DETAILS USED FOR TESTING HERE >
< INDICATE TESTED SCENARIOS (USER INTERFACE INTERACTION, CODE FLOWS) HERE >
and have updated the code & comments accordingly.
Architecture & Documentation
(2) commenting these boundaries correctly, (3) adding inline comments for context when needed.
comments.
in a Markdown document.
packages/coreandpackages/react), see here for more info.