Issue
Can anyone tell me what's wrong with Android Studio. I cannot run flutter projects. It returns the error showed in the picture.
Android Studio version: 3.6.3 Flutter version: 1.22.1 with Dart 2.10.1
The Error showed while executing main.dart:
Launching lib\main.dart on Android SDK built for x86 in debug mode... Running Gradle task 'assembleDebug'...
FAILURE: Build failed with an exception.
Where: Script 'C:\src\flutter\packages\flutter_tools\gradle\flutter.gradle' line: 41
What went wrong: A problem occurred evaluating script.
FlutterPlugin
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 23s Exception: Gradle task assembleDebug failed with exit code 1
Solution
Found the solution: I had to delete the cache file from .gradle folder and run project. And it worked.
Directory of the cache file: C:\user(username)\ .gradle
Answered By - Tariful Islam Abir
0 comments:
Post a Comment
Note: Only a member of this blog may post a comment.