3

This is the error while building the gradle.

[![Execution failed for task ':app:checkDebugAarMetadata'.
> Could not resolve all files for configuration ':app:debugRuntimeClasspath'.
   > Could not find com.pierfrancescosoffritti.androidyoutubeplayer:core:10.0.5.
     Searched in the following locations:
       - https://dl.google.com/dl/android/maven2/com/pierfrancescosoffritti/androidyoutubeplayer/core/10.0.5/core-10.0.5.pom
       - https://repo.maven.apache.org/maven2/com/pierfrancescosoffritti/androidyoutubeplayer/core/10.0.5/core-10.0.5.pom
     Required by:
         project :app

Possible solution:
 - Declare repository providing the artifact, see the documentation at https://docs.gradle.org/current/userguide/declaring_repositories.html

enter image description here

  • AFAIK, some libraries are not included in `mavenCentral()` so you may have to look for another library. I'd assume you already have `mavenCentral()` since it's included by default for recent AS versions. – David Lee Jul 03 '21 at 07:44

3 Answers3

1

did you add mavenCentral()?please replace mavenCentral() instead of jcenter

safa
  • 37
  • 5
0

The library is not maintained if you look at the repo on github the last commit was on Nov 11, 2019. So the maintainer has probably not published the library on mavenCentral. I suggest you download or clone the repo from Github and use it as a module in your project, or generate a jar or aar and use it as a locale library.

sitatech
  • 1,311
  • 11
  • 17
0

Add implementation fileTree(dir: "libs", include: ["*.jar"]) to your app level module dependency

  • Your answer could be improved with additional supporting information. Please [edit] to add further details, such as citations or documentation, so that others can confirm that your answer is correct. You can find more information on how to write good answers [in the help center](/help/how-to-answer). – Community Sep 23 '21 at 12:20
  • That's not going to work. They're not trying to find a .jar dependency, they're trying to download one off Maven. – Ryan M Sep 23 '21 at 15:08