升级到 Lollipop 后无法测试应用 [英] Unable to test app after upgrading to Lollipop

查看:43
本文介绍了升级到 Lollipop 后无法测试应用的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我正在使用 Android Studio 开发我的应用.

I am using Android Studio to develop my apps.

自从我将 HTC One M8 升级到 Lollipop 后,我无法使用它在 Android Studio 中通过运行应用程序"来测试我的应用程序.我收到此错误,但我的手机没有任何反应:

Since I upgraded my HTC One M8 to Lollipop, I can not use it to test my apps by "Run app" in Android Studio. I get this error and nothing happens on my phone:

Launching application: com.project.GalleryActivity.
DEVICE SHELL COMMAND: am start -n "com.project.GalleryActivity" -a android.intent.action.MAIN -c android.intent.category.LAUNCHER
java.lang.UnsatisfiedLinkError: No implementation found for java.lang.String android.os.SystemProperties.native_get(java.lang.String) (tried Java_android_os_SystemProperties_native_1get and Java_android_os_SystemProperties_native_1get__Ljava_lang_String_2)
at android.os.SystemProperties.native_get(Native Method)
at android.os.SystemProperties.get(SystemProperties.java)
at com.htc.customization.HtcCustomizationManager.<init>(HtcCustomizationManager.java)
at com.htc.customization.HtcCustomizationManager.<clinit>(HtcCustomizationManager.java)
at android.os.Environment$UserEnvironment.getCustomizationReader(Environment.java)
at android.os.Environment$UserEnvironment.isDynamicSwitchSupported(Environment.java)
at android.os.Environment$UserEnvironment.<init>(Environment.java)
at android.os.Environment.initForCurrentUser(Environment.java)
at android.os.Environment.<clinit>(Environment.java)
at android.os.Environment.getLegacyExternalStorageDirectory(Environment.java)
at android.os.Debug.<clinit>(Debug.java)
at android.ddm.DdmHandleHello.handleHELO(DdmHandleHello.java)
at android.ddm.DdmHandleHello.handleChunk(DdmHandleHello.java)
at org.apache.harmony.dalvik.ddmc.DdmServer.dispatch(DdmServer.java)
java.lang.UnsatisfiedLinkError: android.os.Debug
at android.ddm.DdmHandleHello.handleFEAT(DdmHandleHello.java)
at android.ddm.DdmHandleHello.handleChunk(DdmHandleHello.java)
at org.apache.harmony.dalvik.ddmc.DdmServer.dispatch(DdmServer.java)
java.lang.UnsatisfiedLinkError: android.os.Debug
at android.ddm.DdmHandleProfiling.handleMPRQ(DdmHandleProfiling.java)
at android.ddm.DdmHandleProfiling.handleChunk(DdmHandleProfiling.java)
at org.apache.harmony.dalvik.ddmc.DdmServer.dispatch(DdmServer.java)
Aborted

我的项目设置如下:

这种技术在升级之前可以完美运行,从那时起我没有改变任何东西.

This technique used to work perfectly before upgrading and I have not change anything since that time.

推荐答案

我在使用 Android 5.0 的 Asus Zenfone 5 (ASUS_T00J) 上遇到了同样的错误.对我来说,解决方案是关闭开发人员选项"中的通过 USB 验证应用程序".Launcher 可能不是问题,因为我也尝试过使用 Google Now Launcher 也没有成功.在装有 Android 5.1 的 Nexus 5 上运行良好

I was facing the same error on Asus Zenfone 5 (ASUS_T00J) with Android 5.0. For me the solution was to switch off the "Verify Apps over USB" in the "Developer Options". Launcher may not be the issue since I tried with Google Now Launcher as well without success. It was working fine on my Nexus 5 with Android 5.1

这篇关于升级到 Lollipop 后无法测试应用的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