首页 > 解决方案 > 使用现有项目打开 Android 模拟器

问题描述

我需要用我现有的项目重新打开 Android 模拟器。当我按下按钮从主文件“运行”项目时,我收到以下错误:

FAILURE: Build failed with an exception.

* What went wrong:
Execution failed for task ':app:processDebugResources'.
> A failure occurred while executing com.android.build.gradle.internal.tasks.Workers$ActionFacade
   > Unable to delete directory 'C:\Users\albat\code\hello_world\build\app\generated\not_namespaced_r_class_sources\debug\r\androidx' after 10 attempts

* Try:
Run with --stacktrace option to get the stack trace. Run with --info or --debug option to get more log output. Run with --scan to get full insights.

* Get more help at https://help.gradle.org

BUILD FAILED in 12s

此外,它不是我一直使用的“Pixel 2 API”设备,而是尝试使用“sdk gphone x86”进行渲染。

感谢您的帮助。

标签: flutter

解决方案


从 android studio 中找到 android AVD 管理器。它将向您显示所有模拟器的列表。选择一个并单击运行。等待它启动,然后尝试再次运行您的应用程序。

让我知道这是否适合您。


推荐阅读