Failed to resolve: com.android.support:appcompat-v7:28.0 –

Development issue/problem:

When I use com.android.support:appcompat-v7:28.+ in the build.gradle(module) of my project, it works without error. But if I just use com.android.support:appcompat-v7:28, without .+, I get an error:

Just without the .+ ending. I’ve already added Maven, but the result is the same. Do you have any idea how to fix the problem?

How can I solve this problem?

Solution 1:

28.0.0 is the final version of the supporting libraries. Android has switched to AndroidX. To use the latest Android libraries, switch to AndroidX

Edit: Versions 28.0.0-rc02 and 28.0.0 are now available.

I don’t see version 28.0 in Google Maven. Only 28.0.0-alpha1 and 28.0.0-alpha3. Just change it to one or the other or what it was before, i.e. .+, which means any version before the major version 28.

For an alpha appcompact, version 28.+ makes more sense.

Solution 2:

Add the following code to the build.gragle (project) to add the Google Maven repository

all projects {
submissions {

maven {
url https://maven.google.com/ name
Google
}

}
}

Solution 3:

some people who may still have problems like me (for IRANIANS and all those who have penalties) this bug can be fixed with the proxy
I used this free proxy for Android Studio 3.2
https://github.com/freedomofdevelopers/fod
just go into the settings (Ctrl + Alt + S) and find the HTTP proxy and then check the manual configuration of the proxy, then add fodev.org
for the host name and 8118 for the port number

Screenshot of the proxy settings in the android studio

Solution 4:

As @Sourabh pointed out, you can see which packages Google has listed via the Google Maven link.

If, like me, you receive a message similar to this Failed to resolve:com.android.support:appcompat-v7:28.0, you may have gotten there after updating targetSdkVersion or compilingSdkVerstion.

Basically, the package is not as indicated in the post. If you have updated the SDK, check Google Maven to see what versions of the package are available for the new version of the SDK you want to update.

I had these addictions (on version 27):

Implementierung ‘com.android.support:appcompat-v7:27.1.1’Implementierung ‘com.android.support:design:27.1.1’Implementierung ‘com.android.support:recyclingerview-v7:27.1.1’Implementierung ‘com.android.support:cardview-v7:27.1.1’Implementierung ‘com.android.support:support-v4:27.1.1’Implementierung ‘com.android.support:support-v4:27.1.1’.

And I had to change the version of the SDK and the rest of the package number:

Implementation com.android.support:appcompat-v7:28.0.0Implementation com.android.support:design:28.0.0Implementation com.android.support:recyclingerview-v7:28.0.0Implementation com.android.support:cardview-v7: 28.0.0Implementation com.android.support:encouragementt-v4: 28.0.0Implementation com.android.support:encouragementt-v4: 28.0.0 1C10 Implementation com.android.support:cardview-v7: 28.0.0.0

The packages have now been found and downloaded. Currently, the only package available for version 28 of the SDK is 28.0.0.

Solution no. 5:

Run the campaign.

gradlew -q app:dependencies

This will correct the error.

Solution no. 6:

My problem was simply the network connection. Using a VPN solved the problem.

Solution no. 7:

Implementation com.android.support: appcompat-v7:28.0
Implementation com.android.support: support-media-compatible 28.0.0
Implementation com.android.support:support:encouragementt-v4:28.0.0

Anything to add

Solution no. 8:

Make sure your version of buildTools is compatible with the compact version of the application.

To find the installedSdkVersion and buildToolsVersion builds, go to Tools > SDK Manager. A window appears where you can manage your build version (compileSdkVersion) and your build version (buildToolsVersion).

To see the exact distribution of the versions, check the Show package details checkbox.

android {compileSdkVersion 28buildToolsVersion 28.0.3 (HERE)defaultConfig {applicationId com.example.truecitizenquizminSdkVersion 14targetSdkVersion 28versionCodeversionName 1.0testInstrumentationRunner android.support.test.runner.AndroidJUnitRunner} Build Types{release {minifyEnabled falseproguardFiles getDefaultProguardFile(‘proguard-android-optimalize.txt’), ‘proguard-rules.pro’}}}}}

dependencies [
implementation fileTree(dir: ‘libs’, including: [‘*.jar’])
implementation ‘com.android.support:appcompat-v7:28.0.0’ (HERE)
implementation ‘com.android.support.constraint:constraint-layout:1.1.3
testImplementation ‘junit:junit:4.12’
androidTestImplementation ‘com.android.support:test:runner:1.0.2’
androidTestImplementation ‘com.android.support.test.espresso:espresso-core:3.0.2’
}

Solution no. 9:

in build.gradle the version of the bellows line must be the same

com.android.support:appcompat-v7: 28.0.0-alpha1
Implementation com.android.support:design: 28.0.0.

Good luck!

Related Tags:

Leave a comment

Your email address will not be published. Required fields are marked *