Android Studio卡在“安装APK”上 [英] Android Studio Stuck on "Installing APK"

查看:474
本文介绍了Android Studio卡在“安装APK”上的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

Android Studio似乎不再检测何时在目标设备上安装了应用程序并打开了该应用程序。它卡在安装APK上,进度条为空。没有错误,apk已成功安装并打开,只是IDE仍显示 Installing APK,并且不会自动连接调试器。我可以使用将调试器附加到Android进程按钮手动连接调试器,但这并不理想。

Android Studio no longer seems to be detecting when an app has installed on a target device and opened. It gets stuck on "Installing APK" and the progress bar is empty. There are no errors, the apk successfully installs and opens, it's just the IDE is still showing "Installing APK" and it does not automatically connect the debugger. I can manually connect the debugger using the "Attach debugger to Android process button", but this is not ideal.

任何人都可以提供有关如何解决问题的建议吗?

Can anyone offer any suggestions for what's up and how to resolve it?

推荐答案

事实证明问题并非出在Android Studio上,而是在我用于测试的设备上。我尝试了另一台设备,它的行为正常,超出了安装APK并在断点处停止的功能。

It turns out the problem wasn't with Android Studio, but with the device I was using for testing. I tried a different device and it behaved normally, progressing beyond "Installing APK" and stopping on breakpoints.

以某种方式,问题的开发人员选项中的等待调试器设置设备已关闭。我重新打开了电源,现在此设备的运行正常。

Somehow the "wait for debugger" setting in developer options on the problem device had switched to off. I switched this back on and now this device is behaving normally.

-请注意,我必须选择一个任意调试应用程序才能使设置生效。将其设置为打开后,我取消选择了调试应用,并且设置保持打开状态。这是运行Android 6.0 API级别23的HUAWEI P8。

-Note that I had to choose an arbitrary debug app for the setting to become active. Once I'd set it on, I deselected the debug app and the setting remained on, as I left it. This was a HUAWEI P8 running android 6.0 API Level 23.

这篇关于Android Studio卡在“安装APK”上的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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