Skip to main content

Gradle sync error Error:Failed to resolve: com.android.support

The project was working Fine. But suddenly it throws the following error.

app\build.gradle
    Error:Error:Failed to resolve: com.android.support:support-annotations:27.0.1
Install Repository and sync project
    Error:Error:Failed to resolve: com.android.support:appcompat-v7:27.0.1
Install Repository and sync project
    Error:Error:Failed to resolve: com.android.support:customtabs:27.0.1
Install Repository and sync project
    Error:Error:Failed to resolve: com.android.support:cardview-v7:27.0.1
Install Repository and sync project
    Error:Error:Failed to resolve: com.android.support:support-v4:27.0.1
Install Repository and sync project
    Error:Error:Failed to resolve: com.android.support:support-core-utils:27.0.1
Install Repository and sync project
Reason:
It suddenly shows error because of Facebook has updated the SDK and removed support for the previous one
Solution:
 You have to update the Facebook SDK in your Gradle. Then it will be solved.
 your existing code might be compile 'com.facebook.android:facebook-android-sdk:4' OR 'com.facebook.android:facebook-login:[4,5)'  change that to compile 'com.facebook.android:facebook-android-sdk:4.26.0'

Comments

  1. Failed to resolve: support-core-utils

    please solved this Error

    ReplyDelete

Post a Comment

Popular posts from this blog

Local variable for "serviceWorkerVersion" is deprecated in flutter

Problem:  Local variable for "serviceWorkerVersion" is deprecated. Use "{{flutter_service_worker_ version}}" template token instead. See  https://docs.flutter.dev/ platform-integration/web/ initialization  for more details. While try to run my flutter app in chrome it shows the above error. Solution: In script file it shows as like below < script > // The value below is injected by flutter build, do not touch. var serviceWorkerVersion = null ; </ script > Replace with below.It will works fine. < script > // The value below is injected by flutter build, do not touch. var serviceWorkerVersion = "{{flutter_service_worker_ version}}" ; </ script >