ketanpatel25 / GCM-Demo

Google Cloud Messaging for Android (GCM) is a service that helps developers send data from servers to their Android applications on Android devices.
11 stars 13 forks source link

Bug #1

Open smilehari opened 12 years ago

smilehari commented 12 years ago

java.lang.RuntimeException: Unable to start activity ComponentInfo{com.ketan.demo/com.ketan.demo.DemoActivity}: java.lang.UnsupportedOperationException: Device does not have package com.google.android.gsf

ketanpatel25 commented 12 years ago

hii.....where is bug. can you explain more

smilehari commented 12 years ago

07-02 18:21:58.703: E/AndroidRuntime(1186): FATAL EXCEPTION: main 07-02 18:21:58.703: E/AndroidRuntime(1186): java.lang.RuntimeException: Unable to start activity ComponentInfo{com.ketan.demo/com.ketan.demo.DemoActivity}: java.lang.UnsupportedOperationException: Device does not have package com.google.android.gsf 07-02 18:21:58.703: E/AndroidRuntime(1186): at android.app.ActivityThread.performLaunchActivity(ActivityThread.java:1647) 07-02 18:21:58.703: E/AndroidRuntime(1186): at android.app.ActivityThread.handleLaunchActivity(ActivityThread.java:1663) 07-02 18:21:58.703: E/AndroidRuntime(1186): at android.app.ActivityThread.access$1500(ActivityThread.java:117) 07-02 18:21:58.703: E/AndroidRuntime(1186): at android.app.ActivityThread$H.handleMessage(ActivityThread.java:931) 07-02 18:21:58.703: E/AndroidRuntime(1186): at android.os.Handler.dispatchMessage(Handler.java:99) 07-02 18:21:58.703: E/AndroidRuntime(1186): at android.os.Looper.loop(Looper.java:123) 07-02 18:21:58.703: E/AndroidRuntime(1186): at android.app.ActivityThread.main(ActivityThread.java:3683) 07-02 18:21:58.703: E/AndroidRuntime(1186): at java.lang.reflect.Method.invokeNative(Native Method) 07-02 18:21:58.703: E/AndroidRuntime(1186): at java.lang.reflect.Method.invoke(Method.java:507) 07-02 18:21:58.703: E/AndroidRuntime(1186): at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:839) 07-02 18:21:58.703: E/AndroidRuntime(1186): at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:597) 07-02 18:21:58.703: E/AndroidRuntime(1186): at dalvik.system.NativeStart.main(Native Method) 07-02 18:21:58.703: E/AndroidRuntime(1186): Caused by: java.lang.UnsupportedOperationException: Device does not have package com.google.android.gsf 07-02 18:21:58.703: E/AndroidRuntime(1186): at com.google.android.gcm.GCMRegistrar.checkDevice(GCMRegistrar.java:83) 07-02 18:21:58.703: E/AndroidRuntime(1186): at com.ketan.demo.DemoActivity.onCreate(DemoActivity.java:51) 07-02 18:21:58.703: E/AndroidRuntime(1186): at android.app.Instrumentation.callActivityOnCreate(Instrumentation.java:1047) 07-02 18:21:58.703: E/AndroidRuntime(1186): at android.app.ActivityThread.performLaunchActivity(ActivityThread.java:1611) 07-02 18:21:58.703: E/AndroidRuntime(1186): ... 11 more

smilehari commented 12 years ago

GCMRegistrar.checkDevice(this); creates the problem

ketanpatel25 commented 12 years ago

ok you can try GCM-Demo / gcm / samples / gcm-demo-client project this one is run or some problem

ketanpatel25 commented 12 years ago

gcm.jar file add or not add

smilehari commented 12 years ago

the jar file is available in the lib

ketanpatel25 commented 12 years ago

hii... you can try this one project this project working. i will test in nexus one Devies or HTC,nexus S working

me be you server sied code som errar

ketanpatel25 commented 12 years ago

you see log in 'regId' get or not ?

smilehari commented 12 years ago

Hi Im texting in the emulator.. Im updating all the sdk available and then will retry yesterday i jus downloaded the GCM sdk.. The problem is with GCMRegistrar.checkDevice(this); if i comment this line the app works.. Can you guide me to some proper tutorial to develop the server side coding for push notifications.. I ve never done server side coding before.. If you can give me some good reference i will ask ma colleagues(.net developers) to develop the server side code for me..

ketanpatel25 commented 12 years ago

ok... this project working in device not work in emulator emulator not supporting, emulator RegID not generate

ketanpatel25 commented 12 years ago

ok... this project working in device not work in emulator emulator not supporting, emulator not generate RegID

ketanpatel25 commented 12 years ago

ok... this project working in device not work in emulator emulator not supporting, emulator not generate RegID

smilehari commented 12 years ago

okie thanks a lot for ur help ketan will check in device later

Can you guide me to some proper tutorial to develop the server side coding for push notifications.. I ve never done server side coding before.. If you can give me some good reference or sample code i will ask ma colleagues(.net developers) to develop the server side code..

smilehari commented 12 years ago

okie thanks a lot for ur help ketan will check in device later

Can you guide me to some proper tutorial to develop the server side coding for push notifications.. I ve never done server side coding before.. If you can give me some good reference or sample code i will ask ma colleagues(.net developers) to develop the server side code..

ketanpatel25 commented 12 years ago

thanks....

as regarding you server side problem. i think below link in project code there you try it GCM-Demo / gcm / samples / gcm-demo-server