Home screen widget crashes after app version upgrade.

Put your problem here if it does not fit any of the other categories.

Home screen widget crashes after app version upgrade.

Postby royiby » Sun Apr 10, 2011 6:38 am

Hello,
i created a home screen widget that uses a service and a broadcast receiver.

it works great but when the app is upgraded it crashes and i don't really know why.

the log shows something like this:
Code: Select all

04-10 08:36:09.677: DEBUG/dalvikvm(1429): GC_CONCURRENT freed 609K, 55% free 3108K/6855K, external 1625K/2137K, paused 6ms+4ms
04-10 08:36:10.797: INFO/ASK(283): onUnbindInput
04-10 08:36:12.257: INFO/ActivityManager(209): Starting: Intent { dat=file:///sdcard/dropbox/drippler/Drippler.apk cmp=com.android.packageinstaller/.InstallAppProgress (has extras) } from pid 1333
04-10 08:36:12.317: WARN/InstallAppProgress(1333): Replacing package:com.drippler
04-10 08:36:12.417: DEBUG/com.dropbox.android.util.FileWatcher(1128): Drippler.apk Open for /sdcard/dropbox/drippler/
04-10 08:36:12.447: DEBUG/dalvikvm(283): GC_EXPLICIT freed 5K, 50% free 2901K/5767K, external 1845K/2357K, paused 82ms
04-10 08:36:12.487: DEBUG/com.dropbox.android.util.FileWatcher(1128): Drippler.apk Close NoWrite for /sdcard/dropbox/drippler/
04-10 08:36:12.487: INFO/com.dropbox.android.util.FileWatcher(1128): File not modified: /sdcard/dropbox/drippler/Drippler.apk
04-10 08:36:12.527: DEBUG/dalvikvm(1343): GC_EXPLICIT freed 13K, 53% free 2545K/5379K, external 1625K/2137K, paused 40ms
04-10 08:36:12.527: WARN/ActivityManager(209): No content provider found for:
04-10 08:36:12.537: DEBUG/com.dropbox.android.util.FileWatcher(1128): Drippler.apk Open for /sdcard/dropbox/drippler/
04-10 08:36:12.597: INFO/ActivityManager(209): Displayed com.android.packageinstaller/.InstallAppProgress: +312ms
04-10 08:36:12.967: DEBUG/com.dropbox.android.util.FileWatcher(1128): Drippler.apk Close NoWrite for /sdcard/dropbox/drippler/
04-10 08:36:12.967: INFO/com.dropbox.android.util.FileWatcher(1128): File not modified: /sdcard/dropbox/drippler/Drippler.apk
04-10 08:36:12.967: WARN/ActivityManager(209): No content provider found for:
04-10 08:36:12.987: DEBUG/PackageParser(209): Scanning package: /data/app/vmdl600101179.tmp
04-10 08:36:13.237: DEBUG/dalvikvm(209): GC_CONCURRENT freed 1088K, 46% free 6120K/11271K, external 1685K/2197K, paused 3ms+6ms
04-10 08:36:13.307: INFO/PackageManager(209): Removing non-system package:com.drippler
04-10 08:36:13.307: INFO/Process(209): Sending signal. PID: 1429 SIG: 9
04-10 08:36:13.307: INFO/ActivityManager(209): Force stopping package com.drippler uid=10068
04-10 08:36:13.307: WARN/ActivityManager(209): Scheduling restart of crashed service com.drippler/.DripWidget$UpdateService in 5000ms
04-10 08:36:13.307: INFO/ActivityManager(209):   Force stopping service ServiceRecord{40a14980 com.drippler/.DripWidget$UpdateService}
04-10 08:36:13.447: DEBUG/PackageManager(209): Scanning package com.drippler
04-10 08:36:13.447: INFO/PackageManager(209): Package com.drippler codePath changed from /data/app/com.drippler-2.apk to /data/app/com.drippler-1.apk; Retaining data and using new
04-10 08:36:13.447: INFO/PackageManager(209): Unpacking native libraries for /data/app/com.drippler-1.apk
04-10 08:36:13.467: DEBUG/installd(184): DexInv: --- BEGIN '/data/app/com.drippler-1.apk' ---
04-10 08:36:13.717: DEBUG/dalvikvm(1470): creating instr width table
04-10 08:36:13.857: DEBUG/dalvikvm(1470): DexOpt: 'Lorg/json/JSONTokener;' has an earlier definition; blocking out
04-10 08:36:13.857: DEBUG/dalvikvm(1470): DexOpt: 'Lorg/json/JSONArray;' has an earlier definition; blocking out
04-10 08:36:13.857: DEBUG/dalvikvm(1470): DexOpt: 'Lorg/json/JSONException;' has an earlier definition; blocking out
04-10 08:36:13.857: DEBUG/dalvikvm(1470): DexOpt: 'Lorg/json/JSONObject$1;' has an earlier definition; blocking out
04-10 08:36:13.857: DEBUG/dalvikvm(1470): DexOpt: 'Lorg/json/JSONObject;' has an earlier definition; blocking out
04-10 08:36:13.857: DEBUG/dalvikvm(1470): DexOpt: 'Lorg/json/JSONStringer;' has an earlier definition; blocking out
04-10 08:36:13.897: INFO/dalvikvm(1470): DexOpt: not resolving ambiguous class 'Lorg/json/JSONObject;'
04-10 08:36:13.907: INFO/dalvikvm(1470): DexOpt: not resolving ambiguous class 'Lorg/json/JSONTokener;'
04-10 08:36:13.907: INFO/dalvikvm(1470): DexOpt: not resolving ambiguous class 'Lorg/json/JSONObject;'
04-10 08:36:13.917: INFO/dalvikvm(1470): DexOpt: not resolving ambiguous class 'Lorg/json/JSONObject;'
04-10 08:36:13.917: INFO/dalvikvm(1470): DexOpt: not resolving ambiguous class 'Lorg/json/JSONObject;'
04-10 08:36:13.927: INFO/dalvikvm(1470): DexOpt: not resolving ambiguous class 'Lorg/json/JSONObject;'
04-10 08:36:13.927: INFO/dalvikvm(1470): DexOpt: not resolving ambiguous class 'Lorg/json/JSONObject;'
04-10 08:36:13.927: INFO/dalvikvm(1470): DexOpt: not resolving ambiguous class 'Lorg/json/JSONObject;'
04-10 08:36:13.937: INFO/dalvikvm(1470): DexOpt: not resolving ambiguous class 'Lorg/json/JSONObject;'
04-10 08:36:13.937: INFO/dalvikvm(1470): DexOpt: not resolving ambiguous class 'Lorg/json/JSONObject;'
04-10 08:36:13.977: INFO/dalvikvm(1470): DexOpt: not resolving ambiguous class 'Lorg/json/JSONObject;'
04-10 08:36:13.987: INFO/dalvikvm(1470): DexOpt: not resolving ambiguous class 'Lorg/json/JSONObject;'
04-10 08:36:13.997: INFO/dalvikvm(1470): DexOpt: not resolving ambiguous class 'Lorg/json/JSONObject;'
04-10 08:36:14.007: INFO/dalvikvm(1470): DexOpt: not resolving ambiguous class 'Lorg/json/JSONObject;'
04-10 08:36:14.007: INFO/dalvikvm(1470): DexOpt: not resolving ambiguous class 'Lorg/json/JSONObject;'
04-10 08:36:14.037: INFO/dalvikvm(1470): DexOpt: not resolving ambiguous class 'Lorg/json/JSONObject;'
04-10 08:36:14.067: INFO/dalvikvm(1470): DexOpt: not resolving ambiguous class 'Lorg/json/JSONTokener;'
04-10 08:36:14.067: INFO/dalvikvm(1470): DexOpt: not resolving ambiguous class 'Lorg/json/JSONObject;'
04-10 08:36:14.067: INFO/dalvikvm(1470): DexOpt: not resolving ambiguous class 'Lorg/json/JSONObject;'
04-10 08:36:14.067: INFO/dalvikvm(1470): DexOpt: not resolving ambiguous class 'Lorg/json/JSONObject;'
04-10 08:36:14.067: DEBUG/dalvikvm(1470): DexOpt: not verifying 'Lorg/json/JSONTokener;': multiple definitions
04-10 08:36:14.067: INFO/dalvikvm(1470): DexOpt: not resolving ambiguous class 'Lorg/json/JSONTokener;'
04-10 08:36:14.067: DEBUG/dalvikvm(1470): DexOpt: not verifying 'Lorg/json/JSONArray;': multiple definitions
04-10 08:36:14.067: DEBUG/dalvikvm(1470): DexOpt: not verifying 'Lorg/json/JSONException;': multiple definitions
04-10 08:36:14.067: DEBUG/dalvikvm(1470): DexOpt: not verifying 'Lorg/json/JSONObject$1;': multiple definitions
04-10 08:36:14.067: DEBUG/dalvikvm(1470): DexOpt: not verifying 'Lorg/json/JSONObject;': multiple definitions
04-10 08:36:14.067: INFO/dalvikvm(1470): DexOpt: not resolving ambiguous class 'Lorg/json/JSONException;'
04-10 08:36:14.067: DEBUG/dalvikvm(1470): DexOpt: not verifying 'Lorg/json/JSONStringer;': multiple definitions
04-10 08:36:14.077: INFO/dalvikvm(1470): DexOpt: not resolving ambiguous class 'Lorg/json/JSONObject;'
04-10 08:36:14.077: INFO/dalvikvm(1470): DexOpt: not resolving ambiguous class 'Lorg/json/JSONObject;'
04-10 08:36:14.077: INFO/dalvikvm(1470): DexOpt: not resolving ambiguous class 'Lorg/json/JSONTokener;'
04-10 08:36:14.077: INFO/dalvikvm(1470): DexOpt: not resolving ambiguous class 'Lorg/json/JSONObject;'
04-10 08:36:14.087: INFO/dalvikvm(1470): DexOpt: not resolving ambiguous class 'Lorg/json/JSONObject;'
04-10 08:36:14.087: INFO/dalvikvm(1470): DexOpt: not resolving ambiguous class 'Lorg/json/JSONObject;'
04-10 08:36:14.087: INFO/dalvikvm(1470): DexOpt: not resolving ambiguous class 'Lorg/json/JSONObject;'
04-10 08:36:14.087: INFO/dalvikvm(1470): DexOpt: not resolving ambiguous class 'Lorg/json/JSONObject;'
04-10 08:36:14.087: INFO/dalvikvm(1470): DexOpt: not resolving ambiguous class 'Lorg/json/JSONObject;'
04-10 08:36:14.087: INFO/dalvikvm(1470): DexOpt: not resolving ambiguous class 'Lorg/json/JSONObject;'
04-10 08:36:14.087: INFO/dalvikvm(1470): DexOpt: not resolving ambiguous class 'Lorg/json/JSONObject;'
04-10 08:36:14.097: INFO/dalvikvm(1470): DexOpt: not resolving ambiguous class 'Lorg/json/JSONObject;'
04-10 08:36:14.097: DEBUG/dalvikvm(1470): DexOpt: load 61ms, verify+opt 231ms
04-10 08:36:14.187: DEBUG/installd(184): DexInv: --- END '/data/app/com.drippler-1.apk' (success) ---
04-10 08:36:14.197: DEBUG/PackageManager(209):   Services: com.drippler.DripWidget$UpdateService
04-10 08:36:14.197: DEBUG/PackageManager(209):   Receivers: com.admob.android.ads.analytics.InstallReceiver com.drippler.DripWidget com.drippler.ScreenReceiver
04-10 08:36:14.197: DEBUG/PackageManager(209):   Activities: com.drippler.splash com.drippler.Drip com.drippler.About com.drippler.Lead com.drippler.Home com.drippler.Follow com.drippler.FollowHome com.drippler.Categories com.admob.android.ads.AdMobActivity com.drippler.WidgetHome com.drippler.WidgetConfig com.drippler.More com.drippler.Deals com.drippler.Face
04-10 08:36:14.197: INFO/ActivityManager(209): Force stopping package com.drippler uid=10068
04-10 08:36:14.197: WARN/PackageManager(209): Code path for pkg : com.drippler changing from /data/app/com.drippler-2.apk to /data/app/com.drippler-1.apk
04-10 08:36:14.197: WARN/PackageManager(209): Resource path for pkg : com.drippler changing from /data/app/com.drippler-2.apk to /data/app/com.drippler-1.apk
04-10 08:36:14.367: INFO/installd(184): move /data/dalvik-cache/data@app@com.drippler-1.apk@classes.dex -> /data/dalvik-cache/data@app@com.drippler-1.apk@classes.dex
04-10 08:36:14.367: DEBUG/PackageManager(209): New package installed in /data/app/com.drippler-1.apk
04-10 08:36:14.537: INFO/ActivityManager(209): Force stopping package com.drippler uid=10068
04-10 08:36:14.647: INFO/ASK PkgChanged(283): Rebuilding Keyboards since (keyboard) packages have been changed.
04-10 08:36:14.647: INFO/ASK_KF(283): Creating keyboards. I have 4 creators
04-10 08:36:14.657: INFO/VoiceActionsFactory(1290): Applications list changed, recalculating supported actions
04-10 08:36:14.707: DEBUG/dalvikvm(283): GC_EXPLICIT freed 8K, 50% free 2902K/5767K, external 1845K/2357K, paused 56ms
04-10 08:36:14.707: INFO/ASK PkgChanged(283): Refreshing dictionaries since (dictionary) packages have been changed.
04-10 08:36:14.707: VERBOSE/ASK - AK(283): No shift key, so no handling images.
04-10 08:36:14.717: INFO/ASK_QTKF(283): Creating quick text keys. I have 1 creators
04-10 08:36:14.737: DEBUG/VoiceDialerReceiver(1363): onReceive Intent { act=android.intent.action.PACKAGE_REMOVED dat=package:com.drippler flg=0x10000000 cmp=com.android.voicedialer/.VoiceDialerReceiver (has extras) }
04-10 08:36:14.737: VERBOSE/RecognizerEngine(1363): deleteCachedGrammarFiles /data/data/com.android.voicedialer/files/openentries.txt
04-10 08:36:14.767: INFO/ASK_BinaryDictionary(283): Loaded dictionary in 4msec
04-10 08:36:14.787: DEBUG/vending(1300): [19] LocalAssetCache.updateOnePackage(): No local info for com.drippler
04-10 08:36:14.807: INFO/ASK PkgChanged(283): Rebuilding Keyboards since (keyboard) packages have been changed.
04-10 08:36:14.817: INFO/ASK_KF(283): Creating keyboards. I have 4 creators
04-10 08:36:14.827: DEBUG/dalvikvm(847): GC_EXPLICIT freed 57K, 55% free 2827K/6151K, external 1625K/2137K, paused 231ms
04-10 08:36:14.917: DEBUG/dalvikvm(283): GC_EXPLICIT freed 43K, 50% free 2905K/5767K, external 1845K/2357K, paused 104ms
04-10 08:36:14.917: INFO/ASK PkgChanged(283): Refreshing dictionaries since (dictionary) packages have been changed.
04-10 08:36:14.927: VERBOSE/ASK - AK(283): No shift key, so no handling images.
04-10 08:36:14.927: INFO/ASK_QTKF(283): Creating quick text keys. I have 1 creators
04-10 08:36:14.947: DEBUG/InstallReceiver(1354): com.drippler
04-10 08:36:14.947: DEBUG/VoiceDialerReceiver(1363): onReceive Intent { act=android.intent.action.PACKAGE_ADDED dat=package:com.drippler flg=0x10000000 cmp=com.android.voicedialer/.VoiceDialerReceiver (has extras) }
04-10 08:36:14.947: VERBOSE/RecognizerEngine(1363): deleteCachedGrammarFiles /data/data/com.android.voicedialer/files/openentries.txt
04-10 08:36:14.967: DEBUG/vending(1300): [21] LocalAssetCache.updateOnePackage(): No local info for com.drippler
04-10 08:36:14.977: INFO/ActivityManager(209): Start proc com.drippler for broadcast com.drippler/.DripWidget: pid=1477 uid=10068 gids={3003, 1015}
04-10 08:36:15.007: DEBUG/dalvikvm(307): GC_EXPLICIT freed 236K, 58% free 3446K/8199K, external 7046K/7407K, paused 239ms
04-10 08:36:15.017: DEBUG/dalvikvm(1477): Debugger has detached; object registry had 1 entries
04-10 08:36:15.047: DEBUG/AndroidRuntime(1477): Shutting down VM
04-10 08:36:15.057: WARN/dalvikvm(1477): threadid=1: thread exiting with uncaught exception (group=0x40015560)
04-10 08:36:15.067: ERROR/AndroidRuntime(1477): FATAL EXCEPTION: main
04-10 08:36:15.067: ERROR/AndroidRuntime(1477): java.lang.RuntimeException: Unable to start receiver com.drippler.DripWidget: java.lang.NullPointerException
04-10 08:36:15.067: ERROR/AndroidRuntime(1477):     at android.app.ActivityThread.handleReceiver(ActivityThread.java:1805)
04-10 08:36:15.067: ERROR/AndroidRuntime(1477):     at android.app.ActivityThread.access$2400(ActivityThread.java:117)
04-10 08:36:15.067: ERROR/AndroidRuntime(1477):     at android.app.ActivityThread$H.handleMessage(ActivityThread.java:981)
04-10 08:36:15.067: ERROR/AndroidRuntime(1477):     at android.os.Handler.dispatchMessage(Handler.java:99)
04-10 08:36:15.067: ERROR/AndroidRuntime(1477):     at android.os.Looper.loop(Looper.java:123)
04-10 08:36:15.067: ERROR/AndroidRuntime(1477):     at android.app.ActivityThread.main(ActivityThread.java:3683)
04-10 08:36:15.067: ERROR/AndroidRuntime(1477):     at java.lang.reflect.Method.invokeNative(Native Method)
04-10 08:36:15.067: ERROR/AndroidRuntime(1477):     at java.lang.reflect.Method.invoke(Method.java:507)
04-10 08:36:15.067: ERROR/AndroidRuntime(1477):     at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:839)
04-10 08:36:15.067: ERROR/AndroidRuntime(1477):     at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:597)
04-10 08:36:15.067: ERROR/AndroidRuntime(1477):     at dalvik.system.NativeStart.main(Native Method)
04-10 08:36:15.067: ERROR/AndroidRuntime(1477): Caused by: java.lang.NullPointerException
04-10 08:36:15.067: ERROR/AndroidRuntime(1477):     at android.app.ContextImpl.stopService(ContextImpl.java:849)
04-10 08:36:15.067: ERROR/AndroidRuntime(1477):     at android.content.ContextWrapper.stopService(ContextWrapper.java:341)
04-10 08:36:15.067: ERROR/AndroidRuntime(1477):     at android.content.ContextWrapper.stopService(ContextWrapper.java:341)
04-10 08:36:15.067: ERROR/AndroidRuntime(1477):     at com.drippler.DripWidget.onUpdate(DripWidget.java:92)
04-10 08:36:15.067: ERROR/AndroidRuntime(1477):     at android.appwidget.AppWidgetProvider.onReceive(AppWidgetProvider.java:61)
04-10 08:36:15.067: ERROR/AndroidRuntime(1477):     at com.drippler.DripWidget.onReceive(DripWidget.java:411)
04-10 08:36:15.067: ERROR/AndroidRuntime(1477):     at android.app.ActivityThread.handleReceiver(ActivityThread.java:1794)
04-10 08:36:15.067: ERROR/AndroidRuntime(1477):     ... 10 more
04-10 08:36:15.067: INFO/VoiceActionsFactory(1290): Applications list changed, recalculating supported actions
04-10 08:36:15.087: INFO/ASK PkgChanged(283): Rebuilding Keyboards since (keyboard) packages have been changed.
04-10 08:36:15.097: INFO/ASK_KF(283): Creating keyboards. I have 4 creators
04-10 08:36:15.217: DEBUG/dalvikvm(283): GC_EXPLICIT freed 46K, 50% free 2905K/5767K, external 1845K/2357K, paused 117ms
04-10 08:36:15.217: INFO/ASK PkgChanged(283): Refreshing dictionaries since (dictionary) packages have been changed.
04-10 08:36:15.237: VERBOSE/ASK - AK(283): No shift key, so no handling images.
04-10 08:36:15.257: INFO/ASK_QTKF(283): Creating quick text keys. I have 1 creators
04-10 08:36:15.387: DEBUG/dalvikvm(209): GC_CONCURRENT freed 1163K, 46% free 6179K/11271K, external 2080K/2197K, paused 7ms+8ms
04-10 08:36:15.467: DEBUG/dalvikvm(209): GC_EXPLICIT freed 29K, 46% free 6149K/11271K, external 2080K/2197K, paused 70ms
04-10 08:36:15.517: INFO/VoiceActionsFactory(1290): Applications list changed, recalculating supported actions
04-10 08:36:15.527: INFO/installd(184): unlink /data/dalvik-cache/data@app@com.drippler-2.apk@classes.dex
04-10 08:36:15.557: ERROR/NetworkLocationProvider(327): releaseCheckLocationLock: wake lock has already been released
04-10 08:36:15.597: INFO/ASK_BinaryDictionary(283): Loaded dictionary in 598msec
04-10 08:36:15.597: INFO/Launcher(307): setLoadOnResume
04-10 08:36:15.597: INFO/ASK_BinaryDictionary(283): Loaded dictionary in 199msec





I would really want to know what i am doing wrong, 10x.


Edit:

silly me: i found my mistake it had to do with this line:
Code: Select all
04-10 08:36:15.067: ERROR/AndroidRuntime(1477):     at com.drippler.DripWidget.onUpdate(DripWidget.java:92)
royiby
Freshman
Freshman
 
Posts: 5
Joined: Sun Apr 25, 2010 8:33 am
Location: israel

Top

Return to Other Coding-Problems

Who is online

Users browsing this forum: No registered users and 20 guests