Process has died - android

In my app i am downloading images from the web. Sometimes i am getting the following error in stack trace and then app crashed. What is meaning of the "process has died"? How to handle this?
ERROR
09-06 11:03:46.127 I/ActivityManager( 98): Process com.ibkr.elgifto (pid 7684) has died.
09-06 11:03:46.157 I/WindowManager( 98): WIN DEATH: Window{44b0e778 com.ibkr.elgifto/com.ibkr.elgifto.ElgiftoSplash paused=false}
09-06 11:03:46.167 I/WindowManager( 98): WIN DEATH: Window{44b4e400 com.ibkr.elgifto/com.ibkr.elgifto.Ehome paused=false}
09-06 11:03:46.207 I/ActivityManager( 98): Start proc com.ibkr.elgifto for activity com.ibkr.elgifto/.ElgiftoSplash: pid=8011 uid=10060 gids={3003, 1015}
09-06 11:03:46.487 I/UsageStats( 98): Unexpected resume of com.ibkr.elgifto while already resumed in com.ibkr.elgifto
09-06 11:04:16.687 W/InputManagerService( 98): Got RemoteException sending 'screen on/off' notification to pid 7684 uid 10060

By the stack trace I underatand that your app is resumed while its already running. Wich causes your process to be killed and start again.
Check to see if you are downloading the image on the main thread. If u do that might be the problem.

The way you handle this through handlers and background service and different threads.
Make sure that you dont do any network operations in UI thread

Related

Can't find the root cause that app been kill by android

We're working on an Android game, developing with Cocos2d-x.
Our game seems to be killed by android, but we can't find the root cause about the game close. The adb's log is dumped as follows:
adb's log
Critical portion:
D/dalvikvm( 501): GC_CONCURRENT freed 875K, 19% free 4478K/5464K, paused 2ms+2ms, total 22ms
E/Surface ( 965): queueBuffer: error queuing buffer to SurfaceTexture, -12
W/dalvikvm( 965): trying to work around app JNI bugs, but didn't find 0x41906cd8 in table!
W/dalvikvm( 965): JNI WARNING: DeleteLocalRef(0x41906cd8) failed to find entry
I/FrameQueueManage( 174): FrameQueueManage::~FrameQueueManage end!
D/Zygote ( 172): Process 965 terminated by signal (11)
I/ActivityManager( 501): Process igs.rd5.SuperSoccer (pid 965) has died.
I/WindowState( 501): WIN DEATH: Window{41a365d8 u0 igs.rd5.SuperSoccer/org.cocos2dx.cpp.AppActivity}
W/WindowManager( 501): Force-removing child win Window{41a4fcb0 u0 SurfaceView} from container Window{41a365d8 u0 igs.rd5.SuperSoccer/org.cocos2dx.cpp.AppActivity}
W/ActivityManager( 501): Force removing ActivityRecord{41975d20 u0 igs.rd5.SuperSoccer/org.cocos2dx.cpp.AppActivity t2}: app died, no saved state
W/WindowManager( 501): Failed looking up window
W/WindowManager( 501): java.lang.IllegalArgumentException: Requested window android.os.BinderProxy#41a4be58 does not exist
W/WindowManager( 501): at com.android.server.wm.WindowManagerService.windowForClientLocked(WindowManagerService.java:8102)
W/WindowManager( 501): at com.android.server.wm.WindowManagerService.windowForClientLocked(WindowManagerService.java:8093)
W/WindowManager( 501): at com.android.server.wm.WindowState$DeathRecipient.binderDied(WindowState.java:1047)
W/WindowManager( 501): at android.os.BinderProxy.sendDeathNotice(Binder.java:493)
W/WindowManager( 501): at dalvik.system.NativeStart.run(Native Method)
I/WindowState( 501): WIN DEATH: null
D/mali_winsys( 680): new_window_surface returns 0x3000
W/InputMethodManagerService( 501): Got RemoteException sending setActive(false) notification to pid 965 uid 10047
W/Binder ( 652): Caught a RuntimeException from the binder stub implementation.
W/Binder ( 652): java.lang.NullPointerException
W/Binder ( 652): at android.inputmethodservice.IInputMethodWrapper.setSessionEnabled(IInputMethodWrapper.java:284)
W/Binder ( 652): at com.android.internal.view.IInputMethod$Stub.onTransact(IInputMethod.java:129)
W/Binder ( 652): at android.os.Binder.execTransact(Binder.java:404)
W/Binder ( 652): at dalvik.system.NativeStart.run(Native Method)
We don't see any native library's crash dump, and nearly can't see any java's exception that has senses. Cound anybody tell us why our game is killed by android?

