Skip to content

Conversation

TuDo1403
Copy link
Contributor

This pull request introduces several changes to enhance the handling of pending transactions in the Ethereum client. The primary updates include adding support for full transaction objects in pending transaction filters and modifying related APIs to accommodate this new functionality.

Enhancements to Pending Transaction Handling:

  • Added ChainConfig and CurrentHeader methods to the filterBackend interface in accounts/abi/bind/backends/simulated.go.
  • Introduced the fullTx flag and txs field to the filter struct in eth/filters/api.go to support full transaction objects.
  • Modified the NewPendingTransactionFilter and NewPendingTransactions methods in eth/filters/api.go to handle full transaction objects when the fullTx flag is set. [1] [2] [3]
  • Updated the GetFilterChanges method in eth/filters/api.go to return full transactions if the fullTx flag is true. [1] [2]

API and Subscription Updates:

  • Added SubscribeFullPendingTransactions method to the Client in ethclient/gethclient/gethclient.go to subscribe to full pending transactions.
  • Updated the SubscribePendingTxs method in eth/filters/filter_system.go to handle full transaction objects.
  • Modified the handleTxsEvent method in eth/filters/filter_system.go to pass full transaction objects to filters.

Test Enhancements:

  • Added a new test TestPendingTxFilterFullTx in eth/filters/filter_system_test.go to verify the functionality of pending transaction filters with full transactions.
  • Updated existing tests to accommodate changes in pending transaction handling. [1] [2]

These changes collectively improve the flexibility and functionality of pending transaction filters, allowing developers to retrieve complete transaction details when needed.

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.

1 participant