{"action":"created","issue":{"url":"https://api.github.com/repos/ethereumjs/testrpc/issues/145","repository_url":"https://api.github.com/repos/ethereumjs/testrpc","labels_url":"https://api.github.com/repos/ethereumjs/testrpc/issues/145/labels{/name}","comments_url":"https://api.github.com/repos/ethereumjs/testrpc/issues/145/comments","events_url":"https://api.github.com/repos/ethereumjs/testrpc/issues/145/events","html_url":"https://github.com/ethereumjs/testrpc/issues/145","id":172995144,"number":145,"title":"eth_getFilterLogs returns an empty array","user":{"login":"mpolci","id":6625359,"avatar_url":"https://avatars.githubusercontent.com/u/6625359?v=3","gravatar_id":"","url":"https://api.github.com/users/mpolci","html_url":"https://github.com/mpolci","followers_url":"https://api.github.com/users/mpolci/followers","following_url":"https://api.github.com/users/mpolci/following{/other_user}","gists_url":"https://api.github.com/users/mpolci/gists{/gist_id}","starred_url":"https://api.github.com/users/mpolci/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/mpolci/subscriptions","organizations_url":"https://api.github.com/users/mpolci/orgs","repos_url":"https://api.github.com/users/mpolci/repos","events_url":"https://api.github.com/users/mpolci/events{/privacy}","received_events_url":"https://api.github.com/users/mpolci/received_events","type":"User","site_admin":false},"labels":[],"state":"closed","locked":false,"assignee":null,"assignees":[],"milestone":null,"comments":3,"created_at":"2016-08-24T16:10:21Z","updated_at":"2016-08-24T17:30:22Z","closed_at":"2016-08-24T16:57:57Z","body":"It seems that this function doesn't return the past logs\r\n\r\nHere a trace from the truffle console:\r\n\r\n```\r\ntruffle(default)> var TXID='0x5a882f8a21443edb76868669ebaf49dc2990e414e8fc0c0d3acbbf409ad5f2ae'\r\n\r\ntruffle(default)> web3.eth.getTransactionReceipt(TXID).logs\r\n[ { logIndex: 0,\r\n    transactionIndex: 0,\r\n    transactionHash: '0x5a882f8a21443edb76868669ebaf49dc2990e414e8fc0c0d3acbbf409ad5f2ae',\r\n    blockHash: '0xe13a35edd48b8a2f5da82aa7e7dbd2b11fb0d1134f7c0252e1b4e33f6d4e0e8c',\r\n    blockNumber: 9,\r\n    address: '0xb6e2b8f8de940170d6389efc584529ecc1966c6b',\r\n    data: '0x000000000000000000000000618fcd1ab22a91911613e622fc03f5ace2bf595d',\r\n    topics: \r\n     [ '0xbb766b38574b4b06dacd1d1436133856d5f955e912882638c674397fa5a21ae1',      \r\n       '0x000000000000000000000000ae0a1daf53184e02911f8a669fda449e20b471a4' ],\r\n    type: 'mined' } ]\r\n```\r\nYou can see the log fingerprint **'0xbb766b38574b4b06dacd1d1436133856d5f955e912882638c674397fa5a21ae1'**, it corresponds to:\r\n```\r\ntruffle(default)> web3.sha3('NewProject(address,address)')\r\n'0xbb766b38574b4b06dacd1d1436133856d5f955e912882638c674397fa5a21ae1'   \r\n\r\ntruffle(default)> FundingHub.abi[8]                                      \r\n{ anonymous: false,\r\n  inputs: \r\n   [ { indexed: true, name: 'owner', type: 'address' },\r\n     { indexed: false, name: 'project', type: 'address' } ],\r\n  name: 'NewProject',\r\n  type: 'event' }\r\n\r\n```\r\n\r\nBut this log is not returned by the `eth_getFilterLogs` rpc call:\r\n```\r\ntruffle(default)> var contract_address = web3.eth.getTransaction(TXID).to\r\n\r\ntruffle(default)> var MyContract = web3.eth.contract(FundingHub.abi)\r\n\r\ntruffle(default)> var myContractInstance = MyContract.at(contract_address)\r\n\r\ntruffle(default)> var filter = myContractInstance.NewProject().get((err,log) => console.log('error:',err,' - log:', log))\r\nundefined\r\nerror: null  - log: []      \r\n```\r\nThe returned log array shouldn't be empty.\r\n"},"comment":{"url":"https://api.github.com/repos/ethereumjs/testrpc/issues/comments/242145889","html_url":"https://github.com/ethereumjs/testrpc/issues/145#issuecomment-242145889","issue_url":"https://api.github.com/repos/ethereumjs/testrpc/issues/145","id":242145889,"user":{"login":"tcoulter","id":92629,"avatar_url":"https://avatars.githubusercontent.com/u/92629?v=3","gravatar_id":"","url":"https://api.github.com/users/tcoulter","html_url":"https://github.com/tcoulter","followers_url":"https://api.github.com/users/tcoulter/followers","following_url":"https://api.github.com/users/tcoulter/following{/other_user}","gists_url":"https://api.github.com/users/tcoulter/gists{/gist_id}","starred_url":"https://api.github.com/users/tcoulter/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/tcoulter/subscriptions","organizations_url":"https://api.github.com/users/tcoulter/orgs","repos_url":"https://api.github.com/users/tcoulter/repos","events_url":"https://api.github.com/users/tcoulter/events{/privacy}","received_events_url":"https://api.github.com/users/tcoulter/received_events","type":"User","site_admin":false},"created_at":"2016-08-24T17:30:22Z","updated_at":"2016-08-24T17:30:22Z","body":"Can you tell me which version of the TestRPC you're using? It should say at the top when you run the testrpc.\r\n\r\nTo make things easier from a bug reporting standpoint, can you write a short snippet of Javascript code that reproduces the error, perhaps using the Truffle default project (or any contracts, whatever's easiest). That would make it much easier for me to reproduce and understand the full context of what's happening. "}}
{"actor":{"display_login":"tcoulter"}}