hey i'm trying to create a webview in my Flutter app but when i installing flutter_webview plugin i got this problems with gradle :
FAILURE: Build failed with an exception.
What went wrong:
Execution failed for task ':app:transformClassesWithMultidexlistForDebug'.
com.android.build.api.transform.TransformException: Error while generating the main dex list.
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 3s
i had try with multi version in flutter_webview and the same problem
Related
whenever i run my app it gives me this error FAILURE: Build failed with an exception.
What went wrong:
Could not update C:\Users\abdou.gradle\caches\7.4\file-changes\last-build.bin
C:\Users\abdou.gradle\caches\7.4\file-changes\last-build.bin (Access is denied)
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 1m 14s
Exception: Gradle task assembleDebug failed with exit code 1
. My app was working the day before just fine.
I tried to create a new flutter project and move all my files there and rerun the project it didn't work .
Launching lib\main.dart on Mi A1 in debug mode...
FAILURE: Build failed with an exception.
What went wrong:
Execution failed for task ':app:processDebugResources'.
A failure occurred while executing com.android.build.gradle.internal.tasks.Workers$ActionFacade
Android resource linking failed
C:\Users\anand.gradle\caches\transforms-2\files-2.1\9d2250f2160023e86dcf90b2c8c1bc31\core-1.7.0-beta01\res\values\values.xml:105:5-114:25: AAPT: error: resource android:attr/lStar not found.
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 1m 57s
The build failed likely due to AndroidX incompatibilities in a plugin. The tool is about to try using Jetifier to solve the incompatibility.
Building plugin admob_flutter...
√ Built build\app\outputs\repo.
Building plugin agora_rtc_engine...
FAILURE: Build failed with an exception.
Where:
Build file 'C:\src\flutter.pub-cache\hosted\pub.dartlang.org\agora_rtc_engine-4.0.7\android\build.gradle' line: 29
What went wrong:
A problem occurred evaluating root project 'agora_rtc_engine'.
Plugin with id 'com.android.library' not found.
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 2s
Exception: The plugin agora_rtc_engine could not be built due to the issue above.
Exited (sigterm)
I created a new app.
Added audioplayers flutter package from https://pub.dev/packages/audioplayers.
Shows an error from Android Embedding. I followed the instructions https://flutter.dev/go/android-project-migration.
Now I get this error:
FAILURE: Build completed with 2 failures.
1: Task failed with an exception.
-----------
* Where:
Build file 'C:\src\flutter\flutter\.pub-cache\hosted\pub.dartlang.org\audioplayers-0.17.1\android\build.gradle' line: 23
* What went wrong:
A problem occurred evaluating project ':audioplayers'.
> Plugin with id 'kotlin-android' not found.
* 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.
==============================================================================
2: Task failed with an exception.
-----------
* What went wrong:
A problem occurred configuring project ':audioplayers'.
> compileSdkVersion is not specified.
* 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 3s
Exception: Gradle task assembleDebug failed with exit code 1
Then I followed https://github.com/react-native-webview/react-native-webview/issues/1407 thread to do what suggested.
Now I'm getting this error:
FAILURE: Build failed with an exception.
Where:
Build file 'C:\src\flutter\flutter.pub-cache\hosted\pub.dartlang.org\audioplayers-0.17.1\android\build.gradle' line: 49
What went wrong:
A problem occurred evaluating project ':audioplayers'.
Could not get unknown property 'kotlin_version' for object of type org.gradle.api.internal.artifacts.dsl.dependencies.DefaultDependencyHandler.
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 4s
Exception: Gradle task assembleDebug failed with exit code 1
I'm very new in android studio development, it drives me crazy with these configurations. Thank you very much.
For those who came up with the same problem I have. The project I'm working came from Git and I think that project wasn't updated for Android Embedding v2 so I got the first error.
Now in the second error, all I did was to read other's bug fixes (not officially).
Adding the dependencies and kotlin-version (1.4.20) needed for the main package(audioplayers). C:\flutter\flutter.pub-cache\hosted\pub.dartlang.org\audioplayers-0.17.1\android\
Making the android project's app build.gradle>defaultConfig>minSdkVersion to 23 (from 16)
Use pub get and update in pubspec.yaml.
At first when I installed and ran the Android Studio the app ran perfectly, then after two days for some reason this is happening. Please help me fix this. Thanks
Launching lib\main.dart on GM1910 in debug mode...
Running Gradle task 'assembleDebug'...
Not resetting hidden file - C:\Users\zahin\AndroidStudioProjects\project1\build\app\intermediates\flutter\debug\flutter_assets\assets\ss\Thumbs.db
FAILURE: Build failed with an exception.
* What went wrong:
Execution failed for task ':app:signingConfigWriterDebug'.
> java.nio.file.AccessDeniedException: C:\Users\zahin\AndroidStudioProjects\project1\build\app\intermediates\signing_config\debug\out\signing-config.json
* 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 4s
Exception: Gradle task assembleDebug failed with exit code 1
Use flutter clean or remove the build folder on your project root then try again.
Flutter,android
I can't understand.
Error has occured, when I upgrading version in 'pubspec.yaml'
version: 1.0.1+2 was no problem. build done!
but, 1.0.2+3, 1.0.3+4, .. ERROR!!!! build failed!!
even though 1.0.0+1.. error too..
What should I do?
no problem
error screenshot
error info is
FAILURE: Build failed with an exception.
* What went wrong:
Execution failed for task ':app:compileDebugJavaWithJavac'.
> java.lang.NullPointerException (no error message)
* 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 13s
Finished with error: Gradle task assembleDebug failed with exit code 1