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

get logs in one go (no listening) #9

Open
1 task
wighawag opened this issue Oct 3, 2017 · 3 comments
Open
1 task

get logs in one go (no listening) #9

wighawag opened this issue Oct 3, 2017 · 3 comments

Comments

@wighawag
Copy link

wighawag commented Oct 3, 2017

ethjs-contract

  • Feature

Description

For my use case I like to call eth_getLogs to gather past events that match the filter parameter in one go (basically I expect to get an array of matching logs)

If this could be added to ethjs as a general method as well as contract event specific, this would be cool

web3 1.0 does this via getPastEvent for contract :

https://web3js.readthedocs.io/en/1.0/web3-eth-contract.html#getpastevents

and getPastLogs for the general case

https://web3js.readthedocs.io/en/1.0/web3-eth.html#getpastlogs

@pointtoken
Copy link

You may be interested in my PR on eth-js ethjs/ethjs#5 and my comment on eth-js query ethjs/ethjs-query#7 that demonstrates how eth_getLogs is kind of broken. I had to use web3 to serialize the event.

@SilentCicero
Copy link
Member

@wighawag we can add something for this, however it would just be using as @pointtoken points out, eth_getLogs.

@wighawag
Copy link
Author

wighawag commented Dec 5, 2017

eth_Logs would be good

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

No branches or pull requests

3 participants