Не удалось запустить отладку приложения flutter в vscode. Проект «приложение» не найден в корневом проекте «android»

#android #flutter #visual-studio-code

Вопрос:

Когда я пытаюсь отладить свое приложение Flutter в vscode, оно показывает ошибку, но когда я запускаю свое приложение в Android Studio, оно работает правильно.

Это ошибка, которую он показывает:

 Launching libmain.dart on Android SDK built for x86 in debug mode...
[!] Your app isn't using AndroidX.
    To avoid potential build failures, you can quickly migrate your app by following the steps on ***.

FAILURE: Build failed with an exception.

* What went wrong:
Task 'assembleDebug' not found in root project 'android'.
* Try:
Run gradlew tasks to get a list of available tasks. 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 ***
BUILD FAILED in 824ms
ProcessException: Process exited abnormally:

FAILURE: Build failed with an exception.

* What went wrong:
Project 'app' not found in root project 'android'.

* 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 ***

BUILD FAILED in 801ms
Exited (sigterm)

 

Флаттер доктор все в порядке:

 Doctor summary (to see all details, run flutter doctor -v):
[√] Flutter (Channel stable, 2.5.1, on Microsoft Windows [Versión 10.0.19043.1237], locale es-EC)
[√] Android toolchain - develop for Android devices (Android SDK version 31.0.0)
[√] Chrome - develop for the web
[√] Android Studio (version 2020.3)
[√] VS Code (version 1.60.1)
[√] Connected device (3 available)

• No issues found!
 

Есть какие-нибудь предложения? пожалуйста, помогите.