【问题标题】:Can't run Android Studio's Emulator无法运行 Android Studio 的模拟器
【发布时间】:2021-05-01 07:43:23
【问题描述】:

我猜是因为在运行检测文件后无法打开 Android Studio 的模拟器? 但我不确定。

错误信息: 在无设备上启动“应用程序”。 等待设备时出错:AVD Pixel_4_XL_API_30 的模拟器进程被终止。

【问题讨论】:

  • 你能从 AVD Manager 手动启动模拟器吗?
  • @Martheen 我也无法从 AVD Manager 手动启动模拟器。
  • 在启动模拟器时使用错误消息编辑您的问题

标签: android-studio android-emulator


【解决方案1】:

我使用以下解决方案解决了这个问题。↓

Tools -> SDK Manager -> SDK Tools (tab) -> Deselect 'Android Emulator' -> OK

Now, when you try to run your app, or launch device from AVD Manager, it will give the 'Install Emulator' error -> Click Ok. This will automatically download the correct version.

【讨论】:

  • 不幸的是,这个解决方案对我没有帮助。 API 30 和 31 与模拟器有关。尤其是在北极狐中,它甚至都没有开始。 androidstudio.googleblog.com/2021/04/…
  • 在 Android Studio Bumblebee 上仍然失败 | 2021.1.1 Patch 2 Build #AI-211.7628.21.2111.8193401,于 2022 年 2 月 17 日构建 运行时版本:11.0.11+0-b60-7590822 x86_64 VM:JetBrains s.r.o 的 OpenJDK 64 位服务器 VM macOS 10.15.7
【解决方案2】:

我在使用模拟器版本 30.6.4 和 Android Studio Arctic Fox 2020.3.1 Canary 15 时遇到了同样的问题。我尝试从 Intel HAXM 切换到 Windows Hyper-V 并重新安装了所有 android 构建工具和模拟器包。然后它工作了一天。

我尝试的第二件事是手动安装旧版本 (30.5.5) 的模拟器,您可以从 here 获得。现在 Android Studio 无法识别我手动安装的模拟器,我无法从 UI 启动 AVD。但是我可以通过 cmd 启动它并从 android studio 中安装应用程序而不会崩溃(至少目前如此)。

使用以下命令 (android/sdk/emulator) 启动您的 AVD:

emulator -avd <name-with-_-instead-of-spaces>

【讨论】:

    猜你喜欢
    • 2020-08-17
    • 1970-01-01
    • 2015-05-18
    • 2019-03-03
    • 2015-05-06
    • 1970-01-01
    • 2016-09-09
    • 1970-01-01
    • 2020-08-02
    相关资源
    最近更新 更多