Failed to resolve: com.github.barteksc:android-pdf-viewer:3.2.0-beta.1
The version of Android Studio is 2024.1.2. Can not sync success,show the error : Failed to resolve: com.github.barteksc:android-pdf-viewer:3.2.0-beta.1
use below repo maven { url "https://repository.liferay.com/nexus/content/repositories/public/" }
Isn't working, continue failing
settings.gradle file
dependencyResolutionManagement {
repositoriesMode.set(RepositoriesMode.FAIL_ON_PROJECT_REPOS)
repositories {
google()
mavenCentral()
gradlePluginPortal()
maven { url 'https://jitpack.io' }
maven { url "https://repository.liferay.com/nexus/content/repositories/public/" }
}
}
i use and its work!
not working
The fix proposed works. Can someone explain why we have to link to another repository to get the latest version? Shouldn't this be better done as a GitHub package ?
The version of Android Studio is 2024.1.2. Can not sync success,show the error : Failed to resolve: com.github.barteksc:android-pdf-viewer:3.2.0-beta.1
Use this one . it works.
implementation 'com.github.mhiew:android-pdf-viewer:3.2.0-beta.1'
settings.gradle file
dependencyResolutionManagement { repositoriesMode.set(RepositoriesMode.FAIL_ON_PROJECT_REPOS) repositories { google() mavenCentral() gradlePluginPortal() maven { url 'https://jitpack.io' } maven { url "https://repository.liferay.com/nexus/content/repositories/public/" } } }i use and its work!
i also use this and now it's perfectly working
Android Studio 版本是 2024.1.2。无法同步成功,显示错误:无法解析:com.github.barteksc:android-pdf-viewer:3.2.0-beta.1
使用这个。它有效。
implementation 'com.github.mhiew:android-pdf-viewer:3.2.0-beta.1'
thank you
use below repo maven { url "https://repository.liferay.com/nexus/content/repositories/public/" }
Using this repo in project level build.gradle file, I was able to address this issue.
worked for some time but not working now
use below repo maven { url "https://repository.liferay.com/nexus/content/repositories/public/" }
Thanks @hhajiloo . This worked like a charm. Not just android-pdf-viewer but few other obsolete dependencies were also found in this repo.
Failed to resolve: com.firebase:firebase-jobdispatcher:0.8.5
Failed to resolve: xyz.belvi.mobilevision:barcodescanner:2.0.3
Failed to resolve: net.opacapp:multiline-collapsingtoolbar:27.1.1
Failed to resolve: com.journeyapps:zxing-android-embedded:3.2.0
Use these lines, copy and paste, and it will work for you. Then pray for me.
dependencyResolutionManagement { repositoriesMode.set(RepositoriesMode.FAIL_ON_PROJECT_REPOS) repositories { google() mavenCentral() gradlePluginPortal() maven { url "https://jitpack.io/" } maven { url "https://repository.liferay.com/nexus/content/repositories/public/" } maven { url "https://jcenter.bintray.com/" } } }
Use this one . it works.
implementation 'com.github.mhiew:android-pdf-viewer:3.2.0-beta.1'
I get these build errors with the above library:
Execution failed for task ':app:checkDebugDuplicateClasses'.
A failure occurred while executing com.android.build.gradle.internal.tasks.CheckDuplicatesRunnable Duplicate class android.support.v4.app.AppLaunchChecker found in modules support-compat-28.0.0.aar -> support-compat-28.0.0-runtime (com.android.support:support-compat:28.0.0) and support-core-utils-26.1.0.aar -> support-core-utils-26.1.0-runtime (com.android.support:support-core-utils:26.1.0) Duplicate class android.support.v4.app.FrameMetricsAggregator found in modules support-compat-28.0.0.aar -> support-compat-28.0.0-runtime (com.android.support:support-compat:28.0.0) and support-core-utils-26.1.0.aar -> support-core-utils-26.1.0-runtime (com.android.support:support-core-utils:26.1.0) Duplicate class android.support.v4.app.FrameMetricsAggregator$FrameMetricsApi24Impl found in modules support-compat-28.0.0.aar -> support-compat-28.0.0-runtime (com.android.support:support-compat:28.0.0) and support-core-utils-26.1.0.aar -> support-core-utils-26.1.0-runtime (com.android.support:support-core-utils:26.1.0)
Execution failed for task ':app:checkDebugDuplicateClasses'.
Try to clean and rebuild the project
I solved it by using this fork version, thanks:
implementation 'com.github.mhiew:android-pdf-viewer:3.2.0-beta.3'
dependencyResolutionManagement { repositoriesMode.set(RepositoriesMode.FAIL_ON_PROJECT_REPOS) repositories { google() mavenCentral() maven { url = uri("https://jitpack.io") } // maven { url = uri("https://repository.liferay.com/nexus/content/repositories/public/") } gradlePluginPortal() } }
allprojects { repositories { google() mavenCentral() jcenter() maven { url 'https://jitpack.io' } }
subprojects { subproject ->
configurations.all {
resolutionStrategy.eachDependency { details ->
if (details.requested.group == 'com.github.barteksc' &&
details.requested.name == 'android-pdf-viewer') {
details.useTarget 'com.github.mhiew:android-pdf-viewer:3.2.0-beta.2'
}
}
}
}
}
I tried adding the subprojects block inside allprojects, and it worked.
use below repo maven { url "https://repository.liferay.com/nexus/content/repositories/public/" }
This solution works for me too, very helpful thanks a lot