I'm attempting to run a Flutter application, but keep getting this output in the console:
Launching lib/main.dart on Android SDK built for x86 in debug mode...
FAILURE: Build failed with an exception.
* What went wrong:
Execution failed for task ':app:desugarDebugFileDependencies'.
> A failure occurred while executing com.android.build.gradle.internal.tasks.Workers$ActionFacade
> /home/(username)/Android/Sdk/build-tools/28.0.3/core-lambda-stubs.jar
* 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 41s
Gradle task assembleDebug failed with exit code 1
Exited (sigterm)
Sometimes, it might be the slightest error in your $JAVA_HOME configuration which is tabbing this error, just fix it like this: Double-check the build of your app. gradle.
I found that my build-tools/28.0.3/ directory was missing many files, probably from a failed install. I used the SDK manager in android studio to remove 28.0.3 and then reinstalled it and the files are there now. Show activity on this post. Deleting the /build-tools/28.0.3 folder and rerunning the app worked for me!
Double-check the build of your app. gradle. It adds an extra.jar file as a dependency that didn’t exist in your project. As a result, remove that and you’re back on track! If you happen to be running the latest version of Android Studio or the Canary Flavor of the IDE then maybe the issue is there with the certain sdkVersions of your project.
I'm using linux mint,in my case I went to: /home/(username)/Android/Sdk/build-tools/ and delete the folder "28.0.3". Then run the application and android studio reinstall this folder, and the application works correctly without the error mentioned.
I found that my build-tools/28.0.3/ directory was missing many files, probably from a failed install. I used the SDK manager in android studio to remove 28.0.3 and then reinstalled it and the files are there now.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With