IllegalStateException: No receivers for action com.google.android.c2dm.intent.REGISTRATION

2,102 views
Skip to first unread message

Jonathan Caryl

unread,
Jul 30, 2013, 8:18:01 AM7/30/13
to andro...@googlegroups.com
We're seeing *occasional* crash reports that look something like so:

java.lang.RuntimeException: Unable to create application com.ourcompany.android.OurApp: java.lang.IllegalStateException: No receivers for action com.google.android.c2dm.intent.REGISTRATION
at android.app.ActivityThread.handleBindApplication(ActivityThread.java:4394)
at android.app.ActivityThread.access$1300(ActivityThread.java:141)
at android.app.ActivityThread$H.handleMessage(ActivityThread.java:1294)
at android.os.Handler.dispatchMessage(Handler.java:99)
at android.os.Looper.loop(Looper.java:137)
at android.app.ActivityThread.main(ActivityThread.java:5041)
at java.lang.reflect.Method.invokeNative(Native Method)
at java.lang.reflect.Method.invoke(Method.java:511)
at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:793)
at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:560)
at dalvik.system.NativeStart.main(Native Method)
Caused by: java.lang.IllegalStateException: No receivers for action com.google.android.c2dm.intent.REGISTRATION
at com.google.android.gcm.GCMRegistrar.checkReceiver(GCMRegistrar.java:184)
at com.google.android.gcm.GCMRegistrar.checkManifest(GCMRegistrar.java:169)
at com.ourcompany.android.push.gcm.GCMHost.initializeService(GCMHost.java:26)
at com.ourcompany.android.push.PushService.initializePushMessaging(PushService.java:36)
at com.ourcompany.android.OurApp.onCreate(OurApp.java:74)
at android.app.Instrumentation.callApplicationOnCreate(Instrumentation.java:1000)
at android.app.ActivityThread.handleBindApplication(ActivityThread.java:4391)
... 10 more


All I can find on the interwebs for this IllegalStateException is places where things have been mis-configured in the AndroidManifest.xml, and hence they never work. Our app is working > 99% of the time, push notifications are in general working, which makes this IllegalStateException somewhat puzzling. I'm thinking the best work-around will be to just catch the Exception and silently carry on, but if anybody knows how to actually *fix* it, that would obviously be better.

The crashes have happened on DROID RAZR and Nexus 7 devices amongst others, so it's not a problem confined to some obscure no-name device.

Does anybody have any insight?



Jonathan

Prabhunath Yadav

unread,
Jul 30, 2013, 8:38:26 AM7/30/13
to andro...@googlegroups.com
Hi, I have also got this problem.
     This can be resolve by change ACTION string in manifest.xml file
Just change own package of receiver where receiver is . for example  if you in com.demo package then make in manifest
<receiver name="com.demo......" />





Jonathan

--
You received this message because you are subscribed to the Google Groups "android-gcm" group.
To unsubscribe from this group and stop receiving emails from it, send an email to android-gcm...@googlegroups.com.
To post to this group, send email to andro...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/android-gcm/f2cbfefd-35d6-4b36-b580-1d5b10243bc8%40googlegroups.com.
For more options, visit https://groups.google.com/groups/opt_out.
 
 



--
----
Thanks and Regards
Prabhunath Yadav
Mobile Apps Developer
Mobile: +91 8010149069

S a k s h a y    W e b    T e c h n o l o g i e s    P v t    L t d
--------------------------------------------------------------------------------------
B-98, Ground Floor , Sector-63,
Noida - 201301
Phone: +91-
120-6517460
---------------------------------------------------------------------------------------------------------
www.sakshay.in   www.drupalindia.com   www.ssecom.in    www.joomla.in

Jonathan Caryl

unread,
Jul 30, 2013, 8:55:42 AM7/30/13
to andro...@googlegroups.com
Thanks, but that's not the problem. If there was a problem with the configuration in the AndroidManifest.xml then it'd not work *at all*. It is working completely fine for 10000s of users, we're just seeing a few rare crashes. 

Ted Ekeroth

unread,
Apr 15, 2014, 2:40:45 AM4/15/14
to andro...@googlegroups.com
Jonathan - did you ever resolve this issue? I have the same problem...

Regards,
Ted

Jonathan Caryl

unread,
Apr 24, 2014, 2:48:07 AM4/24/14
to andro...@googlegroups.com
We never got to the root cause of the problem, we're just catching the Exceptions. It's a rare occurrence, so not that big a deal. It would be nice to know the real solution, though!

Ted Ekeroth

unread,
May 3, 2014, 8:48:12 AM5/3/14
to andro...@googlegroups.com
Ok, I see. Too bad. I am cathing it too, but it happens a bit more frequent for me, I think. 

Thanks for replying.

Regards
ted

Singh Ankit

unread,
Nov 6, 2014, 1:47:17 AM11/6/14
to andro...@googlegroups.com
Hi,

  I am also facing same problem and unable to resolve it. Can anyone got solution of it.

Costin Manolache

unread,
Nov 11, 2014, 1:53:46 PM11/11/14
to andro...@googlegroups.com
I would suggest using the Play Services API - com.google.android.gms.gcm - instead of the long-deprecated library 
(com.google.android.gcm) you are using. 
The main difference is that registration is a blocking call and no longer require the receiver. It is also using the registration code in 
Play Services, instead of the old code in platform.


Costin

On Wed, Nov 5, 2014 at 10:47 PM, Singh Ankit <andro....@gmail.com> wrote:
Hi,

  I am also facing same problem and unable to resolve it. Can anyone got solution of it.

--
You received this message because you are subscribed to the Google Groups "android-gcm" group.
To unsubscribe from this group and stop receiving emails from it, send an email to android-gcm...@googlegroups.com.
To post to this group, send email to andro...@googlegroups.com.
Reply all
Reply to author
Forward
0 new messages