Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

How to solve this issue Execution failed for task ':app:compileFlutterBuildDebug'

I have a already try multiple methods but failed,

FAILURE: Build failed with an exception.

  • Where: Script 'C:\Users\IMBA\flutter\packages\flutter_tools\gradle\flutter.gradle' line: 1070

  • What went wrong: Execution failed for task ':app:compileFlutterBuildDebug'.

Process 'command 'C:\Users\IMBA\flutter\bin\flutter.bat'' finished with non-zero exit value 1

  • 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 16s Exception: Gradle task assembleDebug failed with exit code 1

give me a prefect suggestion

like image 331
kiran Kshirsagar Avatar asked Nov 04 '25 07:11

kiran Kshirsagar


2 Answers

Update the packages in your project. Check if there is any package that needs to be updated.

I've update the package flutter_settings_ui: ^2.0.1 to latest and it solved the issues.

like image 154
Nitish Mishra Avatar answered Nov 05 '25 22:11

Nitish Mishra


You need this line:

import 'package:flutter/material.dart' show BuildContext, Key, MaterialApp, StatelessWidget, Widget, runApp;
like image 28
احمد شاكر Avatar answered Nov 05 '25 22:11

احمد شاكر



Donate For Us

If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!