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
I create a new app and add Guardian.Android package and the app does not build.
I got this error Failed to resolve: com.squareup.okhttp3:okhttp-bom:4.10.0
I took time to investigate. The package prevents compilation with newer versions of AGP. I saw that okhttp-bom was added to the dependencies in 0.7 but I think it was not added properly.
To my understanding, you have to import a bom package using the platform keyword: implementation platform('com.squareup.okhttp3:okhttp-bom:4.10.0')
Reproduction
Detail the steps taken to reproduce this error, what was expected, and whether this issue can be reproduced consistently or if it is intermittent.
Where applicable, please include:
Create a fresh app with Android Studio
Add implementation("com.auth0.android:guardian:0.8.0") to the dependencies
Sync gradle
Error
Unresolved dependencies
No matching variant of com.squareup.okhttp3:okhttp-bom:4.10.0 was found. The consumer was configured to find a library for use during runtime, preferably optimized for Android, as well as attribute 'com.android.build.api.attributes.AgpVersionAttr' with value '8.5.1', attribute 'com.android.build.api.attributes.BuildTypeAttr' with value 'debug', attribute 'org.jetbrains.kotlin.platform.type' with value 'androidJvm' but:
Variant 'apiElements':
Incompatible because this component declares a platform for use during compile-time and the consumer needed a library for use during runtime
Other compatible attributes:
Doesn't say anything about com.android.build.api.attributes.AgpVersionAttr (required '8.5.1')
Doesn't say anything about com.android.build.api.attributes.BuildTypeAttr (required 'debug')
Doesn't say anything about its target Java environment (preferred optimized for Android)
Doesn't say anything about org.jetbrains.kotlin.platform.type (required 'androidJvm')
Variant 'enforcedApiElements':
Incompatible because this component declares an enforced platform for use during compile-time and the consumer needed a library for use during runtime
Other compatible attributes:
Doesn't say anything about com.android.build.api.attributes.AgpVersionAttr (required '8.5.1')
Doesn't say anything about com.android.build.api.attributes.BuildTypeAttr (required 'debug')
Doesn't say anything about its target Java environment (preferred optimized for Android)
Doesn't say anything about org.jetbrains.kotlin.platform.type (required 'androidJvm')
Variant 'enforcedRuntimeElements' declares a component for use during runtime:
Incompatible because this component declares an enforced platform and the consumer needed a library
Other compatible attributes:
Doesn't say anything about com.android.build.api.attributes.AgpVersionAttr (required '8.5.1')
Doesn't say anything about com.android.build.api.attributes.BuildTypeAttr (required 'debug')
Doesn't say anything about its target Java environment (preferred optimized for Android)
Doesn't say anything about org.jetbrains.kotlin.platform.type (required 'androidJvm')
Variant 'runtimeElements' declares a component for use during runtime:
Incompatible because this component declares a platform and the consumer needed a library
Other compatible attributes:
Doesn't say anything about com.android.build.api.attributes.AgpVersionAttr (required '8.5.1')
Doesn't say anything about com.android.build.api.attributes.BuildTypeAttr (required 'debug')
Doesn't say anything about its target Java environment (preferred optimized for Android)
Doesn't say anything about org.jetbrains.kotlin.platform.type (required 'androidJvm')
Environment
com.auth0.android:guardian:0.8.0
Gradle 8.7
AGP 8.5.1
Android minSdkVersion 28
The text was updated successfully, but these errors were encountered:
Hello,
Thank you for raising this issue. While I understand that there is an existing change that could potentially fix this specific error, it seems that the greater issue is actually incompatibility with gradle 8.7 . Currently, it appears another package com.auth0.gradle.oss-library.android does not support gradle versions later than 6.9.4 .
Could you please confirm if the build of the SDK works if you are using an older version of gradle?
Description
I create a new app and add Guardian.Android package and the app does not build.
I got this error
Failed to resolve: com.squareup.okhttp3:okhttp-bom:4.10.0
I took time to investigate. The package prevents compilation with newer versions of AGP. I saw that
okhttp-bom
was added to the dependencies in 0.7 but I think it was not added properly.To my understanding, you have to import a bom package using the platform keyword:
implementation platform('com.squareup.okhttp3:okhttp-bom:4.10.0')
Reproduction
Detail the steps taken to reproduce this error, what was expected, and whether this issue can be reproduced consistently or if it is intermittent.
Where applicable, please include:
implementation("com.auth0.android:guardian:0.8.0")
to the dependenciesError
Unresolved dependencies
No matching variant of com.squareup.okhttp3:okhttp-bom:4.10.0 was found. The consumer was configured to find a library for use during runtime, preferably optimized for Android, as well as attribute 'com.android.build.api.attributes.AgpVersionAttr' with value '8.5.1', attribute 'com.android.build.api.attributes.BuildTypeAttr' with value 'debug', attribute 'org.jetbrains.kotlin.platform.type' with value 'androidJvm' but:
Environment
The text was updated successfully, but these errors were encountered: