Skip to content
This repository has been archived by the owner on Apr 4, 2024. It is now read-only.

eth_getLogs returns empty when specify blockHash and not specify address/topics #861

Closed
yihuang opened this issue Dec 28, 2021 · 1 comment

Comments

@yihuang
Copy link
Contributor

yihuang commented Dec 28, 2021

System info: [Include Ethermint commit, operating system name, and other relevant details]

Steps to reproduce:

$ curl -H "Content-Type: application/json" -X POST --data '{
    "id": 1,
    "jsonrpc": "2.0",
    "method": "eth_getLogs",
    "params": [{"blockHash": "0xb2cb8283f35763ad12389019a49c9a9c4a1dfa7a8b56baeab82fcd8149a8eab6"}]}' https://evm-cronos.crypto.org
{"jsonrpc":"2.0","id":1,"result":[]}
$ curl -H "Content-Type: application/json" -X POST --data '{
    "id": 1,
    "jsonrpc": "2.0",
    "method": "eth_getLogs",
    "params": [{"blockHash": "0xb2cb8283f35763ad12389019a49c9a9c4a1dfa7a8b56baeab82fcd8149a8eab6", "address": "0xed94536A27922e2BD0eE661abF5fB030228d9D72"}]}' https://evm-cronos.crypto.org
{"jsonrpc":"2.0","id":1,"result":[{"address":"0xed94536a27922e2bd0ee661abf5fb030228d9d72","topics":["0xe2403640ba68fed3a2f88b7557551d1993f84b99bb10ff833f0cf8db0c5e0486","0x0000000000000000000000001eb0fa9c3594177da9d47b06900f8c4178904abc"],"data":"0x0000000000000000000000000000000000000000000000004f558ed0d4b9904b","blockNumber":"0xbae4d","transactionHash":"0xcb9ecc77515fec252642e2dce912e35a4d4c24ef8f0bf9c67e6a84b7713b5479","transactionIndex":"0xa","blockHash":"0xb2cb8283f35763ad12389019a49c9a9c4a1dfa7a8b56baeab82fcd8149a8eab6","logIndex":"0x70","removed":false}]}

Expected behavior: eth_getLogs should return logs when specify blockHash

Actual behavior: return empty

Additional info:

@yihuang
Copy link
Contributor Author

yihuang commented Jan 13, 2022

fixed by #860

@yihuang yihuang closed this as completed Jan 13, 2022
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant