{"action":"created","issue":{"url":"https://api.github.com/repos/ReactiveX/RxJava/issues/3459","labels_url":"https://api.github.com/repos/ReactiveX/RxJava/issues/3459/labels{/name}","comments_url":"https://api.github.com/repos/ReactiveX/RxJava/issues/3459/comments","events_url":"https://api.github.com/repos/ReactiveX/RxJava/issues/3459/events","html_url":"https://github.com/ReactiveX/RxJava/issues/3459","id":112074045,"number":3459,"title":"NoSuchFieldException: unsubscribed","user":{"login":"yyfrankyy","id":233918,"avatar_url":"https://avatars.githubusercontent.com/u/233918?v=3","gravatar_id":"","url":"https://api.github.com/users/yyfrankyy","html_url":"https://github.com/yyfrankyy","followers_url":"https://api.github.com/users/yyfrankyy/followers","following_url":"https://api.github.com/users/yyfrankyy/following{/other_user}","gists_url":"https://api.github.com/users/yyfrankyy/gists{/gist_id}","starred_url":"https://api.github.com/users/yyfrankyy/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/yyfrankyy/subscriptions","organizations_url":"https://api.github.com/users/yyfrankyy/orgs","repos_url":"https://api.github.com/users/yyfrankyy/repos","events_url":"https://api.github.com/users/yyfrankyy/events{/privacy}","received_events_url":"https://api.github.com/users/yyfrankyy/received_events","type":"User","site_admin":false},"labels":[{"url":"https://api.github.com/repos/ReactiveX/RxJava/labels/Question","name":"Question","color":"cc317c"}],"state":"open","locked":false,"assignee":null,"milestone":null,"comments":5,"created_at":"2015-10-19T05:23:24Z","updated_at":"2015-10-20T13:03:26Z","closed_at":null,"body":"```\r\njava.lang.NoSuchFieldException: unsubscribed\r\njava.lang.Class.getDeclaredField(Class.java:929)\r\njava.util.concurrent.atomic.AtomicIntegerFieldUpdater$AtomicIntegerFieldUpdaterImpl.<init>(AtomicIntegerFieldUpdater.java:251)\r\njava.util.concurrent.atomic.AtomicIntegerFieldUpdater.newUpdater(AtomicIntegerFieldUpdater.java:49)\r\nrx.subscriptions.BooleanSubscription.<clinit>(SourceFile:32)\r\nrx.subscriptions.Subscriptions.create(SourceFile:75)\r\nrx.subjects.SubjectSubscriptionManager.addUnsubscriber(SourceFile:68)\r\nrx.subjects.SubjectSubscriptionManager.call(SourceFile:58)\r\nrx.subjects.SubjectSubscriptionManager.call(SourceFile:35)\r\nrx.Observable.subscribe(SourceFile:7803)\r\nrx.Observable.subscribe(SourceFile:7531)\r\n```\r\n\r\nHappened randomly, I cannot reproduce this.\r\n\r\nMachine Info\r\n\r\n```\r\nSM-N900;Android 5.0 LRX21V,level 21\r\n```"},"comment":{"url":"https://api.github.com/repos/ReactiveX/RxJava/issues/comments/149561536","html_url":"https://github.com/ReactiveX/RxJava/issues/3459#issuecomment-149561536","issue_url":"https://api.github.com/repos/ReactiveX/RxJava/issues/3459","id":149561536,"user":{"login":"artem-zinnatullin","id":967132,"avatar_url":"https://avatars.githubusercontent.com/u/967132?v=3","gravatar_id":"","url":"https://api.github.com/users/artem-zinnatullin","html_url":"https://github.com/artem-zinnatullin","followers_url":"https://api.github.com/users/artem-zinnatullin/followers","following_url":"https://api.github.com/users/artem-zinnatullin/following{/other_user}","gists_url":"https://api.github.com/users/artem-zinnatullin/gists{/gist_id}","starred_url":"https://api.github.com/users/artem-zinnatullin/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/artem-zinnatullin/subscriptions","organizations_url":"https://api.github.com/users/artem-zinnatullin/orgs","repos_url":"https://api.github.com/users/artem-zinnatullin/repos","events_url":"https://api.github.com/users/artem-zinnatullin/events{/privacy}","received_events_url":"https://api.github.com/users/artem-zinnatullin/received_events","type":"User","site_admin":false},"created_at":"2015-10-20T13:03:26Z","updated_at":"2015-10-20T13:03:26Z","body":"IDK, but I see 2 possible reasons:\r\n\r\n1. Samsung: probably, they've patched the Runtime (they like to change everything in Android) and it tries to minify fields names for less memory usage (though I don't think that they're really doing such things, but, who knows).\r\n2. ProGuard rules problem or ProGuard bug or Android Gradle Plugin bug when you're doing non-clean builds (though it'll break app on other devices too).\r\n\r\n@yyfrankyy can you please wrap the `subscribe()` call into `try-catch` and then collect info about the fields of the `BooleanSubscription` class, it'll help us detect the problem. Also, would be great if you'll check fields of this class \r\n\r\n```java\r\ntry {\r\n  obs.subscribe(...);\r\n} catch (NoSuchFieldException e) {\r\n  // collect info about fields of the BooleanSubscription class\r\n  BooleanSubscription.class.getFields(); // include it into the crash report\r\n}\r\n```\r\n\r\nAlso, recently I've shipped ProGuard rules for RxJava as aar https://github.com/artem-zinnatullin/RxJavaProGuardRules, you can try to use them instead of yours."}}