MVVMCross 3.5.1 and xamarin android does not work

I have a question: is there somebody that use MVVMCross 3.5.1 with Api level android 21 and xamarin studio 5.9.3? I have a problem: I reference mvvmcross in an android app. I have a splashscreen and a firstview. When I tried to start with emulator I don't have any problem with level 15 emulator but when I tried it with the last version (Api 21) the app after splashscreen is closed without any error (not open the firstview).
Is there a solution?
UPDATE
I tried with logcat. In the following I attached the log:
W/AudioTrack( 394): AUDIO_OUTPUT_FLAG_FAST denied by client
I/ActivityManager( 394): START u0 {act=android.intent.action.MAIN cat=[android.
intent.category.LAUNCHER] flg=0x10000000 cmp=com.nowhere.nowhere/md51f5aeae0dbe3
fa3acab67292d41114d1.SplashScreen (has extras)} from uid 10007 on display 0
I/Choreographer( 824): Skipped 67 frames! The application may be doing too muc
h work on its main thread.
I/art ( 1716): Not late-enabling -Xcheck:jni (already on)
I/ActivityManager( 394): Start proc com.nowhere.nowhere for activity com.nowher
e.nowhere/md51f5aeae0dbe3fa3acab67292d41114d1.SplashScreen: pid=1716 uid=10056 g
ids={50056, 9997, 3003} abi=armeabi-v7a
I/Choreographer( 394): Skipped 32 frames! The application may be doing too muc
h work on its main thread.
F/MonoDroid( 1716): shared runtime initialization error: dlopen failed: library
"/data/app/Mono.Android.DebugRuntime-1/lib/arm/lib/libmonosgen-2.0.so" not found
I/Zygote ( 66): Process 1716 exited cleanly (1)
I/ActivityManager( 394): Process com.nowhere.nowhere (pid 1716) has died
I/art ( 1731): Not late-enabling -Xcheck:jni (already on)
I/ActivityManager( 394): Start proc com.nowhere.nowhere for activity com.nowher
e.nowhere/md51f5aeae0dbe3fa3acab67292d41114d1.SplashScreen: pid=1731 uid=10056 g
ids={50056, 9997, 3003} abi=armeabi-v7a
F/MonoDroid( 1731): shared runtime initialization error: dlopen failed: library
"/data/app/Mono.Android.DebugRuntime-1/lib/arm/lib/libmonosgen-2.0.so" not found
I/Zygote ( 66): Process 1731 exited cleanly (1)
I/ActivityManager( 394): Process com.nowhere.nowhere (pid 1731) has died
I/art ( 1746): Not late-enabling -Xcheck:jni (already on)
I/ActivityManager( 394): Start proc com.nowhere.nowhere for activity com.nowher
e.nowhere/md51f5aeae0dbe3fa3acab67292d41114d1.SplashScreen: pid=1746 uid=10056 g
ids={50056, 9997, 3003} abi=armeabi-v7a
F/MonoDroid( 1746): shared runtime initialization error: dlopen failed: library
"/data/app/Mono.Android.DebugRuntime-1/lib/arm/lib/libmonosgen-2.0.so" not found
I/Zygote ( 66): Process 1746 exited cleanly (1)
I/ActivityManager( 394): Process com.nowhere.nowhere (pid 1746) has died
W/ActivityManager( 394): Force removing ActivityRecord{27f513c9 u0 com.nowhere.
nowhere/md51f5aeae0dbe3fa3acab67292d41114d1.SplashScreen t8}: app died, no saved
state
W/WindowManager( 394): Failed looking up window
W/WindowManager( 394): java.lang.IllegalArgumentException: Requested window and
roid.view.ViewRootImpl$W#3c7a1def does not exist
W/WindowManager( 394): at com.android.server.wm.WindowManagerService.wi
ndowForClientLocked(WindowManagerService.java:8412)
W/WindowManager( 394): at com.android.server.wm.WindowManagerService.wi
ndowForClientLocked(WindowManagerService.java:8403)
W/WindowManager( 394): at com.android.server.wm.WindowManagerService.re
moveWindow(WindowManagerService.java:2558)
W/WindowManager( 394): at com.android.server.wm.Session.remove(Session.
java:186)
W/WindowManager( 394): at android.view.ViewRootImpl.dispatchDetachedFro
mWindow(ViewRootImpl.java:2920)
W/WindowManager( 394): at android.view.ViewRootImpl.doDie(ViewRootImpl.
java:5390)
W/WindowManager( 394): at android.view.ViewRootImpl$ViewRootHandler.han
dleMessage(ViewRootImpl.java:3223)
W/WindowManager( 394): at android.os.Handler.dispatchMessage(Handler.ja
va:102)
W/WindowManager( 394): at android.os.Looper.loop(Looper.java:135)
W/WindowManager( 394): at android.os.HandlerThread.run(HandlerThread.ja
va:61)
W/WindowManager( 394): at com.android.server.ServiceThread.run(ServiceT
hread.java:46)
W/InputMethodManagerService( 394): Window already focused, ignoring focus gain
of: com.android.internal.view.IInputMethodClient$Stub$Proxy#14f4aa0b attribute=n
ull, token = android.os.BinderProxy#5c9e508
I/Choreographer( 824): Skipped 56 frames! The application may be doing too muc
h work on its main thread.
D/TaskPersister( 394): removeObsoleteFile: deleting file=8_task.xml
UPDATE 2
The bind does not work. Inside the view..
UPDATE 3
I put the code in this repo:
https://onedrive.live.com/redir?resid=1E563B1D1AD8A1C!15847&authkey=!AII01sfuzToQiUQ&ithint=file%2czip
I used this configuration for the test:
1. Nexus 5,
2. Android 5.0-API Level 21,
3. CPU/ABI, I have chosen Google APIs Intel Atom(x86_64),
4. Use Host GPU.
UPDATE 4
new link for code: http://1drv.ms/1MZWf45
Thanks
Alessandro
I found the problem. The problem was the emulator. I tried to change the configuration and now run without problem.
Thanks
Al.

Amazon processes die, then App Crashes

My application runs fine on any Google device. But when I try to run on a Kindle fire, it crashes. Right before the crash happens, Activity Monitor Logs show that around 15-20 processes that start with com.amazon die and are scheduled to restart. Then My app (which is running in the foreground) crashes and attempts to restart:
04-25 15:56:00.487: I/ActivityManager(861): Process com.qualcomm.wfd.service:wfd_service (pid 13715) has died.
04-25 15:56:00.517: I/ActivityManager(861): Process com.qualcomm.wiper (pid 13903) has died.
04-25 15:56:00.517: W/ActivityManager(861): Scheduling restart of crashed service com.qualcomm.wiper/.Wiper in 44738ms
04-25 15:56:00.567: I/WindowState(861): WIN DEATH: Window{421cb828 u0 com.amazon.kindle.otter/com.amazon.kindle.otter.Launcher}
04-25 15:56:00.567: I/ActivityManager(861): Process com.amazon.kindle.otter (pid 15113) has died.
04-25 15:56:00.737: I/ActivityManager(861): Process com.audible.application.kindle (pid 12920) has died.
04-25 15:56:00.737: W/ActivityManager(861): Scheduling restart of crashed service com.audible.application.kindle/com.audible.application.download.service.DownloadManagerService in 54521ms
04-25 15:56:00.737: W/ActivityManager(861): Scheduling restart of crashed service com.audible.application.kindle/com.audible.application.services.PlayerService in 64521ms
04-25 15:56:00.737: W/ActivityManager(861): Scheduling restart of crashed service com.audible.application.kindle/com.audible.application.AudibleContentManagementService in 74521ms
04-25 15:56:00.737: W/ActivityManager(861): Scheduling restart of crashed service com.audible.application.kindle/com.audible.application.media.AudioPlayerService in 84521ms
04-25 15:56:00.817: I/ActivityManager(861): Process com.amazon.zico (pid 13321) has died.
04-25 15:56:00.817: W/ActivityManager(861): Scheduling restart of crashed service com.amazon.zico/.service.LocalFileObserverService in 94443ms
04-25 15:56:00.857: I/ActivityManager(861): Process com.amazon.webview (pid 14116) has died.
04-25 15:56:00.857: W/ActivityManager(861): Scheduling restart of crashed service com.amazon.webview/.WarmupService in 94402ms
04-25 15:56:00.897: I/ActivityManager(861): Process com.ivona.tts.oem (pid 14231) has died.
04-25 15:56:00.897: W/ActivityManager(861): Scheduling restart of crashed service com.ivona.tts.oem/com.ivona.ttslib.engine.TTSServiceActivation in 104365ms
04-25 15:56:01.077: I/ActivityManager(861): Process com.amazon.platform (pid 14652) has died.
04-25 15:56:01.077: W/ActivityManager(861): Scheduling restart of crashed service com.amazon.platform/com.amazon.geo.platform.GeoDeviceService in 114186ms
04-25 15:56:01.117: I/ActivityManager(861): Process com.nokia.odnp.service:remote (pid 14738) has died.
04-25 15:56:01.117: W/ActivityManager(861): Scheduling restart of crashed service com.nokia.odnp.service/.OdnpService in 124145ms
04-25 15:56:01.397: I/ActivityManager(861): Process com.amazon.kindle.cms (pid 12817) has died.
04-25 15:56:01.397: W/ActivityManager(861): Scheduling restart of crashed service com.amazon.kindle.cms/.CMSService in 133859ms
04-25 15:56:01.397: W/ActivityManager(861): Scheduling restart of crashed service com.amazon.kindle.cms/.MaintenanceService in 143858ms
04-25 15:56:01.487: I/ActivityManager(861): Process com.nuance.swype.input:SwypeConnect (pid 12837) has died.
04-25 15:56:01.487: W/ActivityManager(861): Scheduling restart of crashed service com.nuance.swype.input/com.nuance.swype.connect.ConnectClient in 0ms
04-25 15:56:01.487: I/ActivityManager(861): Start proc com.nuance.swype.input:SwypeConnect for service com.nuance.swype.input/com.nuance.swype.connect.ConnectClient: pid=15792 uid=32062 gids={72062, 3003, 1015, 3002, 1028, 9001}
04-25 15:56:01.607: I/ActivityManager(861): Start proc com.amazon.kindle.cms for service com.amazon.kindle.cms/.CMSService: pid=15810 uid=32092 gids={72092, 1015, 3003, 1028, 9001}
04-25 15:56:01.657: I/ActivityManager(861): Process com.android.inputmethod.latin (pid 15740) has died.
04-25 15:56:01.657: W/ActivityManager(861): Scheduling restart of crashed service com.android.inputmethod.latin/.spellcheck.AndroidSpellCheckerService in 153603ms
04-25 15:56:01.757: I/ActivityManager(861): Start proc com.amazon.device.settings:Settings for content provider com.amazon.device.settings/.SettingsProvider: pid=15830 uid=32086 gids={72086, 3003, 1028, 9001}
04-25 15:56:02.227: I/ActivityManager(861): Process com.theatavist.atavist (pid 15290) has died.
04-25 15:56:02.227: I/WindowState(861): WIN DEATH: Window{422de940 u0 com.theatavist.atavist/net.atavist.android.LaunchActivity}
04-25 15:56:02.237: W/ActivityManager(861): Force removing ActivityRecord{42941990 u0 com.theatavist.atavist/net.atavist.android.view.testPaging.TestPagerActivity}: app died, no saved state
04-25 15:56:02.237: I/WindowState(861): WIN DEATH: Window{423b0b38 u0 com.theatavist.atavist/net.atavist.android.StoreActivity}
04-25 15:56:02.247: I/WindowState(861): WIN DEATH: Window{4273e5c8 u0 com.theatavist.atavist/net.atavist.android.view.testPaging.TestPagerActivity}
04-25 15:56:02.247: V/DoNotDisturb(861): Top component: com.theatavist.atavist/net.atavist.android.StoreActivity
04-25 15:56:02.267: I/ActivityManager(861): Start proc com.theatavist.atavist for activity com.theatavist.atavist/net.atavist.android.StoreActivity: pid=15877 uid=10000 gids={50000, 1015, 3003, 1028}
04-25 15:56:02.297: D/WindowManager(861): openingActivityName = net.atavist.android.StoreActivity, animAttr = 4
04-25 15:56:02.297: V/DoNotDisturb(861): Top component: com.theatavist.atavist/net.atavist.android.StoreActivity
04-25 15:56:02.317: W/Settings(861): Setting default_input_method has moved from android.provider.Settings.Secure to android.provider.Settings.Global.
04-25 15:56:02.337: D/ProfileManager(15877): Create ProfileManager instance
04-25 15:56:02.357: D/SurfaceTexture(424): [Starting com.theatavist.atavist] setFilteringEnabled called with mCurrentTextureBuf == NULL
04-25 15:56:02.367: I/Activity(15877): Constructing ActvityExender com.amazon.android.app.AmazonActivityExtender.
04-25 15:56:02.367: I/Activity(15877): Constructed ActvityExender com.amazon.android.app.AmazonActivityExtender.
There is no description of the crash itself, so I'm not sure how to fix. Does anyone have any ideas?
It may be an ANR.
I have a suite of about 400 unit tests that run fine on various other devices (including the Amazon Phone Fire) but fail on the Amazon Kindle Fire HDX 7".
When this "crash" happens there is no java stack trace and no c stack trace. The crash never happens on the same test. And, obviously, running those unit tests by themselves never causes an issue.
When the process finally exits, there isn't much fanfare beyond the normal unit test exist. E.g. there is a WIN DEATH log line, however even when the unit tests run successfully to completion it still announces WIN DEATH.
I have noticed something interesting though. When I monitor logcat using the following command:
adb logcat WindowState:I *:S
I see a page full of these:
I/WindowState( 826): WIN DEATH: Window{41968490 u0 com.amazon.kindle.otter/com.amazon.kindle.otter.Launcher}
When I sit there and watch the output, the pace of errors increases until my test app crashes.
According to some docs I've found, lack of response to a touch event in 5 sec, or a BroadcastReceiver running for 10 sec will cause an ANR in normal android. However, I don't know what amazon has done to it.
I did another test that passes a runnable to $getInstrumentation().runOnMainSync()$ which busy waits in an empty while loop for 120 seconds. That alone didn't cause the app to be killed, until I touched the back button. Then I see the same exact crash: window death, no stack trace, no c stack trace.
Also, in both the original crash and the deliberate ANR, I see a line mentioning ActivityRecord having difficulty (not always exactly this line):
W/ActivityManager( 826): Activity pause timeout for ActivityRecord{40fadb78 u0 com.amazon.kindle.otter/.Launcher}
I tried making the junit thread sleep for 1500ms after each thread, thinking that I was starving some background system of the UI thread (my unit tests cause 6,000 views to be created in a short amount of time), but that has not helped, and it has not noticeably delayed the crash either.

