[求助] 上传 apk 到 PlayStore 过程中遇到的问题 - V2EX
V2EX = way to explore
V2EX 是一个关于分享和探索的地方
现在注册
已注册用户请  登录
spongebobsun
V2EX    Android

[求助] 上传 apk 到 PlayStore 过程中遇到的问题

  •  
  •   spongebobsun 2016-10-08 16:34:26 +08:00 12878 次点击
    这是一个创建于 3356 天前的主题,其中的信息可能已经有所发展或是发生改变。

    上传 apk 时 play store 给出的报错是 -

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

    于是本地跑了一下 aapt , 结果是这样婶儿的 -

     Desktop /Developer/Android/sdk/build-tools/24.0.0/aapt dump badging app-release.apk package: name='sun.bob.leela' versiOnCode='1' versiOnName='1.0' platformBuildVersiOnName='' sdkVersion:'16' targetSdkVersion:'24' uses-permission: name='android.permission.READ_EXTERNAL_STORAGE' uses-permission: name='android.permission.WRITE_EXTERNAL_STORAGE' uses-permission: name='android.permission.VIBRATE' uses-permission: name='android.permission.SYSTEM_ALERT_WINDOW' application-label-zh:'Puff' application-icon-120:'res/mipmap-mdpi-v4/ic_launcher.png' application-icon-160:'res/mipmap-mdpi-v4/ic_launcher.png' application-icon-240:'res/mipmap-hdpi-v4/ic_launcher.png' application-icon-320:'res/mipmap-xhdpi-v4/ic_launcher.png' application-icon-480:'res/mipmap-xxhdpi-v4/ic_launcher.png' application-icon-640:'res/mipmap-xxxhdpi-v4/ic_launcher.png' application-icon-65534:'res/mipmap-mdpi-v4/ic_launcher.png' application: label='Puff' icon='res/mipmap-mdpi-v4/ic_launcher.png' launchable-activity: name='sun.bob.leela.ui.activities.SplashActivity' label='Puff' icon='' ERROR getting 'android:label' attribute: attribute is not a string value Desktop 

    第一次上传 app ,不知道是做错了啥, google 了一圈发现说好像是 aapt 的 bug , android:label 里面不能用 @string ,于是瞅了下我的 manifest -

    <?xml version="1.0" encoding="utf-8"?> <manifest xmlns:android="http://schemas.android.com/apk/res/android" package="sun.bob.leela"> <uses-permission android:name="android.permission.READ_EXTERNAL_STORAGE" /> <uses-permission android:name="android.permission.WRITE_EXTERNAL_STORAGE" /> <uses-permission android:name="android.permission.VIBRATE" /> <uses-permission android:name="android.permission.SYSTEM_ALERT_WINDOW" /> <application android:name=".App" android:allowBackup="true" android:icon="@mipmap/ic_launcher" android:label="@string/app_name" android:largeHeap="true" android:supportsRtl="true" android:theme="@style/AppTheme"> <activity android:name=".ui.activities.SplashActivity" android:label="Puff" android:screenOrientation="portrait" android:theme="@style/AppTheme.Splash"> <intent-filter> <action android:name="android.intent.action.MAIN" /> <category android:name="android.intent.category.LAUNCHER" /> </intent-filter> </activity> 

    这就很尴尬了。。。也怀疑过是多语言的问题,这个 app 里面有中文和英文两个 string.xml ,尝试删除中文的 string.xml 依旧无效。。。

    有没有遇到过类似问题的老司机给个解决思路啊。。。先谢过。。。

    6 条回复    2016-10-08 18:13:18 +08:00
    inmyfree
        1
    inmyfree  
       2016-10-08 17:33:56 +08:00
    3,4 年前上传过,那时候不是这么玩的....[:dogge]
    skydiver
        2
    skydiver  
       2016-10-08 17:35:57 +08:00
    > android:label 里面不能用 @string
    不用不就行了……
    spongebobsun
        3
    spongebobsun  
    OP
       2016-10-08 17:44:45 +08:00
    @skydiver 问题是没用啊。。。。我直接写了个字符串在里面的
    skydiver
        4
    skydiver  
       2016-10-08 17:55:56 +08:00
    @spongebobsun android:label="@string/app_name" 这是啥?
    spongebobsun
        5
    spongebobsun  
    OP
       2016-10-08 18:12:58 +08:00
    解决了。
    问题不是出在 launch activity 上面,而是后面其他 activity 我有指定 @null 作为 label 。

    aapt 这个报错实在给我看的很蒙,我一直以为是 launchable activity 出的问题。
    spongebobsun
        6
    spongebobsun  
    OP
       2016-10-08 18:13:18 +08:00
    @skydiver 问题解决了。蟹蟹回复。
    关于     帮助文档     自助推广系统     博客     API     FAQ     Solana     5121 人在线   最高记录 6679       Select Language
    创意工作者们的社区
    World is powered by solitude
    VERSION: 3.9.8.5 27ms UTC 01:26 PVG 09:26 LAX 17:26 JFK 20:26
    Do have faith in what you're doing.
    ubao msn snddm index pchome yahoo rakuten mypaper meadowduck bidyahoo youbao zxmzxm asda bnvcg cvbfg dfscv mmhjk xxddc yybgb zznbn ccubao uaitu acv GXCV ET GDG YH FG BCVB FJFH CBRE CBC GDG ET54 WRWR RWER WREW WRWER RWER SDG EW SF DSFSF fbbs ubao fhd dfg ewr dg df ewwr ewwr et ruyut utut dfg fgd gdfgt etg dfgt dfgd ert4 gd fgg wr 235 wer3 we vsdf sdf gdf ert xcv sdf rwer hfd dfg cvb rwf afb dfh jgh bmn lgh rty gfds cxv xcv xcs vdas fdf fgd cv sdf tert sdf sdf sdf sdf sdf sdf sdf sdf sdf sdf sdf sdf sdf sdf sdf sdf sdf sdf sdf sdf sdf sdf sdf sdf sdf sdf sdf sdf sdf sdf sdf sdf sdf sdf sdf sdf sdf sdf sdf sdf shasha9178 shasha9178 shasha9178 shasha9178 shasha9178 liflif2 liflif2 liflif2 liflif2 liflif2 liblib3 liblib3 liblib3 liblib3 liblib3 zhazha444 zhazha444 zhazha444 zhazha444 zhazha444 dende5 dende denden denden2 denden21 fenfen9 fenf619 fen619 fenfe9 fe619 sdf sdf sdf sdf sdf zhazh90 zhazh0 zhaa50 zha90 zh590 zho zhoz zhozh zhozho zhozho2 lislis lls95 lili95 lils5 liss9 sdf0ty987 sdft876 sdft9876 sdf09876 sd0t9876 sdf0ty98 sdf0976 sdf0ty986 sdf0ty96 sdf0t76 sdf0876 df0ty98 sf0t876 sd0ty76 sdy76 sdf76 sdf0t76 sdf0ty9 sdf0ty98 sdf0ty987 sdf0ty98 sdf6676 sdf876 sd876 sd876 sdf6 sdf6 sdf9876 sdf0t sdf06 sdf0ty9776 sdf0ty9776 sdf0ty76 sdf8876 sdf0t sd6 sdf06 s688876 sd688 sdf86