简体   繁体   English

上载到Google Play时发生错误:android:label属性:属性不是字符串值

[英]error on uploading to google play: android:label attribute: attribute is not a string value

i have tried to upload my new apk to google play services and it says the current error message: 我尝试将新的APK上传到Google Play服务,并显示当前错误消息:

Your APK cannot be analyzed using aapt. Error output:
Failed to run aapt dump badging:
ERROR getting 'android:label' attribute:attribute is not a string value

I have tried to search for this error on the web, and this tutorial( ERROR getting 'android:label' attribute: attribute is not a string value ) recomended to use the "aapt dump badging APKPATH" command to see what's the error. 我试图在网络上搜索此错误,并且本教程( 错误获取“ android:label”属性:属性不是字符串值 )建议使用“ aapt dump badging APKPATH”命令查看错误所在。 Here's what i got: http://postimg.org/image/u8d0unohv/ 这是我得到的: http : //postimg.org/image/u8d0unohv/

I really don´t know how to read this. 我真的不知道该怎么读。 Can someone help me to identify the error? 有人可以帮助我确定错误吗? My game has a values-jp folder for japanese strings and here is the manifest file: 我的游戏有一个用于日语字符串的values-jp文件夹,这是清单文件:

<?xml version="1.0" encoding="utf-8"?>
<manifest xmlns:android="http://schemas.android.com/apk/res/android"
    package="br.ufrn.dimap.pairg.karutakanji.android"
    android:versionCode="7"
    android:versionName="0.1.12-beta" >

    <supports-screens
        android:largeScreens="true"
        android:normalScreens="false"
        android:smallScreens="false"
        android:xlargeScreens="true"
        android:requiresSmallestWidthDp="600" />

    <uses-sdk
        android:minSdkVersion="11"
        android:targetSdkVersion="18" />

    <uses-permission android:name="android.permission.INTERNET" />
    <uses-permission android:name="android.permission.GET_ACCOUNTS" />
    <uses-permission android:name="android.permission.GET_TASKS" />
    <uses-permission android:name="android.permission.ACCESS_NETWORK_STATE" />

    <dependency>
        <groupId>javax.mail</groupId>

        <artifactId>mail</artifactId>
        <version>1.4.5</version>
    </dependency>
    <dependency>
        <groupId>javax.activation</groupId>

        <artifactId>activation</artifactId>

        <version>1.1.1</version>
    </dependency>

    <application
        android:allowBackup="true"
        android:icon="@drawable/ic_launcher"
        android:label="@string/tituloDoApp"
        android:theme="@style/AppTheme" >
        <meta-data
            android:name="com.google.android.gms.games.APP_ID"
            android:value="@string/app_id" />
        <meta-data
            android:name="com.google.android.gms.version"
            android:value="@integer/google_play_services_version" />

        <activity
            android:name="com.karutakanji.EscolherCategoriasModoTreinamento"
            android:label="@string/app_name"
            android:screenOrientation="portrait" >
        </activity>
        <activity
            android:name="com.karutakanji.MainActivity"
            android:label="@string/tituloDoApp"
            android:screenOrientation="portrait"
            android:windowSoftInputMode="stateHidden" >
            <intent-filter>
                <action android:name="android.intent.action.MAIN" />

                <category android:name="android.intent.category.LAUNCHER" />
            </intent-filter>
        </activity>
        <activity
            android:name="com.karutakanji.ModoCasual"
            android:label="@string/title_activity_tela_inicial_multiplayer"
            android:screenOrientation="portrait" >
        </activity>
        <activity
            android:name="com.karutakanji.ModoTreinamento"
            android:label="@string/title_activity_modo_treinamento"
            android:screenOrientation="portrait" >
        </activity>
        <activity
            android:name="com.karutakanji.DadosPartidasAnteriores"
            android:label="@string/title_activity_dados_partidas_anteriores"
            android:screenOrientation="portrait" >
        </activity>
        <activity
            android:name="com.karutakanji.MostrarDadosUmaPartida"
            android:label="@string/title_activity_mostrar_dados_uma_partida"
            android:screenOrientation="portrait" >
        </activity>
        <activity
            android:name="com.karutakanji.LojinhaMaceteKanjiActivity"
            android:label="@string/title_activity_lojinha_macete_kanji"
            android:screenOrientation="portrait" >
        </activity>
        <activity
            android:name="com.karutakanji.VerMaceteKanjiActivity"
            android:label="@string/title_activity_ver_macete_kanji"
            android:screenOrientation="portrait" >
        </activity>

        <service
            android:name="com.karutakanji.BackgroundSoundService"
            android:enabled="true" >
        </service>

        <activity
            android:name="com.karutakanji.MostrarRegrasModoTreinamento"
            android:label="@string/tituloDoApp"
            android:screenOrientation="portrait" >
        </activity>
        <activity
            android:name="com.karutakanji.Configuracoes"
            android:label="@string/title_activity_configuracoes"
            android:screenOrientation="portrait" >
        </activity>
        <activity
            android:name="com.karutakanji.EscolherFormaDeJogoTreinamento"
            android:label="@string/title_activity_escolher_forma_de_jogo_treinamento"
            android:screenOrientation="portrait" >
        </activity>
        <activity
            android:name="com.karutakanji.ModoCompeticao"
            android:label="@string/title_activity_modo_competicao"
            android:screenOrientation="portrait" >
        </activity>
        <activity
            android:name="com.karutakanji.RankingCompeticao"
            android:label="@string/title_activity_ranking_competicao"
            android:screenOrientation="portrait" >
        </activity>
        <activity
            android:name="com.karutakanji.EsqueceuSenha"
            android:label="@string/title_activity_esqueceu_senha"
            android:screenOrientation="portrait" >
        </activity>
        <activity
            android:name="com.karutakanji.MostrarPalavrasUmaPartida"
            android:label="@string/title_activity_mostrar_palavras_uma_partida"
            android:screenOrientation="portrait" >
        </activity>
    </application>

</manifest>

It looks like you have some of your tags out of place. 看起来您的某些标签不正确。 Make sure you follow the correct structure which can be found Here . 确保遵循正确的结构(可在此处找到)。 Looking at the Manifest page it does not seem that the "dependency" tag is valid as it is not within the "can contain" list. 查看清单页面 ,似乎“依赖项”标签无效,因为它不在“可以包含”列表中。

i have found the answer. 我找到了答案。 Just follow the link i gave, use the command aapt dump badging APKPATH, you will receive a sort of id number on the error. 只需按照我给的链接,使用命令aapt dump Badging APKPATH,您将收到有关错误的ID号。 Search(ctrl+f) on your project's R.java archive and find a component there. 在项目的R.java归档文件中搜索(ctrl + f),然后在其中找到一个组件。 My error was: On strings.xml, this component with this id didn't exist! 我的错误是:在strings.xml上,具有此ID的该组件不存在! I must have deleted it by mistake ^^ 我一定是误删了它^^

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

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