Using WeakSubscribe from MvvmCross

I need to subscribe to INotifyPropertyChanged of one of my models in my ViewModel. My research led me to: How do I update the parent viewmodel when child viewmodel is updated.
I tried using WeakSubscribe as suggested in #3 but after entering and leaving the view several times my whole application either freezes or crashes.
Here's my code from Init() in the ViewModel:
foreach (var sale in Model.Sales)
{
sale.WeakSubscribe(delegate
{
Model.CalculateSalesTotals();
});
}
when the app is crashing, I'm getting SIGSEGV:
I/mono-stdout(30334): mvx:Diagnostic:227.00 Showing ViewModel InvoiceAuthorizationViewModel
I/ActivityManager( 391): START u0 {flg=0x10000000 cmp=com.desco.escMobile/escmobile.android.views.InvoiceAuthorizationView (has extras)} from pid 30334
I/mono-stdout(30334): mvx:Diagnostic:227.19 Loading new ViewModel from Intent with Extras
D/dalvikvm(30334): GC_EXPLICIT freed 783K, 5% free 17252K/18068K, paused 2ms+8ms, total 53ms
I/mono-stdout(30334): MvxBind:Warning:227.59 Unable to bind: source property source not found Cirrious.MvvmCross.Binding.Parse.PropertyPath.PropertyTokens.MvxPr
opertyNamePropertyToken on null-object
I/mono-stdout(30334): MvxBind:Warning:227.61 Unable to bind: source property source not found Cirrious.MvvmCross.Binding.Parse.PropertyPath.PropertyTokens.MvxPr
opertyNamePropertyToken on null-object
I/mono-stdout(30334): MvxBind:Warning:227.63 Unable to bind: source property source not found Cirrious.MvvmCross.Binding.Parse.PropertyPath.PropertyTokens.MvxPr
opertyNamePropertyToken on null-object
I/dalvikvm(30334): Jit: resizing JitTable from 4096 to 8192
I/ActivityManager( 391): Displayed com.desco.escMobile/escmobile.android.views.InvoiceAuthorizationView: +755ms (total +1s259ms)
I/ActivityManager( 391): Displayed com.desco.escMobile/escmobile.android.views.InvoiceAuthorizationView: +1s279ms
I/ActivityManager( 391): Process com.android.vending (pid 30179) has died.
E/mono-rt (30334): Stacktrace:
E/mono-rt (30334):
E/mono-rt (30334):
E/mono-rt (30334): =================================================================
E/mono-rt (30334): Got a SIGSEGV while executing native code. This usually indicates
E/mono-rt (30334): a fatal error in the mono runtime or one of the native libraries
E/mono-rt (30334): used by your application.
E/mono-rt (30334): =================================================================
E/mono-rt (30334):
I/ActivityManager( 391): Process com.desco.escMobile (pid 30334) has died.
I/WindowState( 391): WIN DEATH: Window{42cf2e60 u0 com.desco.escMobile/escmobile.android.views.InvoiceAuthorizationView}
W/ActivityManager( 391): Force removing ActivityRecord{42e05b20 u0 com.desco.escMobile/escmobile.android.views.InvoiceAuthorizationView}: app died, no saved st
ate
I/WindowState( 391): WIN DEATH: Window{427bfbf0 u0 com.desco.escMobile/escmobile.android.views.DispatchListView}
I/WindowState( 391): WIN DEATH: Window{42b32b50 u0 com.desco.escMobile/escmobile.android.views.InvoiceDetailsView}
I/WindowState( 391): WIN DEATH: Window{43003e48 u0 com.desco.escMobile/escmobile.android.views.InvoiceAuthorizationView}
I/WindowState( 391): WIN DEATH: Window{42aea920 u0 com.desco.escMobile/escmobile.android.views.DispatchDetailsView}
D/dalvikvm(30434): Late-enabling CheckJNI
I/ActivityManager( 391): Start proc com.desco.escMobile for activity com.desco.escMobile/escmobile.android.views.InvoiceAuthorizationView: pid=30434 uid=10086
gids={50086, 3003, 1015, 1028}
D/Zygote ( 129): Process 30334 exited cleanly (255)
Any suggestions?

Android Toast cannot be resolved as field or type

I've done some research on the above error and it would seem that to solve there are two ways most people do:
Re import R
Close and restart eclipse
However I have done both and yet I still get the same error. Does anyone know of any other ways to defeat this error?
I'm thinking though that it may be my code. I'm trying to compile the bluetooth le sample found here
I've brought over everything yet I'm still stuck with 36 errors with most of them being this cannot be resolved as field or type error.
Here is how they call the toast line:
Toast.makeText(this, R.string.error_bluetooth_not_supported, Toast.LENGTH_SHORT).show();
And there strings.xml found in the values folder:
<?xml version="1.0" encoding="utf-8"?>
<resources>
<string name="app_name">BLE Sample</string>
<string name="ble_not_supported">BLE is not supported</string>
<string name="label_data">Data:</string>
<string name="label_device_address">Device address:</string>
<string name="label_state">State:</string>
<string name="no_data">No data</string>
<string name="connected">Connected</string>
<string name="disconnected">Disconnected</string>
<string name="title_devices">BLE Device Scan</string>
<string name="error_bluetooth_not_supported">Bluetooth not supported.</string>
<string name="unknown_device">Unknown device</string>
<string name="unknown_characteristic">Unknown characteristic</string>
<string name="unknown_service">Unknown service</string>
<!-- Menu items -->
<string name="menu_connect">Connect</string>
<string name="menu_disconnect">Disconnect</string>
<string name="menu_scan">Scan</string>
<string name="menu_stop">Stop</string>
</resources>
I'm literally a day into my first android development and this is all new to me. I thought using the sample code they would provide would help me get a good over view of how the bluetooth system works.
Can anyone help me beat this error?
I should add that every item on this list has an error. Any time I call anything with R.string. it get the same error.
Logcat since 1:25pm:
09-06 13:25:20.901: E/(526): W/virtual loc_api_adapter_err LocApiAdapter::enableData(int): default implementation invoked
09-06 13:25:20.901: E/(526): W/virtual loc_api_adapter_err LocApiAdapter::setAPN(char*, int): default implementation invoked
09-06 13:25:20.911: D/PicasaUploaderSyncManager(25851): active network: NetworkInfo: type: WIFI[], state: CONNECTED/CONNECTED, reason: (unspecified), extra: "SOL2", roaming: false, failover: false, isAvailable: true
09-06 13:25:20.921: D/GCM(2565): GcmService start Intent { act=android.net.conn.CONNECTIVITY_CHANGE flg=0x8000010 cmp=com.google.android.gms/.gcm.GcmService (has extras) } android.net.conn.CONNECTIVITY_CHANGE
09-06 13:25:21.051: D/ConnectivityService(526): handleInetConditionHoldEnd: net=1, condition=100, published condition=0
09-06 13:25:21.542: D/Tethering(526): MasterInitialState.processMessage what=3
09-06 13:25:21.642: E/(526): W/virtual loc_api_adapter_err LocApiAdapter::enableData(int): default implementation invoked
09-06 13:25:21.642: E/(526): W/virtual loc_api_adapter_err LocApiAdapter::setAPN(char*, int): default implementation invoked
09-06 13:25:21.662: D/GCM(2565): GcmService start Intent { act=android.net.conn.CONNECTIVITY_CHANGE flg=0x8000010 cmp=com.google.android.gms/.gcm.GcmService (has extras) } android.net.conn.CONNECTIVITY_CHANGE
09-06 13:25:22.102: D/ConnectivityService(526): handleInetConditionHoldEnd: net=1, condition=100, published condition=100
09-06 13:30:01.245: V/DigitalWidgetViewsFactory(6453): DigitalWidget sets next alarm string to null
09-06 13:36:19.083: I/ActivityManager(526): No longer want com.google.android.talk (pid 26303): empty for 1801s
09-06 13:36:31.455: V/BackupManagerService(526): Running a backup pass
09-06 13:36:31.455: V/BackupManagerService(526): clearing pending backups
09-06 13:36:31.455: V/PerformBackupTask(526): Beginning backup of 1 targets
09-06 13:36:31.485: V/BackupServiceBinder(526): doBackup() invoked
09-06 13:36:31.485: D/PerformBackupTask(526): invokeAgentForBackup on #pm#
09-06 13:36:31.495: I/PerformBackupTask(526): no backup data written; not calling transport
09-06 13:36:31.506: D/PerformBackupTask(526): starting agent for backup of BackupRequest{pkg=com.android.providers.settings}
09-06 13:36:31.506: D/BackupManagerService(526): awaiting agent for ApplicationInfo{4202bfe0 com.android.providers.settings}
09-06 13:36:31.506: D/BackupManagerService(526): agentConnected pkg=com.android.providers.settings agent=android.app.backup.BackupAgent$BackupServiceBinder#42081138
09-06 13:36:31.506: I/BackupManagerService(526): got agent android.app.backup.BackupAgent$BackupServiceBinder#42081138
09-06 13:36:31.506: D/PerformBackupTask(526): invokeAgentForBackup on com.android.providers.settings
09-06 13:36:31.516: V/BackupServiceBinder(526): doBackup() invoked
09-06 13:36:31.526: W/SettingsBackupAgent(526): Couldn't backup /data/misc/wifi/ipconfig.txt
09-06 13:36:31.526: I/PerformBackupTask(526): no backup data written; not calling transport
09-06 13:36:31.526: I/PerformBackupTask(526): Backup pass finished.
09-06 13:39:59.999: I/ActivityManager(526): No longer want com.google.android.music:main (pid 26385): empty for 1849s
09-06 13:40:00.099: W/ActivityManager(526): Scheduling restart of crashed service com.google.android.music/.playback.MusicPlaybackService in 5000ms
09-06 13:40:05.134: I/ActivityManager(526): Start proc com.google.android.music:main for service com.google.android.music/.playback.MusicPlaybackService: pid=27303 uid=10041 gids={50041, 3003, 1015, 1028}
09-06 13:40:05.214: I/MusicStore(27303): Database version: 70
09-06 13:40:05.274: D/dalvikvm(27303): GC_CONCURRENT freed 315K, 4% free 9097K/9448K, paused 3ms+9ms, total 39ms
09-06 13:40:05.274: D/dalvikvm(27303): WAIT_FOR_CONCURRENT_GC blocked 2ms
09-06 13:40:05.284: D/dalvikvm(27303): WAIT_FOR_CONCURRENT_GC blocked 5ms
09-06 13:40:05.364: D/SystemUtils(27303): getSystemProperty: lpa.decode=null
09-06 13:40:05.364: D/CacheService(27303): onCreate
09-06 13:40:05.374: D/CacheService(27303): onBind
09-06 13:40:05.384: I/LocalDevicePlayback(27303): Streaming client created.
09-06 13:40:06.445: D/dalvikvm(27303): GC_CONCURRENT freed 181K, 3% free 9337K/9580K, paused 4ms+4ms, total 30ms
09-06 13:40:06.535: I/MediaStoreImporter(27303): Update: incremental Added music: 0 Updated music: 0 Deleted music: 0 Created playlists: 0 Updated playlists: 0 Deleted playlists: 0 Inserted playlist items: 0 Deleted playlist items: 0 Removed orphaned playlist items: 0
09-06 13:40:10.459: I/MusicLeanback(27303): Conditions not met for autocaching.
09-06 13:40:10.459: I/MusicLeanback(27303): Stop autocaching.
09-06 13:40:20.549: D/GCM(2565): Ignoring attempt to send heartbeat on dead connection.
09-06 13:40:59.997: I/ActivityManager(526): No longer want android.process.acore (pid 26550): empty for 1807s
09-06 13:45:01.283: V/DigitalWidgetViewsFactory(6453): DigitalWidget sets next alarm string to null
09-06 13:48:16.403: I/EventLogService(2565): Aggregate from 1378470317827 (log), 1378469896229 (data)
09-06 13:48:16.533: I/ServiceDumpSys(2565): dumping service [account]
09-06 13:50:23.497: I/jdwp(24586): Ignoring second debugger -- accepting and dropping
09-06 13:50:23.507: I/jdwp(20948): Ignoring second debugger -- accepting and dropping
09-06 13:50:34.378: D/dalvikvm(526): GC_CONCURRENT freed 3407K, 27% free 23292K/31488K, paused 11ms+8ms, total 146ms
09-06 13:52:43.224: D/ChildProcessLauncher(5790): Setting up connection to process: slot=2
09-06 13:52:43.224: I/ActivityManager(526): Start proc com.android.chrome:sandboxed_process2 for service com.android.chrome/org.chromium.content.app.SandboxedProcessService2: pid=27469 uid=99002 gids={}
09-06 13:52:43.244: I/ChildProcessService(27469): Creating new ChildProcessService pid=27469
09-06 13:52:43.254: D/ChildProcessLauncher(5790): on connect callback, pid=27469 context=2105709408
09-06 13:52:43.254: I/LibraryLoader(27469): loading: chromeview
09-06 13:52:43.304: I/LibraryLoader(27469): loaded: chromeview
09-06 13:52:43.304: I/chromium(27469): [INFO:library_loader_hooks.cc(72)] Chromium logging enabled: level = 0, default verbosity = 0
09-06 13:52:43.314: D/TraceEvent(27469): View tag enabled: false
09-06 13:52:43.334: I/chromium(27469): [INFO:child_process_service.cc(132)] ChildProcessService: Exiting child process.
09-06 13:52:43.344: W/ChildProcessConnection(5790): onServiceDisconnected (crash?): pid=27469
09-06 13:52:43.344: D/ChildProcessLauncher(5790): stopping child connection: pid=27469
09-06 13:52:43.344: I/ActivityManager(526): Process com.android.chrome:sandboxed_process2 (pid 27469) has died.
09-06 13:52:43.344: W/ActivityManager(526): Scheduling restart of crashed service com.android.chrome/org.chromium.content.app.SandboxedProcessService2 in 5000ms
Try to show Toast like this:
Toast.makeText(context, context.getString(R.string.error_bluetooth_not_supported),Toast.LENGTH_LONG).show();
Here context refers to context of current Activity where you showing the Toast.
See these as well: Toast.makeText from resource string
Android: Java: using a string resource in a Toast
1) Typically, all R.string.stuff cease to be errors after you build the project because the file R.java is generated during the build. If you have not yet built the project, they are shown as errors and this is normal. By the way, in Eclipse, you can manually delete the error messages in the error message window (you can select and delete one or several errors, but cannot delete the root node that reads "Errors (N items)"). One more "magic" pass is pressing F5 ("Refresh") when the project is selected in the "Package Explorer" (the left-hand) pane.
2) Make sure that the generated R class belongs to the same package as the class where it's used. In Eclipse you must see in the "Package Explorer" pane: YourProject--gen--your.package--R.java.
(If that file does not exist, is the folder read/write?)
3) It may be easier to create an empty project and move the google sources to it than try to compile the project from git. At least some google app projects use a directory structure that is different from what you normally get with Eclipse (because they are built with a special script).
Generally when there are any errors in the resource folder , the R.Java file doesnt get created properly and as a result you will get this sort of error . Please check whether you have any errors in the layout folder or drawable folder.
Use:
Toast.makeText(this, getResources().getText(R.string.error_bluetooth_not_supported).toString(), Toast.LENGTH_SHORT).show();
U can use:
String str = getResources().getText(R.string.error_bluetooth_not_supported).toString();

Categories

Resources