web3.js
web3.js copied to clipboard
Support BatchRequest for getPastEvents
Is there an existing issue for this? No.
- [X] I have searched the existing issues
Feature Request
It would be great if BatchRequest supports getPastEvents ( eth_getLogs ), so that it would reduce calls for fetching events which would fulfill getting event logs from public nodes with rate limits.
Use Cases
Many public nodes have rate limits as well as limits for block length for a single eth_getLogs call ( 5K block for BSC https://docs.bnbchain.org/docs/rpc ). Without batch requests, it would take a lot of time to fetch historic contract logs due to those limits applied ).
Implementation Ideas
Support web3.eth.Contract().getPastEvents to call for eth_getLogs, I don't think 4.x branch doesn't support this feature as well ( Although it is technically possible & already available for ethers.js )
Feature Examples/References
No response
Are you willing to implement this feature? No. ( This would create incompatibility for type definitions for either BatchRequest or getPastEvents )
- [ ] Yes
@ayanamidev Thanks for this issue, Currently we are focused on 4.x alpha release and our team can look this for beta.
This issue has been automatically marked as stale because it has not had recent activity. It will be closed in 7 days if no further activity occurs. Thank you for your contributions. If you believe this was a mistake, please comment.
This issue has been automatically marked as stale because it has not had recent activity. It will be closed in 7 days if no further activity occurs. Thank you for your contributions. If you believe this was a mistake, please comment.
This issue has been automatically marked as stale because it has not had recent activity. It will be closed in 7 days if no further activity occurs. Thank you for your contributions. If you believe this was a mistake, please comment.