Invalid SplitApkBundle. The bundle targets unknown languages: [gr]. google play console

余生颓废 提交于 2020-01-09 09:58:26

问题


Android app bundle upload failed with error

Invalid SplitApkBundle. The bundle targets unknown languages: [gr]

Android Studio version 3.5

I tried

  1. Clean & rebuild
  2. Invalidate cache/restart

回答1:


I had the same issue.
Invalid SplitApkBundle. The bundle targets unknown languages:[cb]

I solved by setting DSL to stop aapt package building the wrong language targets.

My app supports English and Chinese, therefore resConfigs only needs en and zh.

defaultConfig {
    ...
    resConfigs "en", "zh-rTW", "zh-rCN"
}



回答2:


Apply this to Android{}

bundle {
    density {
        // Different APKs are generated for devices with different screen densities; true by default.
        enableSplit true
    }
    abi {
        // Different APKs are generated for devices with different CPU architectures; true by default.
        enableSplit true
    }
    language {
        // This is disabled so that the App Bundle does NOT split the APK for each language.
        // We're gonna use the same APK for all languages.
        enableSplit false
    }
}



回答3:


in my case i was because i was using facebook account kit see wells answer it helped me out , i am in lining it here for future references

bundle {
    density {
        // Different APKs are generated for devices with different screen densities; true by default.
        enableSplit true
    }
    abi {
        // Different APKs are generated for devices with different CPU architectures; true by default.
        enableSplit true
    }
    language {
        // This is disabled so that the App Bundle does NOT split the APK for each language.
        // We're gonna use the same APK for all languages.
        enableSplit false
    }
}



回答4:


I had the same issue after downgrading facebook login implimentation to 5.8 it's fixed

implementation 'com.facebook.android:facebook-login:5.8.0'



回答5:


I'm facing the same issue, I guess it is related to some resources added for Facebook's Account Kit (specifically the values inside /res/values-cb/values-cb.xml) I've tried uploading a version without this SDK and the playstore proccessed it properly




回答6:


In my case, I was working with Localization and Translation also. It worked. no more code.

Put this code in app-level build.gradle.

android {
    bundle {
        language {
            enableSplit = false
        }
    }

    ...

}


来源:https://stackoverflow.com/questions/57859122/invalid-splitapkbundle-the-bundle-targets-unknown-languages-gr-google-play

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!