1

Improperly formatted define flag: Inc\VMwareCorp\Documents\flutter\test2\lib\main.dart

FAILURE: Build failed with an exception.

  • Where: Script 'C:\src\flutter\packages\flutter_tools\gradle\flutter.gradle' line: 1005

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

Process 'command 'C:\src\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 7m 12s Exception: Gradle task assembleDebug failed with exit code 1 Exited (sigterm)

No errors coming from flutter doctor -v

4 Answers 4

1

The issue was finally resolved after shortening the execution path of my flutter project as I changed it from this C:\Users\aesmail\OneDrive - Comp, Inc\CompCorp\Documents\flutter\hello_world

to this: C:\Users\aesmail\flutter_application_1 from

Sign up to request clarification or add additional context in comments.

Comments

0

try running flutter pub get and if it doesn’t work, connect to a vpn and try to run it again. if problem persists, please show a sample of your code

1 Comment

flutter pub get works without an issue My code is the test code generated when you create a new flutter project. Works completely fine on chrome and edge but the issue is just encountered when I get to run the code on the android emulator
0

have you accepted your flutter sdk licenses? if not try a checking the licenses or try this navigate to this pth on your android studio

Tools > SDK Manager > Appareance & Behavior > System Setting> Android SDK > SDK Tools > Android SDK Command-line Tools (apply)

then run this commands when you are done and send the output if it still continues

flutter doctor --android-licenses flutter doctor -v

Comments

0

enter link description here

Finally, the correct one!!, I was trying with different SDK and others i was having the same error

flutter.gradle' line: 1005

But the reason is the location of the project, like Ahmed Esmail I was using the project in the path with

C:\Users\wborbon\OneDrive - ******, Inc

Comments

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.