2

I have this strange error when deploy and run Android application on a real device running Android 4.4.4 (API 19). Recently I have installed Windows 8.1 Pro, Android Studio 8.14, Java 1.7.0_67 x64. Before that on Windows 7 machine everything worked fine.

Here comes the stack trace:

main@830030777992, prio=5, in group 'main', status: 'RUNNING'
      at libcore.io.ForwardingOs.stat(ForwardingOs.java:131)
      at dalvik.system.DexPathList.splitAndAdd(DexPathList.java:193)
      at dalvik.system.DexPathList.splitPaths(DexPathList.java:177)
      at dalvik.system.DexPathList.splitLibraryPath(DexPathList.java:160)
      at dalvik.system.DexPathList.<init>(DexPathList.java:120)
      at dalvik.system.BaseDexClassLoader.<init>(BaseDexClassLoader.java:48)
      at dalvik.system.PathClassLoader.<init>(PathClassLoader.java:65)
      at android.app.ApplicationLoaders.getClassLoader(ApplicationLoaders.java:57)
      at android.app.LoadedApk.getClassLoader(LoadedApk.java:327)
      at android.app.LoadedApk.makeApplication(LoadedApk.java:513)
      at android.app.ActivityThread.handleBindApplication(ActivityThread.java:4435)
      at android.app.ActivityThread.access$1500(ActivityThread.java:144)
      at android.app.ActivityThread$H.handleMessage(ActivityThread.java:1306)
      at android.os.Handler.dispatchMessage(Handler.java:102)
      at android.os.Looper.loop(Looper.java:212)
      at android.app.ActivityThread.main(ActivityThread.java:5135)
      at java.lang.reflect.Method.invokeNative(Method.java:-1)
      at java.lang.reflect.Method.invoke(Method.java:515)
      at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:878)
      at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:694)
      at dalvik.system.NativeStart.main(NativeStart.java:-1)

And these are available run time variables:

this = {libcore.io.BlockGuardOs@830030803952}
    os = {libcore.io.Posix@830030808968}

Exception = {libcore.io.ErrnoException@830055892600}
    functionName = {java.lang.String@830055892526}"stat"
    errno = 2
    cause = {libcore.io.ErrnoException@830055892600}"libcore.io.ErrnoException: stat failed: ENOENT (No such file or directory)"
    dataMessage = null
    stackState = {int[44]@83005589640}
    stackTrace = {java.lang.StackTraceElement[0]@830030771936}
    suppressedExceptions = {java.util.Collections$EmptyList@8300307698166} size = 0

As far as I understand the app is not even started. Tried to uninstall and redeploy the app several times - no success.

Any help and suggestions will be appreciated.

update 16.11.2014

I've just run the app on emulator and it works fine, but it still doesn't start on my phone. UNinstalled, rebooted to recovery, cleared Dalvik cache, redeployed - didn't help

update 19.11.2014

I lost patience and downgraded to Windows 7. On the first deploy Android studio asked me to uninstall the app, I agreed and now it works fine. The Run log follows (maybe it will be helpful to somebody)

Installing com.ash.challenge
DEVICE SHELL COMMAND: pm install -r "/data/local/tmp/com.maypackage"
pkg: /data/local/tmp/com.maypackage
Failure [INSTALL_PARSE_FAILED_INCONSISTENT_CERTIFICATES]


DEVICE SHELL COMMAND: pm uninstall com.maypackage
DEVICE SHELL COMMAND: pm install -r "/data/local/tmp/com.maypackage"
pkg: /data/local/tmp/com.maypackage
Success
Aleksandr
  • 489
  • 1
  • 4
  • 12
  • This question might need more info. Can you show where in the source it crashes? I looked for the exception (ENOENT) and found this (can't write to root of internal storage): http://stackoverflow.com/questions/11620641/android-error-open-failed-enoent – ǝɲǝɲbρɯͽ Nov 13 '14 at 23:49
  • The problem is that stack doesn't show my code at all. I assume it has something to do with dex files (at dalvik.system.DexPathList.splitAndAdd(DexPathList.java:193)). – Aleksandr Nov 14 '14 at 06:38
  • I would try installing the application as you would do normally, the uninstalling it via adb with the following command: adb shell pm uninstall com.packagename My experience is that this does a better job at removing an application than doing it via the GUI would. It's worth a try, because it looks like the application is fine, just the phone doesn't accept it. – Daniel Zolnai Nov 16 '14 at 22:51

0 Answers0