1

我正在使用android studio 2.3最新的穩定版本。當我使用configChanges添加活動時,我遇到了這5個錯誤。有趣的是我可以運行應用程序。所以我認爲這是新版本的某種錯誤,但我不確定。在Android Studio 2.3中Android Manifest configChanges錯誤

我也試圖改變這3個configChanges keyboardHidden|orientation|screenSize的順序,但它仍然顯示5級象這樣的錯誤screenSize" />

當我刪除configChanges其中之一,我沒有看到任何錯誤。 因此keyboardHidden|orientation不會導致任何錯誤。

有誰知道我爲什麼會遇到這種錯誤?謝謝。

error message

清單文件,導致錯誤。 Manifest activity

更新

的build.gradle文件:

apply plugin: 'com.android.application' 
apply plugin: 'io.fabric' 

android { 
    compileSdkVersion 25 
    buildToolsVersion "25.0.2" 
    defaultConfig { 
     applicationId "com.test.test" 
     minSdkVersion 16 
     targetSdkVersion 25 
     versionCode 200 
     versionName "2.0" 
     multiDexEnabled true 
     vectorDrawables.useSupportLibrary = true 
     testInstrumentationRunner "android.support.test.runner.AndroidJUnitRunner" 
     manifestPlaceholders = [manifestApplicationId   : "${applicationId}", 
           onesignal_app_id    : "713123123123131313", 
           onesignal_google_project_number: "123123123"] 
    } 
    signingConfigs { 
     config { 
      keyAlias 'android' 
      keyPassword 'android' 
      storeFile file('/Users/test/.android/debug.keystore') 
      storePassword 'android' 
     } 
     config_staging { 
      keyAlias 'asdadsStaging' 
      keyPassword '13123131' 
      storeFile file('../asdasdasd.jks') 
      storePassword '13123123' 
     } 
    } 
    buildTypes { 
     release { 
      minifyEnabled false 
      proguardFiles getDefaultProguardFile('proguard-android.txt'), 'proguard-rules.pro' 

     } 
     debug { 
      minifyEnabled false 
      debuggable true 

     } 
     staging { 
      minifyEnabled false 
      debuggable true 
      applicationIdSuffix ".staging" 


      // one signal staging 
      manifestPlaceholders = [manifestApplicationId   : "com.test.test.staging", 
            onesignal_app_id    : "04123123123123123", 
            onesignal_google_project_number: "1232131231"] 

      signingConfig signingConfigs.config_staging 
     } 
    } 
} 

dependencies { 
    compile fileTree(dir: 'libs', include: ['*.jar']) 
    androidTestCompile('com.android.support.test.espresso:espresso-core:2.2.2', { 
     exclude group: 'com.android.support', module: 'support-annotations' 
    }) 
    testCompile 'junit:junit:4.12' 

    compile project(':volley') 
    compile project(path: ':customtabs') 
    compile('com.crashlytics.sdk.android:crashlytics:[email protected]') { transitive = true; } 
    compile 'com.onesignal:OneSignal:[email protected]' 
    compile 'com.miguelcatalan:materialsearchview:1.4.0' 
    compile 'com.ToxicBakery.viewpager.transforms:view-pager-transforms:[email protected]' 
    compile 'com.android.support:multidex:1.0.1' 
    compile 'com.android.support:support-v13:25.2.0' 
    compile 'com.android.support:gridlayout-v7:25.2.0' 
    compile 'com.android.support:appcompat-v7:25.2.0' 
    compile 'com.android.support:recyclerview-v7:25.2.0' 
    compile 'com.android.support:cardview-v7:25.2.0' 
    compile 'com.android.support:design:25.2.0' 
    compile 'com.android.support:preference-v7:25.2.0' 
    compile 'com.android.support:customtabs:25.2.0' 
    compile 'com.android.support:support-v4:25.2.0' 
    compile 'com.google.code.gson:gson:2.7' 
    compile 'com.squareup.picasso:picasso:2.5.2' 
    compile 'com.squareup.okhttp:okhttp:2.7.5' 
    compile 'com.squareup.okhttp:okhttp-urlconnection:2.7.5' 
    compile 'com.facebook.android:facebook-android-sdk:4.18.0' 
    compile 'com.facebook.android:audience-network-sdk:4.18.0' 
    compile 'com.google.android.gms:play-services-gcm:10.2.0' 
    compile 'com.google.android.gms:play-services-analytics:10.2.0' 
    compile 'com.google.android.gms:play-services-ads:10.2.0' 
    compile 'com.google.android.gms:play-services-auth:10.2.0' 
    compile 'com.google.firebase:firebase-core:10.2.0' 
    compile 'com.google.firebase:firebase-auth:10.2.0' 
    compile 'com.google.firebase:firebase-database:10.2.0' 
    compile 'com.google.firebase:firebase-ads:10.2.0' 
    compile 'com.google.firebase:firebase-crash:10.2.0' 
    compile 'com.google.firebase:firebase-config:10.2.0' 
    compile 'com.appnext.sdk:native-ads-mediation-mopub:1.7.6' 
// compile 'com.flurry.android:ads:6.5.0' 
// compile 'com.inmobi.monetization:inmobi-ads:5.3.1' 
// compile 'net.pubnative:library:2.2.0' 
// compile 'com.github.mobfox:MobFox-Android-SDK-Core:2.1.3' 
// compile 'com.flurry.android:analytics:6.5.0' 
    compile('com.mopub:mopub-sdk:[email protected]') { transitive = true; } 
    compile('io.fabric.sdk.android:fabric:[email protected]') { transitive = true; } 
    compile("com.twitter.sdk.android:twitter:[email protected]") { transitive = true } 
    compile 'com.android.support.constraint:constraint-layout:1.0.0' 
} 

repositories { 
    maven { 
     url 'https://maven.fabric.io/public' 
    } 
    jcenter() 
} 

buildscript { 
    repositories { 
     maven { 
      url 'https://maven.fabric.io/public' 
     } 
    } 
    dependencies { 
     classpath 'io.fabric.tools:gradle:1.21.6' 
    } 
} 

apply plugin: 'com.google.gms.google-services' 
+0

什麼是您的最低SDK版本? –

+0

minSdkVersion 16 – MiloRambaldi

+0

你能告訴我你的build.gradle文件嗎? –

回答

0

同樣在這裏的問題。我在添加MoPub活動時遇到此錯誤。 即使報告了這些錯誤,該應用程序也能正確編譯並按預期工作。