Transaction intermittently reverting without any apparent reason #3368
Unanswered
brunoguerios
asked this question in
Question
Replies: 1 comment 1 reply
-
This would be an RPC issue. I would suggest trying with an alternative RPC provider. |
Beta Was this translation helpful? Give feedback.
1 reply
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
Check existing issues
Viem Version
2.23.3
Current Behavior
Transaction intermittently reverting without any apparent reason.
I'm sure that inputs are correct and balances/approvals are enough, but this specific transaction will randomly fail during tests.
Running simulateContract with the exact same inputs and blockNumber returns the correct result instead of reverting.
Expected Behavior
I expect that a transaction that is supposed to succeed indeed succeeds every time.
I expect that simulateContract results are exactly the same as the actual transaction.
Steps To Reproduce
Follow readme instruction on the repo provided (which is basically setup and run it).
Note: I created a repo instead of using stackblitz because couldn't find a way to use
testClient
actions on stackblitz (e.g. setStorage).Link to Minimal Reproducible Example
https://github.com/brunoguerios/b-sdk-viem-issue
Anything else?
The code is set to perform the same transaction 100 times in a row. Since it's random, it should eventually fail, but all might succeed. Please try again if that's the case.
Beta Was this translation helpful? Give feedback.
All reactions