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

log filter with address option is not returning log #629

Closed
frozeman opened this issue Apr 2, 2015 · 6 comments
Closed

log filter with address option is not returning log #629

frozeman opened this issue Apr 2, 2015 · 6 comments
Labels
Milestone

Comments

@frozeman
Copy link
Contributor

frozeman commented Apr 2, 2015

When leaving the address option it retrurns the log.

e.g. creating a filter:

{"jsonrpc":"2.0","method":"eth_newFilter","params":[{"topics":[],"fromBlock":"0x0","toBlock":"latest"}],"id":2}

And then calling eth_getFilterLogs

{"jsonrpc":"2.0","method":"eth_getFilterLogs","params":["0x19"],"id":3}

Returns one log:

{
    "id": 3,
    "jsonrpc": "2.0",
    "result": [
        {
            "address": "0x6295ee1b4f6dd65047762f924ecd367c17eabf8f",
            "topics": [
                "0x59ebeb90bc63057b6515673c3ecf9438e5058bca0f92585014eced636878c9a5"
            ],
            "data": "0x",
            "blockNumber": "0x3",
            "hash": null,
            "logIndex": null,
            "blockHash": null,
            "transactionHash": null,
            "transactionIndex": null
        }
    ]
}

But adding the address filter option like:

{"jsonrpc":"2.0","method":"eth_newFilter","params":[{"topics":[],"address":"0x6295ee1b4f6dd65047762f924ecd367c17eabf8f","fromBlock":"0x0","toBlock":"latest"}],"id":4}

And then getting the logs again using:

{"jsonrpc":"2.0","method":"eth_getFilterLogs","params":["0x1a"],"id":3}

returns no log:

{
    "id": 5,
    "jsonrpc": "2.0",
    "result": []
}
@frozeman frozeman added the RPC label Apr 2, 2015
@frozeman
Copy link
Contributor Author

frozeman commented Apr 2, 2015

Looking into the node console i get:

2015/04/02 17:21:12 [CHAIN] err: filter get logs  Block's parent unknown 0000000000000000000000000000000000000000000000000000000000000000

But only when i use the first filter, where i get a log..

@tgerring tgerring mentioned this issue Apr 7, 2015
@frozeman frozeman added this to the Frontier milestone Apr 8, 2015
@frozeman frozeman mentioned this issue Apr 8, 2015
3 tasks
obscuren added a commit that referenced this issue Apr 8, 2015
Logs are now recorded per transactions instead of tossing them out after
each transaction. This should also fix an issue with
`eth_getFilterLogs` (#629) Also now implemented are the `transactionHash,
blockHash, transactionIndex, logIndex` on logs. Closes #654.
@obscuren
Copy link
Contributor

@frozeman please confirm that this issue is still pending

@frozeman
Copy link
Contributor Author

it is

@obscuren
Copy link
Contributor

Give me a test case please. Give me the steps, code, etc.

@frozeman
Copy link
Contributor Author

in my first comment there is one :)
curl calls and results.

You can additionally run the rpc-tests by following the readme here: https://github.com/ethereum/rpc-tests

Then just run only the filter logs using:

$ mocha test/1_testConnection.js test/eth_getFilterLogs.js

We can also go together over this in a skype call

@frozeman
Copy link
Contributor Author

var filter = web3.eth.filter({fromBlock: 0, toBlock: 'latest'});
JSON.stringify(filter.get(),null,2);

nonsense pushed a commit that referenced this issue May 29, 2018
tony-ricciardi pushed a commit to tony-ricciardi/go-ethereum that referenced this issue Jan 20, 2022
…1269)

This changes them to use medium+ instead of the default medium, which should help with flaky tests where the machine is overloaded and which don't happen on dev machines since they're more powerful (e.g. ethereum#629). If the failures keep happening, we can either (a) increase further to large, (b) increase the waits in the tests, (c) make those specific tests not run using `t.Parallel()`.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

3 participants