This is what I'm receiving from Android Studio, but I don't know how to fix this in the latest version.
A problem occurred evaluating project ':app'.
> Failed to apply plugin [id 'com.android.internal.version-check']
> Minimum supported Gradle version is 5.6.4.
Edit: I changed the gradle-wrapper.properties to
distributionUrl=https\://services.gradle.org/distributions/gradle-5.6.4-all.zip
And now also went to File/Settings/Build, Execution, Deployment/Gradle, and changed the Gradle User Home to a gradle-5.6.4 that I downloaded.
But now, I'm receiving this:
Finished with error: Gradle task assembleDebug failed with exit code 1
Related
this is happening when running the flutter default app.
build is failing with an exception.
in the img it may be showing evaluating :app but now it is also showing problem occured evaluating project android.
I didn't change anything in my Flutter application and it was running perfectly but when i tried running on real device i got this exception
FAILURE: Build failed with an exception.
* What went wrong:
Execution failed for task ':bluetoothadapter:compileDebugJavaWithJavac'.
> Could not find tools.jar. Please check that C:\Program Files\Java\jre1.8.0_321 contains a valid JDK installation.
BUILD FAILED in 13s
Exception: Gradle task assembleDebug failed with exit code 1
Check out this post for a workaround:
tools.jar seems to be not in Android Studio classpath on Windows 8
It seems, the tools.jar is not present on every version of Java 8 anymore. Also make sure to use a JDK and not a pure JRE for development.
Maybe it is worth downloading a current version of the JDK from https://adoptopenjdk.net
I am trying to code an app for the first time with flutter in vs code and I am getting this error,
FAILURE: Build failed with an exception.
Where:
Build file 'C:\Users\ajgoc\Desktop\Badges\badges_gram\buddies_gram-master\android\build.gradle' line: 29
What went wrong:
A problem occurred evaluating root project 'android'.
A problem occurred configuring project ':app'.
Failed to notify project evaluation listener.
> 'org.gradle.api.file.DirectoryProperty org.gradle.api.file.ProjectLayout.directoryProperty(org.gradle.api.provider.Provider)'
Exception: Gradle task assembly debug failed with exit code 1
I have tried a couple of things to fix it but haven't gotten anything to work. The app will still load in the emulator but it is an older version of the app. Here is what my gradle-wrapper.poperties and build.gradle files look like.
gradle-wrapper.poperties
build.gradle
flutter doctor -v output
I imported a flutter project from GitHub. when I tried to run it I had this error(no errors in code). I could not figure out what this error is all about and I keep getting this error for every project which I import from GitHub.Please help me out!
This is the error:
Exception in thread "main" java.util.zip.ZipException: error in opening zip file.
Gradle threw an error while trying to update itself. Retrying the update...
Finished with error: Gradle task assembleDebug failed with exit code 1.
It's kinda common problem when you get a project from github and I solved it once with this answer.
Copy paste from there:
Open your Android Studio preferences(Command + ',') and go to
Languages and Frameworks -> Dart
Check "Enable Dart support for the project your_project_name"
In "Dart SDK path" click in "…" and navigate to flutter SDK directory.
Under that directory you'll find "bin/cache/dart-sdk". This is the
dart sdk path you should use.
Click "Apply"
flutter packages get
flutter run
I'm trying to run my project , I am getting error
Launching lib/main.dart on Android SDK built for x86 in debug mode...
Running Gradle task 'assembleDebug'...
Error: Could not find or load main class org.gradle.wrapper.GradleWrapperMain
Exception: Gradle task assembleDebug failed with exit code 1
It is hard to know the problem with so little information. One general approach with worked to me was performing:
flutter clean
Try to run.
If it does not run delete the jar file under android/gradle/properties to recompile it and try again.