When I try to debug my Flutter application in vscode it shows an error, but when I launch my app in Android Studio it works correctly.
This is the error it shows:
Launching lib\main.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)
Flutter doctor everything is OK:
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!
Any suggestion? please help.