Error Failed to resolve recyclerview-v7 in Android Studio 3.2.1










0















I want to add this dependency in my build.gradle file :



implementation 'com.android.support:design:28.0.0'


when I add this and click on the Sync now, it gives me error :



Failed to resolve: recyclerview-v7


and this is my build.gradle file :



// Top-level build file where you can add configuration options common to 

all sub-projects/modules.

buildscript
repositories
google()
jcenter()

dependencies
classpath 'com.android.tools.build:gradle:3.2.1'

// NOTE: Do not place your application dependencies here; they belong
// in the individual module build.gradle files



allprojects
repositories
google()
jcenter()
mavenCentral()
mavenLocal()



apply plugin: 'com.android.library'

android
packagingOptions
exclude 'META-INF/NOTICE'



android
packagingOptions
exclude 'META-INF/LICENSE'



android
compileSdkVersion 28
buildToolsVersion "28.0.3"

defaultConfig
minSdkVersion 16
targetSdkVersion 28
versionCode 1
versionName "1.0"



dependencies
api project(':MapdroidClient')
api project(':UiUtil')
implementation 'org.slf4j:slf4j-api:1.7.25'
implementation 'com.github.ksoichiro:android-observablescrollview:1.6.0'
implementation 'com.nineoldandroids:library:2.4.0'
implementation 'org.osmdroid:osmdroid-android:5.6.4'
implementation 'com.android.support:support-v4:28.0.0'
implementation 'com.android.support:design:28.0.0'



I know that in my observablescrollview library, there is recyclerview dependency, but I don't know why i get this error.



I searched every where and none of solutions worked. Solutions like changing order of google() and jcenter() repositories ...










