fluttercommunity / fluttercommunity/community
A problem occurred configuring project
- Dominant language
- No language data
- Stars
- 1.7k
- Forks
- 128
- PR merge metrics
- No merged PRs in 30d
Description
I have been trying to build new apk since and i don't know what happened it has been working fine up until now
`flutter build apk
You are applying Flutter's app_plugin_loader Gradle plugin imperatively using the apply script method, which is deprecated and will be removed in a future release. Migrate to applying Gradle plugins with the declarative plugins block: https://flutter.dev/go/flutter-gradle-plugin-apply
You are applying Flutter's main Gradle plugin imperatively using the apply script method, which is deprecated and will be removed in a future release. Migrate to applying Gradle plugins with the declarative plugins block: https://flutter.dev/go/flutter-gradle-plugin-apply
FAILURE: Build failed with an exception.
* What went wrong:
A problem occurred configuring project ':camera_android'.
> Could not open proj generic class cache for build file 'C:\Users\Swiftluxe\AppData\Local\Pub\Cache\hosted\pub.dev\camera_android-0.10.9+11\android\build.gradle' (C:\Users\Swiftluxe\.gradle\caches\7.5\scripts\39ew46josl314gzmcfusqehaz).
> BUG! exception in phase 'semantic analysis' in source unit '_BuildScript_' Unsupported class file major version 65
> Failed to notify project evaluation listener.
> Could not get unknown property 'android' for project ':camera_android' of type org.gradle.api.Project.
> Could not find method implementation() for arguments [project ':flutter_plugin_android_lifecycle'] on object of type org.gradle.api.internal.artifacts.dsl.dependencies.DefaultDependencyHandler.
> Could not get unknown property 'android' for project ':camera_android' of type org.gradle.api.Project.
* 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 11s
Running Gradle task 'assembleRelease'... 12.3s
┌─ Flutter Fix ───────────────────────────────────────────────────────────────────────────────────────┐
│ [!] Your project's Gradle version is incompatible with the Java version that Flutter is using for │
│ Gradle. │
│ │
│ If you recently upgraded Android Studio, consult the migration guide at │
│ docs.flutter.dev/go/android-java-gradle-error. │
│ │
│ Otherwise, to fix this issue, first, check the Java version used by Flutter by running `flutter │
│ doctor --verbose`. │
│ │
│ Then, update the Gradle version specified in │
│ C:\github\Swiftluxe_app\android\gradle\wrapper\gradle-wrapper.properties to be compatible with that │
│ Java version. See the link below for more information on compatible Java/Gradle versions: │
│ https://docs.gradle.org/current/userguide/compatibility.html#java │
│ │
│ │
└─────────────────────────────────────────────────────────────────────────────────────────────────────┘
Gradle task assembleRelease failed with exit code 1`
Contributor guide
No contributing guide indexed for this repository
Assessment
This issue has not been assessed yet.