Deprecated Gradle features were used in this build, making it incompatible with Gradle 5.0

后端 未结 14 638
暖寄归人
暖寄归人 2020-11-28 07:33

I\'ve got a gradle FAILURE:

...\"Deprecated Gradle features were used in this build, making it incompatible with Gradle 5.0.\"

Case descrip

相关标签:
14条回答
  • 2020-11-28 07:37

    Finally decided to downgrade the junit 5 to junit 4 and rebuild the testing environment.

    0 讨论(0)
  • 2020-11-28 07:38

    in my case i updated the build.gradle file and make the classpath to latest version from 3.5.2 to 3.6.3

    dependencies {
            classpath("com.android.tools.build:gradle:3.6.3") 
        }
    
    0 讨论(0)
  • 2020-11-28 07:39

    It was fixed this kind of error after migrate to AndroidX

    • Go to Refactor ---> Migrate to AndroidX
    0 讨论(0)
  • 2020-11-28 07:44

    Run the Gradle build with a command line argument --warning-mode=all to see what exactly the deprecated features are.

    It will give you a detailed description of found issues with links to the Gradle docs for instructions how to fix your build.

    Adding --stacktrace to that, you will also be able to pinpoint where the warning comes from, if it's triggered by outdated code in one of the plugins and not your build script.

    0 讨论(0)
  • 2020-11-28 07:46

    Try this one

    cd android && ./gradlew clean && ./gradlew :app:bundleRelease
    
    0 讨论(0)
  • 2020-11-28 07:49

    I was getting this error. Turns out it only happened when I completely cleaned the RN caches (quite elaborate process) and then created a release build.

    If I cleaned the caches, created a debug build and then a release build, everything worked. Bit worrying but works.

    Note: My clean command is...

    rm -r android/build ; rm -r android/app/src/release/res ; rm -r android/app/build/intermediates ; watchman watch-del-all ; rm -rf $TMPDIR/react-* ; npm start -- --reset-cache

    0 讨论(0)
提交回复
热议问题