You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Launching lib/main.dart on sdk gphone64 arm64 in debug mode...
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:
Could not determine the dependencies of task ':app:mergeDebugAssets'.
> Could not resolve all task dependencies for configuration ':app:debugRuntimeClasspath'.
> Could not resolve project :unityLibrary.
Required by:
project :app
project :app > project :flutter_unity_widget
> No matching configuration of project :unityLibrary was found. The consumer was configured to find a runtime of a component, preferably optimized for Android, as well as attribute 'com.android.build.api.attributes.BuildTypeAttr' with value 'debug', attribute 'com.android.build.api.attributes.AgpVersionAttr' with value '7.1.2', attribute 'org.jetbrains.kotlin.platform.type' with value 'androidJvm' but:
- None of the consumable configurations have attributes.
* 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 6s
Error: Gradle task assembleDebug failed with exit code 1
Exited (1).
Steps to Reproduce:
Run the Flutter project with flutter run.
Observe the build process and error message.
Expected Behavior:
The project should build and run successfully without any Gradle configuration issues.
Actual Behavior:
The build fails with the error message above.
Environment:
Flutter version: 3.22.0
Unity version: latest
Android Studio version: Android Studio Jellyfish | 2023.3.1
Gradle version: 7.4.0
Additional Context:
This issue seems to be related to the deprecated method of applying Flutter's Gradle plugins. Any guidance on resolving this issue would be appreciated.
The text was updated successfully, but these errors were encountered:
The gradle apply method is just a warning, it does not throw or cause any errors.
Maybe you could run in to errors if you add modifications in the new style without upgrading the existing files.
The example uses Gradle 7.2 with AGP 7.1.2 because that is what Unity 2022.3.x is officially compatible with.
You can use higher gradle versions, but that requires manually changing files like gradle-wrapper.properties and build.gradle.
Which files did you change to configure Gradle 8?
Unity 6 actually supports gradle 8 out of the box, but the android export isn't compatible with the current version of this plugin.
Issue Description:
When trying to run the example app of https://pub.dev/packages/flutter_unity_widget, I encountered the following error during the build process:
Steps to Reproduce:
flutter run
.Expected Behavior:
The project should build and run successfully without any Gradle configuration issues.
Actual Behavior:
The build fails with the error message above.
Environment:
Additional Context:
This issue seems to be related to the deprecated method of applying Flutter's Gradle plugins. Any guidance on resolving this issue would be appreciated.
The text was updated successfully, but these errors were encountered: