Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Extrenal Dependency Manager fails the development build #3712

Open
Martinecko30 opened this issue Dec 19, 2024 · 7 comments
Open

Extrenal Dependency Manager fails the development build #3712

Martinecko30 opened this issue Dec 19, 2024 · 7 comments

Comments

@Martinecko30
Copy link

[REQUIRED] Step 1: Describe your environment

  • Unity version: 6000.0.31f and 6000.0.29f1
  • Google Mobile Ads Unity plugin version: 9.5.0
  • Plugin installation method: .unitypackage import
  • Platform: Unity Editor
  • Platform OS version: Windows 10 (eg iOS 10, Android 9)
  • Any specific devices issue occurs on: None
  • Mediation ad networks used, and their versions: Default AdMob

[REQUIRED] Step 2: Describe the problem

Steps to reproduce:

Download Unity Google Play Games plugin (ver. 2.0.0) with this plugin, now the External Dependency Manager will not allow development builds and will throw errors:

[pram:13.096][err] FAILURE: Build failed with an exception.
[pram:13.096][err]
[pram:13.096][err] * What went wrong:
[pram:13.096][err] Execution failed for task ':launcher:mergeLibDexDebug'.
[pram:13.096][err] > Could not resolve all files for configuration ':launcher:debugRuntimeClasspath'.
[pram:13.096][err] > Failed to transform classes.jar (project :unityLibrary) to match attributes {artifactType=android-dex, com.android.build.api.attributes.AgpVersionAttr=8.3.0, com.android.build.api.attributes.BuildTypeAttr=debug, com.android.build.gradle.internal.attributes.VariantAttr=debug, dexing-component-attributes=ComponentSpecificParameters(minSdkVersion=23, debuggable=true, enableCoreLibraryDesugaring=false, enableGlobalSynthetics=true, enableApiModeling=false, dependenciesClassesAreInstrumented=false, asmTransformComponent=null, useJacocoTransformInstrumentation=false, enableDesugaring=true, needsClasspath=true, useFullClasspath=false, componentIfUsingFullClasspath=null), org.gradle.libraryelements=jar, org.gradle.usage=java-runtime}.
[pram:13.096][err] > Could not resolve all files for configuration ':launcher:debugRuntimeClasspath'.
[pram:13.096][err] > No variants of com.google.games:gpgs-plugin-support:2.0.0 match the consumer attributes:
[pram:13.096][err] - com.google.games:gpgs-plugin-support:2.0.0 configuration runtime declares a library for use during runtime:
[pram:13.096][err] - Incompatible because this component declares a component, as well as attribute 'artifactType' with value 'srcaar' and the consumer needed a component, as well as attribute 'artifactType' with value 'android-classes-jar'
[pram:13.096][err] - Other compatible attributes:
[pram:13.096][err] - Doesn't say anything about com.android.build.api.attributes.AgpVersionAttr (required '8.3.0')
[pram:13.096][err] - Doesn't say anything about com.android.build.api.attributes.BuildTypeAttr (required 'debug')
[pram:13.096][err] - Doesn't say anything about dexing-component-attributes (required 'ComponentSpecificParameters(minSdkVersion=23, debuggable=true, enableCoreLibraryDesugaring=false, enableGlobalSynthetics=true, enableApiModeling=false, dependenciesClassesAreInstrumented=false, asmTransformComponent=null, useJacocoTransformInstrumentation=false, enableDesugaring=true, needsClasspath=true, useFullClasspath=false, componentIfUsingFullClasspath=null)')
[pram:13.096][err] - Doesn't say anything about its target Java environment (preferred optimized for Android)
[pram:13.096][err]

Relevant Code:

None, you just need to try making a development Android build and it will fail.

@dipupo6
Copy link

dipupo6 commented Dec 19, 2024

I also encountered this error recently, reverting target API Level from 35 back to 34 helps me build for now. I initially thought it was because I'm using a fairly old Unity version (2020.x.x), but seeing now that the error occurs on the latest Unity version, probably means it's a dependency conflict issue.

@Martinecko30
Copy link
Author

Very well might be!

You seem to find a better fix than I do, but unfortunately I need to have it set to API 35 as that's where I test it on.

For anyone else, you can uncheck the External Dependency Manager from Google ads plugin when importing and use the one provided in Google Play Games plugin

@dipupo6
Copy link

dipupo6 commented Dec 19, 2024

For anyone else, you can uncheck the External Dependency Manager from Google ads plugin when importing and use the one provided in Google Play Games plugin

That works correctly?

@Martinecko30
Copy link
Author

I'm experiencing some Google Ads GUI errors but nothing is broken (yet).

Also, don't import it from the package manager as it won't work either. And there you can't resolve the Extrenal dependency Manager as it is bound as dependency to both of the plugins

@Shamsad-Madovergames
Copy link

Very well might be!

You seem to find a better fix than I do, but unfortunately I need to have it set to API 35 as that's where I test it on.

For anyone else, you can uncheck the External Dependency Manager from Google ads plugin when importing and use the one provided in Google Play Games plugin

Thanks. It worked like charm

@NVentimiglia
Copy link
Member

We recommend using Gradle for android builds

https://developers.google.com/admob/unity/android

@Martinecko30
Copy link
Author

We recommend using Gradle for android builds

https://developers.google.com/admob/unity/android

I don't see how this is relevant? The Extrenal Dependency Manager already uses Gradle to build the project. The issue is bundled into the provided plugin, not the project. (This is confirmed by other users experiencing similar issue)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

4 participants