{"action":"reopened","issue":{"url":"https://api.github.com/repos/web3j/web3j/issues/712","repository_url":"https://api.github.com/repos/web3j/web3j","labels_url":"https://api.github.com/repos/web3j/web3j/issues/712/labels{/name}","comments_url":"https://api.github.com/repos/web3j/web3j/issues/712/comments","events_url":"https://api.github.com/repos/web3j/web3j/issues/712/events","html_url":"https://github.com/web3j/web3j/issues/712","id":360869931,"node_id":"MDU6SXNzdWUzNjA4Njk5MzE=","number":712,"title":"rx.exceptions.OnErrorThrowable$OnNextValue: OnError while emitting onNext value: org.web3j.protocol.core.methods.response.EthLog$LogObject.class","user":{"login":"helderribeirosousa","id":3706268,"node_id":"MDQ6VXNlcjM3MDYyNjg=","avatar_url":"https://avatars1.githubusercontent.com/u/3706268?v=4","gravatar_id":"","url":"https://api.github.com/users/helderribeirosousa","html_url":"https://github.com/helderribeirosousa","followers_url":"https://api.github.com/users/helderribeirosousa/followers","following_url":"https://api.github.com/users/helderribeirosousa/following{/other_user}","gists_url":"https://api.github.com/users/helderribeirosousa/gists{/gist_id}","starred_url":"https://api.github.com/users/helderribeirosousa/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/helderribeirosousa/subscriptions","organizations_url":"https://api.github.com/users/helderribeirosousa/orgs","repos_url":"https://api.github.com/users/helderribeirosousa/repos","events_url":"https://api.github.com/users/helderribeirosousa/events{/privacy}","received_events_url":"https://api.github.com/users/helderribeirosousa/received_events","type":"User","site_admin":false},"labels":[{"id":1096249322,"node_id":"MDU6TGFiZWwxMDk2MjQ5MzIy","url":"https://api.github.com/repos/web3j/web3j/labels/awaiting-user-input","name":"awaiting-user-input","color":"baf99f","default":false}],"state":"open","locked":false,"assignee":null,"assignees":[],"milestone":null,"comments":4,"created_at":"2018-09-17T13:29:12Z","updated_at":"2018-11-19T21:09:38Z","closed_at":null,"author_association":"NONE","body":"Hello,\r\n\r\nWhenever i subscribe to my smart contract's events i get this exception:\r\n```\r\njava.lang.NullPointerException\r\n\tat my.package.smartcontracts.MySmartContract$55.call(MySmartContract.java:355)\r\n\tat my.package.smartcontracts.MySmartContract$55.call(MySmartContract.java:349)\r\n\tat rx.internal.operators.OnSubscribeMap$MapSubscriber.onNext(OnSubscribeMap.java:69)\r\n\tat org.web3j.protocol.core.filters.LogFilter.process(LogFilter.java:39)\r\n\tat org.web3j.protocol.core.filters.Filter.getInitialFilterLogs(Filter.java:106)\r\n\tat org.web3j.protocol.core.filters.Filter.run(Filter.java:61)\r\n\tat org.web3j.protocol.rx.JsonRpc2_0Rx.run(JsonRpc2_0Rx.java:73)\r\n\tat org.web3j.protocol.rx.JsonRpc2_0Rx.lambda$ethLogObservable$2(JsonRpc2_0Rx.java:65)\r\n\tat rx.Observable.unsafeSubscribe(Observable.java:10142)\r\n\tat rx.internal.operators.OnSubscribeMap.call(OnSubscribeMap.java:48)\r\n\tat rx.internal.operators.OnSubscribeMap.call(OnSubscribeMap.java:33)\r\n\tat rx.Observable.unsafeSubscribe(Observable.java:10142)\r\n\tat rx.internal.operators.OnSubscribeDetach.call(OnSubscribeDetach.java:45)\r\n\tat rx.internal.operators.OnSubscribeDetach.call(OnSubscribeDetach.java:29)\r\n\tat rx.Observable.subscribe(Observable.java:10238)\r\n\tat rx.Observable.subscribe(Observable.java:10205)\r\n\tat rx.Observable.subscribe(Observable.java:10045)\r\n\tat my.package.MyDapp.run(MyDapp.java:114)\r\n\tat pt.ipp.estg.mei.MyDapp.main(MyDapp.java:30)\r\nCaused by: rx.exceptions.OnErrorThrowable$OnNextValue: OnError while emitting onNext value: org.web3j.protocol.core.methods.response.EthLog$LogObject.class\r\n\tat rx.exceptions.OnErrorThrowable.addValueAsLastCause(OnErrorThrowable.java:118)\r\n\tat rx.internal.operators.OnSubscribeMap$MapSubscriber.onNext(OnSubscribeMap.java:73)\r\n\t... 16 more\r\n```\r\n\r\nI'm running web3j 3.5.0 (both the library and the command-line utility) and connecting to a Rinkeby (Archive mode) node.\r\nEverything else works flawlessy except operations involving event logging.\r\nI'm chasing the cause of this behaviour for the last 15 days and i've ran out of ideas.\r\n\r\nHere's the code i'm executing:\r\n\r\n```\r\n        String nodeUrl = \"MY_NODE\";\r\n\tOkHttpClient.Builder builder = new OkHttpClient.Builder();\r\n\tLong tos = 300L;\r\n\tbuilder.connectTimeout(tos, TimeUnit.SECONDS);\r\n\tbuilder.readTimeout(tos, TimeUnit.SECONDS);\r\n\tbuilder.writeTimeout(tos, TimeUnit.SECONDS);\r\n\tWeb3j web3j = Web3j.build(new HttpService(nodeUrl,builder.build(),false));\r\n\tSystem.out.println(\"Connected to Ethereum client version: \"+web3j.web3ClientVersion().send().getWeb3ClientVersion());\r\n\r\n\tCredentials credentials = WalletUtils.loadCredentials(\"WALLET_SECRET\",\"/path/to/my/wallet.json\");\r\n\r\n\tString smartContractAddress = \"0x_MY_SMART_CONTRACT_ADDRESS\";\r\n\r\n\tBigInteger LATEST_BLOCK = web3j.ethGetBlockByNumber(DefaultBlockParameterName.LATEST,true).send().getBlock().getNumber();\r\n\tEthFilter filter = new EthFilter(DefaultBlockParameterName.EARLIEST,DefaultBlockParameterName.LATEST,smartContractAddress);\r\n\t\t    \r\n\tSubscription sub = contract.myEventEventObservable(filter).onTerminateDetach().subscribe(x -> {\r\n\t\tSystem.out.println(x.message);\r\n\t}, Throwable::printStackTrace);\r\n```\r\n\r\nIs this by any chance a known issue?\r\n"}}
{"actor":{"display_login":"helderribeirosousa"}}