{"action":"created","issue":{"url":"https://api.github.com/repos/farkam135/GoIV/issues/318","repository_url":"https://api.github.com/repos/farkam135/GoIV","labels_url":"https://api.github.com/repos/farkam135/GoIV/issues/318/labels{/name}","comments_url":"https://api.github.com/repos/farkam135/GoIV/issues/318/comments","events_url":"https://api.github.com/repos/farkam135/GoIV/issues/318/events","html_url":"https://github.com/farkam135/GoIV/issues/318","id":174245913,"number":318,"title":"NPE on master","user":{"login":"Blaisorblade","id":289960,"avatar_url":"https://avatars.githubusercontent.com/u/289960?v=3","gravatar_id":"","url":"https://api.github.com/users/Blaisorblade","html_url":"https://github.com/Blaisorblade","followers_url":"https://api.github.com/users/Blaisorblade/followers","following_url":"https://api.github.com/users/Blaisorblade/following{/other_user}","gists_url":"https://api.github.com/users/Blaisorblade/gists{/gist_id}","starred_url":"https://api.github.com/users/Blaisorblade/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/Blaisorblade/subscriptions","organizations_url":"https://api.github.com/users/Blaisorblade/orgs","repos_url":"https://api.github.com/users/Blaisorblade/repos","events_url":"https://api.github.com/users/Blaisorblade/events{/privacy}","received_events_url":"https://api.github.com/users/Blaisorblade/received_events","type":"User","site_admin":false},"labels":[{"url":"https://api.github.com/repos/farkam135/GoIV/labels/bug","name":"bug","color":"ee0701"}],"state":"open","locked":false,"assignee":null,"assignees":[],"milestone":null,"comments":1,"created_at":"2016-08-31T11:08:26Z","updated_at":"2016-08-31T16:42:23Z","closed_at":null,"body":"Just caught this beast here:\r\n```\r\n08-31 13:06:00.089 3878-3878/com.kamron.pogoiv E/MainActivity: Error thrown in grabScreen() - acquireLatestImage()\r\n08-31 13:06:00.124 3878-3878/com.kamron.pogoiv E/ScreenGrabber: java.lang.NullPointerException: Attempt to invoke virtual method 'android.media.Image android.media.ImageReader.acquireLatestImage()' on a null object reference\r\n                                                                    at com.kamron.pogoiv.ScreenGrabber.grabScreen(ScreenGrabber.java:66)\r\n                                                                    at com.kamron.pogoiv.Pokefly.scanPokemonScreen(Pokefly.java:385)\r\n                                                                    at com.kamron.pogoiv.Pokefly.access$000(Pokefly.java:76)\r\n                                                                    at com.kamron.pogoiv.Pokefly$1$1.run(Pokefly.java:371)\r\n                                                                    at android.os.Handler.handleCallback(Handler.java:739)\r\n                                                                    at android.os.Handler.dispatchMessage(Handler.java:95)\r\n                                                                    at android.os.Looper.loop(Looper.java:148)\r\n                                                                    at android.app.ActivityThread.main(ActivityThread.java:5417)\r\n                                                                    at java.lang.reflect.Method.invoke(Native Method)\r\n                                                                    at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:726)\r\n                                                                    at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:616)\r\n\r\n```\r\n\r\nAround that moment, I stopped the service, swiped away the app, and cleared the cache. Not sure which is relevant, but \"race condition with the timer when stopping the service\" might be it."},"comment":{"url":"https://api.github.com/repos/farkam135/GoIV/issues/comments/243825069","html_url":"https://github.com/farkam135/GoIV/issues/318#issuecomment-243825069","issue_url":"https://api.github.com/repos/farkam135/GoIV/issues/318","id":243825069,"user":{"login":"sarav","id":247061,"avatar_url":"https://avatars.githubusercontent.com/u/247061?v=3","gravatar_id":"","url":"https://api.github.com/users/sarav","html_url":"https://github.com/sarav","followers_url":"https://api.github.com/users/sarav/followers","following_url":"https://api.github.com/users/sarav/following{/other_user}","gists_url":"https://api.github.com/users/sarav/gists{/gist_id}","starred_url":"https://api.github.com/users/sarav/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/sarav/subscriptions","organizations_url":"https://api.github.com/users/sarav/orgs","repos_url":"https://api.github.com/users/sarav/repos","events_url":"https://api.github.com/users/sarav/events{/privacy}","received_events_url":"https://api.github.com/users/sarav/received_events","type":"User","site_admin":false},"created_at":"2016-08-31T16:42:22Z","updated_at":"2016-08-31T16:42:22Z","body":"Hmmm... that's why I do the timer.cancel() first in the onDestroy() for Pokefly. So, it shouldn't happen. Unless timer.cancel() doesn't wait for a currently running timer to finish before returning."}}
{"actor":{"display_login":"sarav"}}