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

feat: index pre-eip155 transactions #1363

Merged
merged 8 commits into from
Sep 9, 2024

Conversation

eugypalu
Copy link
Contributor

@eugypalu eugypalu commented Sep 4, 2024

Resolves: #1362

Pull Request type

Please check the type of change your PR introduces:

  • Bugfix
  • Feature
  • Code style update (formatting, renaming)
  • Refactoring (no functional changes, no API changes)
  • Build-related changes
  • Documentation content changes
  • Testing

What is the new behavior?

  • Added a check that allows indexing transactions with v < 35 if included in WHITE_LISTED_EIP_155_TRANSACTION_HASHES.
  • Added unit tests.

An error is no longer thrown for each transaction with v < 35, but due to this check in ethers, v must be equal to 27 or 28, otherwise LegacyTransaction.fromTxData will fail.
https://github.com/ethereumjs/ethereumjs-monorepo/blob/fe0d6b4b0fb904f742c86ec47f4488a96f92b7af/packages/tx/src/legacy/tx.ts#L278

Does this introduce a breaking change?

  • Yes
  • No

tcoratger
tcoratger previously approved these changes Sep 6, 2024
@tcoratger
Copy link
Collaborator

lgtm pending @greged93

Copy link
Collaborator

@greged93 greged93 left a comment

Choose a reason for hiding this comment

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

I don't know if we want to only index the white listed ones, that seems like a bit much what do you think @tcoratger? They shouldn't pass the rpc nor the execution layer so I think filtering a third time on the indexer is a lot

@tcoratger
Copy link
Collaborator

@greged93 I was thinking maybe in the past, on some specific transactions if we reindex everything from the beginning but I agree that it's a lot. As you can feel, both options are fine with me.

docker-compose.prod.yaml Outdated Show resolved Hide resolved
indexer/.env.example Outdated Show resolved Hide resolved
indexer/src/types/transaction.ts Outdated Show resolved Hide resolved
indexer/src/types/transaction.ts Outdated Show resolved Hide resolved
@eugypalu eugypalu force-pushed the index_pre_eip155_transactions branch from 97d79f3 to 192a246 Compare September 9, 2024 10:17
@greged93 greged93 added this pull request to the merge queue Sep 9, 2024
Merged via the queue into kkrt-labs:main with commit 281eba0 Sep 9, 2024
8 checks passed
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.

feat: index pre-eip155 transactions
3 participants