简体   繁体   中英

:app:dataBindingMergeDependencyArtifactsDebug' Error

What is causing the problem? I am encountering such an error in my application sale. I couldn't find anything exactly as a solution.

FAILURE: Build failed with an exception.

* What went wrong:
Execution failed for task ':app:dataBindingMergeDependencyArtifactsDebug'.
> Could not resolve all files for configuration ':app:debugCompileClasspath'.
   > Could not resolve androidx.core:core-ktx:+.
     Required by:
         project :app
      > Skipped due to earlier error
      > Failed to list versions for androidx.core:core-ktx.
         > Unable to load Maven meta-data from https://dl.bintray.com/kotlin/kotlin-eap/androidx/core/core-ktx/maven-metadata.xml.
            > Could not get resource 'https://dl.bintray.com/kotlin/kotlin-eap/androidx/core/core-ktx/maven-metadata.xml'.
               > Could not GET 'https://dl.bintray.com/kotlin/kotlin-eap/androidx/core/core-ktx/maven-metadata.xml'. Received status code 502 from server: Bad Gateway

* 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

You need to declare your dependency correctly "androidx.core:core-ktx:$core_version"

This is because bintray support is now no longer there. Go to your project level build.gradle and comment out the bintray dependencies in the allprojects and repositories section

Bintray Shutdown

As @Narendra_Nath said, it is because of the bintray dependencies and Jcenter shutting down. you can refer to this article https://blog.gradle.org/jcenter-shutdown

the solution that worked for me is changing the repositories in the (Top-level build.gradle) to

    buildscript {
      repositories {
        google()
        mavenCentral()
        maven {
        url "https://repo.spring.io/release"
        }
        maven {
        url "https://repository.jboss.org/maven2"
      } }

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM