Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

GetBlock prefetchTxs error #4530

Open
wants to merge 1 commit into
base: main
Choose a base branch
from
Open

Conversation

eduardfina
Copy link

Hello,

I found a couple errors while I was trying to use the getBlock function with a FallbackProvider. I'm using a FallbackProvider with 2 JsonRpcProviders, each one have Sepolia defined as a staticNetwork and an Infuria Sepolia url.

  1. Even if I set prefetchTxs = true, the FallbackProvider never gets the transaction objects, #transactions is always an array of transaction hashes.
  2. Using a basic JsonRpcProvider instead of the FallbackProvider I can prefetch the transactions successfully but after it when I call the getTransaction function it always duplicate the second block transaction.

For the first error I could not find an easy solution, but with this commit I solved the second one, it was not properly comparing the object transaction hash with the one we are looking for.

@ricmoo ricmoo added investigate Under investigation and may be a bug. on-deck This Enhancement or Bug is currently being worked on. v6 Issues regarding v6 labels Feb 2, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
investigate Under investigation and may be a bug. on-deck This Enhancement or Bug is currently being worked on. v6 Issues regarding v6
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

3 participants