share|improve this question


























    0















    I want to add this dependency in my build.gradle file :



    implementation 'com.android.support:design:28.0.0'


    when I add this and click on the Sync now, it gives me error :



    Failed to resolve: recyclerview-v7


    and this is my build.gradle file :



    // Top-level build file where you can add configuration options common to 

    all sub-projects/modules.

    buildscript
    repositories
    google()
    jcenter()

    dependencies
    classpath 'com.android.tools.build:gradle:3.2.1'

    // NOTE: Do not place your application dependencies here; they belong
    // in the individual module build.gradle files



    allprojects
    repositories
    google()
    jcenter()
    mavenCentral()
    mavenLocal()



    apply plugin: 'com.android.library'

    android
    packagingOptions
    exclude 'META-INF/NOTICE'



    android
    packagingOptions
    exclude 'META-INF/LICENSE'



    android
    compileSdkVersion 28
    buildToolsVersion "28.0.3"

    defaultConfig
    minSdkVersion 16
    targetSdkVersion 28
    versionCode 1
    versionName "1.0"



    dependencies
    api project(':MapdroidClient')
    api project(':UiUtil')
    implementation 'org.slf4j:slf4j-api:1.7.25'
    implementation 'com.github.ksoichiro:android-observablescrollview:1.6.0'
    implementation 'com.nineoldandroids:library:2.4.0'
    implementation 'org.osmdroid:osmdroid-android:5.6.4'
    implementation 'com.android.support:support-v4:28.0.0'
    implementation 'com.android.support:design:28.0.0'



    I know that in my observablescrollview library, there is recyclerview dependency, but I don't know why i get this error.



    I searched every where and none of solutions worked. Solutions like changing order of google() and jcenter() repositories ...










    share|improve this question
























      0












      0








      0








      I want to add this dependency in my build.gradle file :



      implementation 'com.android.support:design:28.0.0'


      when I add this and click on the Sync now, it gives me error :



      Failed to resolve: recyclerview-v7


      and this is my build.gradle file :



      // Top-level build file where you can add configuration options common to 

      all sub-projects/modules.

      buildscript
      repositories
      google()
      jcenter()

      dependencies
      classpath 'com.android.tools.build:gradle:3.2.1'

      // NOTE: Do not place your application dependencies here; they belong
      // in the individual module build.gradle files



      allprojects
      repositories
      google()
      jcenter()
      mavenCentral()
      mavenLocal()



      apply plugin: 'com.android.library'

      android
      packagingOptions
      exclude 'META-INF/NOTICE'



      android
      packagingOptions
      exclude 'META-INF/LICENSE'



      android
      compileSdkVersion 28
      buildToolsVersion "28.0.3"

      defaultConfig
      minSdkVersion 16
      targetSdkVersion 28
      versionCode 1
      versionName "1.0"



      dependencies
      api project(':MapdroidClient')
      api project(':UiUtil')
      implementation 'org.slf4j:slf4j-api:1.7.25'
      implementation 'com.github.ksoichiro:android-observablescrollview:1.6.0'
      implementation 'com.nineoldandroids:library:2.4.0'
      implementation 'org.osmdroid:osmdroid-android:5.6.4'
      implementation 'com.android.support:support-v4:28.0.0'
      implementation 'com.android.support:design:28.0.0'



      I know that in my observablescrollview library, there is recyclerview dependency, but I don't know why i get this error.



      I searched every where and none of solutions worked. Solutions like changing order of google() and jcenter() repositories ...










      share|improve this question














      I want to add this dependency in my build.gradle file :



      implementation 'com.android.support:design:28.0.0'


      when I add this and click on the Sync now, it gives me error :



      Failed to resolve: recyclerview-v7


      and this is my build.gradle file :



      // Top-level build file where you can add configuration options common to 

      all sub-projects/modules.

      buildscript
      repositories
      google()
      jcenter()

      dependencies
      classpath 'com.android.tools.build:gradle:3.2.1'

      // NOTE: Do not place your application dependencies here; they belong
      // in the individual module build.gradle files



      allprojects
      repositories
      google()
      jcenter()
      mavenCentral()
      mavenLocal()



      apply plugin: 'com.android.library'

      android
      packagingOptions
      exclude 'META-INF/NOTICE'



      android
      packagingOptions
      exclude 'META-INF/LICENSE'



      android
      compileSdkVersion 28
      buildToolsVersion "28.0.3"

      defaultConfig
      minSdkVersion 16
      targetSdkVersion 28
      versionCode 1
      versionName "1.0"



      dependencies
      api project(':MapdroidClient')
      api project(':UiUtil')
      implementation 'org.slf4j:slf4j-api:1.7.25'
      implementation 'com.github.ksoichiro:android-observablescrollview:1.6.0'
      implementation 'com.nineoldandroids:library:2.4.0'
      implementation 'org.osmdroid:osmdroid-android:5.6.4'
      implementation 'com.android.support:support-v4:28.0.0'
      implementation 'com.android.support:design:28.0.0'



      I know that in my observablescrollview library, there is recyclerview dependency, but I don't know why i get this error.



      I searched every where and none of solutions worked. Solutions like changing order of google() and jcenter() repositories ...







      android gradle






      share|improve this question













      share|improve this question











      share|improve this question




      share|improve this question










      asked Nov 15 '18 at 15:48









      Behzad GhadimiBehzad Ghadimi

      5651927




      5651927






















          1 Answer
          1






          active

          oldest

          votes


















          1














          You get this error because observablescrollview uses uses implementation to reference the recyclerview. This new build keyword makes inner dependencies invisible for you. In most cases, you do not need them anyways.



          in your case:
          if you want to use them, you need to contact the authors to compile with api instead of implementation for the recyclerview reference.



          If they don't do that, you have no chance to use their inner dependency.






          share|improve this answer

























          • thanks for this great help. Actually I don't really know the differences of api and implementation and I don't want to use inner dependencies, I want all my support library versions be 28.0.0. But in observablescrollview, they use version 22.2.0. And I got error mixing version can lead to runtime error.

            – Behzad Ghadimi
            Nov 15 '18 at 16:10











          • what you heard is true. And that is the reason why this special case is a good one to use the api keyword. Glad I could help. Accept the answer please if it solved your problem.

            – Grisgram
            Nov 15 '18 at 16:12











          • no , I changed implementation to api for 3 of my libraries but I got same error

            – Behzad Ghadimi
            Nov 15 '18 at 16:15











          • Yes you are right. My bad. The api keyword is not necessary in YOUR build.gradle file but in the build file of the observable scrollview. If they used implementation, the reference is hidden for you. You can't use it. THEY need to open the reference for you by linking recyclerview as api.

            – Grisgram
            Nov 15 '18 at 16:18











          • and I haven't access to that library, I just use it :(

            – Behzad Ghadimi
            Nov 15 '18 at 16:20










          Your Answer






          StackExchange.ifUsing("editor", function ()
          StackExchange.using("externalEditor", function ()
          StackExchange.using("snippets", function ()
          StackExchange.snippets.init();
          );
          );
          , "code-snippets");

          StackExchange.ready(function()
          var channelOptions =
          tags: "".split(" "),
          id: "1"
          ;
          initTagRenderer("".split(" "), "".split(" "), channelOptions);

          StackExchange.using("externalEditor", function()
          // Have to fire editor after snippets, if snippets enabled
          if (StackExchange.settings.snippets.snippetsEnabled)
          StackExchange.using("snippets", function()
          createEditor();
          );

          else
          createEditor();

          );

          function createEditor()
          StackExchange.prepareEditor(
          heartbeatType: 'answer',
          autoActivateHeartbeat: false,
          convertImagesToLinks: true,
          noModals: true,
          showLowRepImageUploadWarning: true,
          reputationToPostImages: 10,
          bindNavPrevention: true,
          postfix: "",
          imageUploader:
          brandingHtml: "Powered by u003ca class="icon-imgur-white" href="https://imgur.com/"u003eu003c/au003e",
          contentPolicyHtml: "User contributions licensed under u003ca href="https://creativecommons.org/licenses/by-sa/3.0/"u003ecc by-sa 3.0 with attribution requiredu003c/au003e u003ca href="https://stackoverflow.com/legal/content-policy"u003e(content policy)u003c/au003e",
          allowUrls: true
          ,
          onDemand: true,
          discardSelector: ".discard-answer"
          ,immediatelyShowMarkdownHelp:true
          );



          );













          draft saved

          draft discarded


















          StackExchange.ready(
          function ()
          StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2fstackoverflow.com%2fquestions%2f53323087%2ferror-failed-to-resolve-recyclerview-v7-in-android-studio-3-2-1%23new-answer', 'question_page');

          );

          Post as a guest















          Required, but never shown

























          1 Answer
          1






          active

          oldest

          votes








          1 Answer
          1






          active

          oldest

          votes









          active

          oldest

          votes






          active

          oldest

          votes









          1














          You get this error because observablescrollview uses uses implementation to reference the recyclerview. This new build keyword makes inner dependencies invisible for you. In most cases, you do not need them anyways.



          in your case:
          if you want to use them, you need to contact the authors to compile with api instead of implementation for the recyclerview reference.



          If they don't do that, you have no chance to use their inner dependency.






          share|improve this answer

























          • thanks for this great help. Actually I don't really know the differences of api and implementation and I don't want to use inner dependencies, I want all my support library versions be 28.0.0. But in observablescrollview, they use version 22.2.0. And I got error mixing version can lead to runtime error.

            – Behzad Ghadimi
            Nov 15 '18 at 16:10











          • what you heard is true. And that is the reason why this special case is a good one to use the api keyword. Glad I could help. Accept the answer please if it solved your problem.

            – Grisgram
            Nov 15 '18 at 16:12











          • no , I changed implementation to api for 3 of my libraries but I got same error

            – Behzad Ghadimi
            Nov 15 '18 at 16:15











          • Yes you are right. My bad. The api keyword is not necessary in YOUR build.gradle file but in the build file of the observable scrollview. If they used implementation, the reference is hidden for you. You can't use it. THEY need to open the reference for you by linking recyclerview as api.

            – Grisgram
            Nov 15 '18 at 16:18











          • and I haven't access to that library, I just use it :(

            – Behzad Ghadimi
            Nov 15 '18 at 16:20















          1














          You get this error because observablescrollview uses uses implementation to reference the recyclerview. This new build keyword makes inner dependencies invisible for you. In most cases, you do not need them anyways.



          in your case:
          if you want to use them, you need to contact the authors to compile with api instead of implementation for the recyclerview reference.



          If they don't do that, you have no chance to use their inner dependency.






          share|improve this answer

























          • thanks for this great help. Actually I don't really know the differences of api and implementation and I don't want to use inner dependencies, I want all my support library versions be 28.0.0. But in observablescrollview, they use version 22.2.0. And I got error mixing version can lead to runtime error.

            – Behzad Ghadimi
            Nov 15 '18 at 16:10











          • what you heard is true. And that is the reason why this special case is a good one to use the api keyword. Glad I could help. Accept the answer please if it solved your problem.

            – Grisgram
            Nov 15 '18 at 16:12











          • no , I changed implementation to api for 3 of my libraries but I got same error

            – Behzad Ghadimi
            Nov 15 '18 at 16:15











          • Yes you are right. My bad. The api keyword is not necessary in YOUR build.gradle file but in the build file of the observable scrollview. If they used implementation, the reference is hidden for you. You can't use it. THEY need to open the reference for you by linking recyclerview as api.

            – Grisgram
            Nov 15 '18 at 16:18











          • and I haven't access to that library, I just use it :(

            – Behzad Ghadimi
            Nov 15 '18 at 16:20













          1












          1








          1







          You get this error because observablescrollview uses uses implementation to reference the recyclerview. This new build keyword makes inner dependencies invisible for you. In most cases, you do not need them anyways.



          in your case:
          if you want to use them, you need to contact the authors to compile with api instead of implementation for the recyclerview reference.



          If they don't do that, you have no chance to use their inner dependency.






          share|improve this answer















          You get this error because observablescrollview uses uses implementation to reference the recyclerview. This new build keyword makes inner dependencies invisible for you. In most cases, you do not need them anyways.



          in your case:
          if you want to use them, you need to contact the authors to compile with api instead of implementation for the recyclerview reference.



          If they don't do that, you have no chance to use their inner dependency.







          share|improve this answer














          share|improve this answer



          share|improve this answer








          edited Nov 15 '18 at 16:23

























          answered Nov 15 '18 at 15:56









          GrisgramGrisgram

          1,47611127




          1,47611127












          • thanks for this great help. Actually I don't really know the differences of api and implementation and I don't want to use inner dependencies, I want all my support library versions be 28.0.0. But in observablescrollview, they use version 22.2.0. And I got error mixing version can lead to runtime error.

            – Behzad Ghadimi
            Nov 15 '18 at 16:10











          • what you heard is true. And that is the reason why this special case is a good one to use the api keyword. Glad I could help. Accept the answer please if it solved your problem.

            – Grisgram
            Nov 15 '18 at 16:12











          • no , I changed implementation to api for 3 of my libraries but I got same error

            – Behzad Ghadimi
            Nov 15 '18 at 16:15











          • Yes you are right. My bad. The api keyword is not necessary in YOUR build.gradle file but in the build file of the observable scrollview. If they used implementation, the reference is hidden for you. You can't use it. THEY need to open the reference for you by linking recyclerview as api.

            – Grisgram
            Nov 15 '18 at 16:18











          • and I haven't access to that library, I just use it :(

            – Behzad Ghadimi
            Nov 15 '18 at 16:20

















          • thanks for this great help. Actually I don't really know the differences of api and implementation and I don't want to use inner dependencies, I want all my support library versions be 28.0.0. But in observablescrollview, they use version 22.2.0. And I got error mixing version can lead to runtime error.

            – Behzad Ghadimi
            Nov 15 '18 at 16:10











          • what you heard is true. And that is the reason why this special case is a good one to use the api keyword. Glad I could help. Accept the answer please if it solved your problem.

            – Grisgram
            Nov 15 '18 at 16:12











          • no , I changed implementation to api for 3 of my libraries but I got same error

            – Behzad Ghadimi
            Nov 15 '18 at 16:15











          • Yes you are right. My bad. The api keyword is not necessary in YOUR build.gradle file but in the build file of the observable scrollview. If they used implementation, the reference is hidden for you. You can't use it. THEY need to open the reference for you by linking recyclerview as api.

            – Grisgram
            Nov 15 '18 at 16:18











          • and I haven't access to that library, I just use it :(

            – Behzad Ghadimi
            Nov 15 '18 at 16:20
















          thanks for this great help. Actually I don't really know the differences of api and implementation and I don't want to use inner dependencies, I want all my support library versions be 28.0.0. But in observablescrollview, they use version 22.2.0. And I got error mixing version can lead to runtime error.

          – Behzad Ghadimi
          Nov 15 '18 at 16:10





          thanks for this great help. Actually I don't really know the differences of api and implementation and I don't want to use inner dependencies, I want all my support library versions be 28.0.0. But in observablescrollview, they use version 22.2.0. And I got error mixing version can lead to runtime error.

          – Behzad Ghadimi
          Nov 15 '18 at 16:10













          what you heard is true. And that is the reason why this special case is a good one to use the api keyword. Glad I could help. Accept the answer please if it solved your problem.

          – Grisgram
          Nov 15 '18 at 16:12





          what you heard is true. And that is the reason why this special case is a good one to use the api keyword. Glad I could help. Accept the answer please if it solved your problem.

          – Grisgram
          Nov 15 '18 at 16:12













          no , I changed implementation to api for 3 of my libraries but I got same error

          – Behzad Ghadimi
          Nov 15 '18 at 16:15





          no , I changed implementation to api for 3 of my libraries but I got same error

          – Behzad Ghadimi
          Nov 15 '18 at 16:15













          Yes you are right. My bad. The api keyword is not necessary in YOUR build.gradle file but in the build file of the observable scrollview. If they used implementation, the reference is hidden for you. You can't use it. THEY need to open the reference for you by linking recyclerview as api.

          – Grisgram
          Nov 15 '18 at 16:18





          Yes you are right. My bad. The api keyword is not necessary in YOUR build.gradle file but in the build file of the observable scrollview. If they used implementation, the reference is hidden for you. You can't use it. THEY need to open the reference for you by linking recyclerview as api.

          – Grisgram
          Nov 15 '18 at 16:18













          and I haven't access to that library, I just use it :(

          – Behzad Ghadimi
          Nov 15 '18 at 16:20





          and I haven't access to that library, I just use it :(

          – Behzad Ghadimi
          Nov 15 '18 at 16:20



















          draft saved

          draft discarded
















































          Thanks for contributing an answer to Stack Overflow!


          • Please be sure to answer the question. Provide details and share your research!

          But avoid


          • Asking for help, clarification, or responding to other answers.

          • Making statements based on opinion; back them up with references or personal experience.

          To learn more, see our tips on writing great answers.




          draft saved


          draft discarded














          StackExchange.ready(
          function ()
          StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2fstackoverflow.com%2fquestions%2f53323087%2ferror-failed-to-resolve-recyclerview-v7-in-android-studio-3-2-1%23new-answer', 'question_page');

          );

          Post as a guest















          Required, but never shown





















































          Required, but never shown














          Required, but never shown












          Required, but never shown







          Required, but never shown

































          Required, but never shown














          Required, but never shown












          Required, but never shown







          Required, but never shown







          Popular posts from this blog

          Top Tejano songwriter Luis Silva dead of heart attack at 64

          ReactJS Fetched API data displays live - need Data displayed static

          政党