Как разрешить использовать стороннюю библиотеку
ошибка такая
Failed to resolve: es.voghdev.pdfviewpager:library:1.1.0
Я в новый проект в android studio добавляю implementation 'es.voghdev.pdfviewpager:library:1.1.0'
и у меня
Starting Gradle Daemon...
Gradle Daemon started in 3 s 673 ms
> Task :app:clean
> Task :app:createDebugVariantModel
> Task :app:preBuild UP-TO-DATE
> Task :app:preDebugBuild UP-TO-DATE
> Task :app:mergeDebugNativeDebugMetadata NO-SOURCE
> Task :app:javaPreCompileDebug
> Task :app:checkDebugAarMetadata FAILED
> Task :app:generateDebugResValues
> Task :app:mapDebugSourceSetPaths FAILED
> Task :app:generateDebugResources
> Task :app:mergeDebugResources FAILED
> Task :app:packageDebugResources
> Task :app:createDebugCompatibleScreenManifests
> Task :app:extractDeepLinksDebug
> Task :app:processDebugMainManifest FAILED
> Task :app:parseDebugLocalResources
> Task :app:mergeDebugShaders
> Task :app:compileDebugShaders NO-SOURCE
> Task :app:generateDebugAssets UP-TO-DATE
> Task :app:mergeDebugAssets FAILED
> Task :app:processDebugJavaRes NO-SOURCE
> Task :app:mergeDebugJavaResource FAILED
> Task :app:checkDebugDuplicateClasses FAILED
> Task :app:desugarDebugFileDependencies FAILED
> Task :app:mergeDebugJniLibFolders
> Task :app:mergeDebugNativeLibs FAILED
> Task :app:validateSigningDebug
> Task :app:writeDebugAppMetadata
> Task :app:writeDebugSigningConfigVersions
FAILURE: Build completed with 9 failures.
1: Task failed with an exception.
-----------
* What went wrong:
Execution failed for task ':app:checkDebugAarMetadata'.
> Could not resolve all files for configuration ':app:debugRuntimeClasspath'.
> Could not find es.voghdev.pdfviewpager:library:1.1.0.
Searched in the following locations:
- https://dl.google.com/dl/android/maven2/es/voghdev/pdfviewpager/library/1.1.0/library-1.1.0.pom
- https://repo.maven.apache.org/maven2/es/voghdev/pdfviewpager/library/1.1.0/library-1.1.0.pom
Required by:
project :app
* 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.
==============================================================================
2: Task failed with an exception.
-----------
* What went wrong:
Execution failed for task ':app:mapDebugSourceSetPaths'.
> Could not resolve all files for configuration ':app:debugRuntimeClasspath'.
> Could not find es.voghdev.pdfviewpager:library:1.1.0.
Searched in the following locations:
- https://dl.google.com/dl/android/maven2/es/voghdev/pdfviewpager/library/1.1.0/library-1.1.0.pom
- https://repo.maven.apache.org/maven2/es/voghdev/pdfviewpager/library/1.1.0/library-1.1.0.pom
Required by:
project :app
* 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.
==============================================================================
3: Task failed with an exception.
-----------
* What went wrong:
Execution failed for task ':app:mergeDebugResources'.
> Could not resolve all files for configuration ':app:debugRuntimeClasspath'.
> Could not find es.voghdev.pdfviewpager:library:1.1.0.
Searched in the following locations:
- https://dl.google.com/dl/android/maven2/es/voghdev/pdfviewpager/library/1.1.0/library-1.1.0.pom
- https://repo.maven.apache.org/maven2/es/voghdev/pdfviewpager/library/1.1.0/library-1.1.0.pom
Required by:
project :app
* 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.
==============================================================================
4: Task failed with an exception.
-----------
* What went wrong:
Execution failed for task ':app:processDebugMainManifest'.
> Could not resolve all files for configuration ':app:debugRuntimeClasspath'.
> Could not find es.voghdev.pdfviewpager:library:1.1.0.
Searched in the following locations:
- https://dl.google.com/dl/android/maven2/es/voghdev/pdfviewpager/library/1.1.0/library-1.1.0.pom
- https://repo.maven.apache.org/maven2/es/voghdev/pdfviewpager/library/1.1.0/library-1.1.0.pom
Required by:
project :app
* 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.
==============================================================================
5: Task failed with an exception.
-----------
* What went wrong:
Execution failed for task ':app:mergeDebugAssets'.
> Could not resolve all files for configuration ':app:debugRuntimeClasspath'.
> Could not find es.voghdev.pdfviewpager:library:1.1.0.
Searched in the following locations:
- https://dl.google.com/dl/android/maven2/es/voghdev/pdfviewpager/library/1.1.0/library-1.1.0.pom
- https://repo.maven.apache.org/maven2/es/voghdev/pdfviewpager/library/1.1.0/library-1.1.0.pom
Required by:
project :app
* 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.
==============================================================================
6: Task failed with an exception.
-----------
* What went wrong:
Execution failed for task ':app:mergeDebugJavaResource'.
> Could not resolve all files for configuration ':app:debugRuntimeClasspath'.
> Could not find es.voghdev.pdfviewpager:library:1.1.0.
Searched in the following locations:
- https://dl.google.com/dl/android/maven2/es/voghdev/pdfviewpager/library/1.1.0/library-1.1.0.pom
- https://repo.maven.apache.org/maven2/es/voghdev/pdfviewpager/library/1.1.0/library-1.1.0.pom
Required by:
project :app
* 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.
==============================================================================
7: Task failed with an exception.
-----------
* What went wrong:
Execution failed for task ':app:checkDebugDuplicateClasses'.
> Could not resolve all files for configuration ':app:debugRuntimeClasspath'.
> Could not find es.voghdev.pdfviewpager:library:1.1.0.
Searched in the following locations:
- https://dl.google.com/dl/android/maven2/es/voghdev/pdfviewpager/library/1.1.0/library-1.1.0.pom
- https://repo.maven.apache.org/maven2/es/voghdev/pdfviewpager/library/1.1.0/library-1.1.0.pom
Required by:
project :app
* 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.
==============================================================================
8: Task failed with an exception.
-----------
* What went wrong:
Execution failed for task ':app:desugarDebugFileDependencies'.
> Could not resolve all files for configuration ':app:debugRuntimeClasspath'.
> Could not find es.voghdev.pdfviewpager:library:1.1.0.
Searched in the following locations:
- https://dl.google.com/dl/android/maven2/es/voghdev/pdfviewpager/library/1.1.0/library-1.1.0.pom
- https://repo.maven.apache.org/maven2/es/voghdev/pdfviewpager/library/1.1.0/library-1.1.0.pom
Required by:
project :app
* 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.
==============================================================================
9: Task failed with an exception.
-----------
* What went wrong:
Execution failed for task ':app:mergeDebugNativeLibs'.
> Could not resolve all files for configuration ':app:debugRuntimeClasspath'.
> Could not find es.voghdev.pdfviewpager:library:1.1.0.
Searched in the following locations:
- https://dl.google.com/dl/android/maven2/es/voghdev/pdfviewpager/library/1.1.0/library-1.1.0.pom
- https://repo.maven.apache.org/maven2/es/voghdev/pdfviewpager/library/1.1.0/library-1.1.0.pom
Required by:
project :app
* 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 23s
22 actionable tasks: 22 executed
Да может еще дело за перехода jcenter() на
mavenCentral()
jcenter() работало
Источник: Stack Overflow на русском