Android Studio 3.0 Error. Migrate dependency configurations for local modules

前端 未结 6 485
南方客
南方客 2020-12-07 17:47

I recently installed the latest Canary build of Android Studio which is currently using the Android Gradle plugin 3.0.0-alpha4 .

I now get a error:

E         


        
6条回答
  •  忘掉有多难
    2020-12-07 18:09

    This solution worked for me. I'm using Android Studio 3.1.2. Android Gradle plugin 3.1.2. Gradle 4.4. I have a library module with flavours such as trial and premium. As part of the process of migrating to the Android Gradle plugin 3.1.2 I added a flavour dimension of main to my library module's gradle build file. To correct the build error therefore in my app's build.gradle file I changed the following:

    debugImplementation project(path: ':library', configuration: 'premiumDebug')
    releaseImplementation project(path: ':library', configuration: 'premiumRelease')
    

    became

    implementation project(':library')
    

    and I added the following line to my defaultConfig block: missingDimensionStrategy 'main', 'premium'

提交回复
热议问题