xcode 将 iOS 应用程序提交到应用程序商店应用程序标识符无效
声明:本页面是StackOverFlow热门问题的中英对照翻译,遵循CC BY-SA 4.0协议,如果您需要使用它,必须同样遵循CC BY-SA许可,注明原文地址和作者信息,同时你必须将它归于原作者(不是我):StackOverFlow
原文地址: http://stackoverflow.com/questions/20120128/
Warning: these are provided under cc-by-sa 4.0 license. You are free to use/share it, But you must attribute it to the original authors (not me):
StackOverFlow
Submitting iOS app to app store application identifier invalid
提问by tessad
I'm using xcode 5 and I guess I'm missing where to change the bundle identifier.
我正在使用 xcode 5,我想我错过了在哪里更改包标识符。
When I try to validate my app for submission to the app store, I get two errors....
当我尝试验证我的应用程序以提交到应用程序商店时,我收到两个错误....
Invalid code signing entitlements. Your application bundle's signature contains code signing entitlements that are not supported on iOS. Speicifically value 'K8TE8KDZ95.com.iclinical.child' for key 'application-identifier' in 'Payload/iResus.app/iResus' is not supported. This value should be a string starting with your TEAMID, followed by a dot '.' followed by the bundle identifier
无效的代码签名权利。您的应用程序包的签名包含 iOS 不支持的代码签名权利。不支持“Payload/iResus.app/iResus”中关键“application-identifier”的具体值“K8TE8KDZ95.com.iclinical.child”。该值应该是一个以您的 TEAMID 开头的字符串,后跟一个点“.” 后跟包标识符
and
和
The executable at Payload/iResus.app/iResus in Payload/iResus.app has been signed with identifier 'com.iclinical.child' which does not match the bundle identifier 'com.iclinical.childresus
Payload/iResus.app 中 Payload/iResus.app/iResus 的可执行文件已使用标识符“com.iclinical.child”签名,该标识符与包标识符“com.iclinical.childresus”不匹配
I'm not sure where I should be changing this. The bundle identifier in the target is com.iclinical.child but clearly I need to change it somewhere else too....
我不确定我应该在哪里改变这个。目标中的包标识符是 com.iclinical.child 但显然我也需要在其他地方更改它......
Hope you can help.
希望你能帮忙。
回答by Charlie Seligman
I just had both these error messages and here is how I fixed it:
我刚刚收到了这两条错误消息,这是我修复它的方法:
- Went into iTunes Connect > viewed my app (under manage apps) and copied the 'Bundle ID'
- Went into xcode and pasted the 'Bundle ID' into the info.plist 'Bundle identifier' field
- Restarted xcode
- Xcode > Window > Organizer > Projects > 'Delete' derived data file for project
- Xcode > Product > Alt + Clean (to Clean Build folder)
- 进入 iTunes Connect > 查看我的应用程序(在管理应用程序下)并复制“捆绑 ID”
- 进入 xcode 并将“捆绑 ID”粘贴到 info.plist 的“捆绑标识符”字段中
- 重启xcode
- Xcode > Window > Organizer > Projects > 'Delete' 项目的派生数据文件
- Xcode > Product > Alt + Clean(到 Clean Build 文件夹)
I then tried resubmitting and it all went through correctly. I am 95% sure my Bundle ID was correct to begin with so it might have been something in steps 2 to 5 that fixed this.
然后我尝试重新提交,并且一切顺利。我 95% 确定我的 Bundle ID 一开始是正确的,所以它可能是在第 2 步到第 5 步中解决了这个问题。
Anyways hope this helps someone else.
无论如何,希望这对其他人有所帮助。
回答by moby
In XCode 9, Open the Project Navigator, Select your target, check the following two places:
在 XCode 9 中,打开 Project Navigator,选择你的目标,检查以下两个地方:
- General ---> Identity ---> Bundle Identifier
- Build Settings -> Packaging -> Product bundle identifier
- 通用 ---> 身份 ---> 捆绑标识符
- 构建设置 -> 包装 -> 产品包标识符
Sometimes this issue happens when you have changed the Bundle Identifier in place 1, but place 2 did not change accordingly.
有时当您在位置 1 中更改了 Bundle Identifier,但位置 2 没有相应更改时,会发生此问题。
回答by Dov D.
I had the same errors trying to validate an app that was originally developed with a different bundle identifier than what I had entered into itunesconnect.
我在尝试验证最初使用与我在 itunesconnect 中输入的标识符不同的捆绑标识符开发的应用程序时遇到了同样的错误。
There were two issues that I came across:
我遇到了两个问题:
If you change the bundle-identifier in XCode (General tab, Info tab or Info.plist), XCode won't archive the app with the new bundle identifier (in some cases) until you restart XCode.
If XCode is managing your provisioning profiles dynamically (normally using a wildcard bundle-identifier) and you are trying to use a fixed bundle identifier, you have to choose the static provisioning profile in your build settings.
如果您更改 XCode 中的包标识符(常规选项卡、信息选项卡或 Info.plist),在您重新启动 XCode 之前,XCode 不会使用新的包标识符(在某些情况下)存档应用程序。
如果 XCode 正在动态管理您的配置文件(通常使用通配符包标识符)并且您尝试使用固定包标识符,则必须在构建设置中选择静态配置文件。
I was surprised by the second issue because I never used XCode with a fixed provisioning profile and never had to download a profile in the past.
我对第二个问题感到惊讶,因为我从来没有使用过带有固定配置文件的 XCode,而且过去也不需要下载配置文件。
Since I wanted my app to use a wildcard bundle identifier, I changed it in itunesconnect and updated my settings, restarted XCode and my app validated.
由于我希望我的应用程序使用通配符包标识符,因此我在 itunesconnect 中更改了它并更新了我的设置,重新启动了 XCode 并验证了我的应用程序。
Hope this helps.
希望这可以帮助。
回答by Kibernetik
I got the same error, although I already submitted the app with this BundleID multiple times.
我遇到了同样的错误,虽然我已经多次提交了带有这个 BundleID 的应用程序。
What solved the problem: performed Product->Clean and restarted Xcode.
什么解决了问题:执行 Product->Clean 并重新启动 Xcode。
回答by Tommie C.
I'm using xcode 5 and I guess I'm missing where to change the bundle identifier.
我正在使用 xcode 5,我想我错过了在哪里更改包标识符。
In Xcode 5:
在 Xcode 5 中:
- Open the Project Navigator
- Select your project name at the top of the tree on the left
- Single Click directly onto the project name (it should become highlighted)
- Change the project name (the bundle id will be updated)
Once you highlight the blue project icon at the top of your project navigator you will have several tabs on the right hand side appear. Your bundle identifier should have the default value as noted below:
com.company.${PRODUCT_NAME:rfc1034identifier}
- 打开项目导航器
- 在左侧树的顶部选择您的项目名称
- 直接单击项目名称(它应该突出显示)
- 更改项目名称(bundle id 会更新)
突出显示项目导航器顶部的蓝色项目图标后,右侧会出现几个选项卡。您的捆绑标识符应具有如下所示的默认值:
com.company.${PRODUCT_NAME:rfc1034identifier}
You might also want to create a sample empty project and note the project info defaults compared to your current settings.
您可能还想创建一个示例空项目,并注意与当前设置相比的项目信息默认值。
Hope this helps.
希望这可以帮助。
回答by crypt
How I resolved this:
我是如何解决这个问题的:
- Cleaned the build folder. Menu -> Product -> Alt key: Clean build folder.
- Closed the XCode.
- Deleted derived data.
- Restarted my system. (Had to try this because steps 1 to 3 did not work for me as suggested in other posts).
- 清理了构建文件夹。菜单 -> 产品 -> Alt 键:清理构建文件夹。
- 关闭了 XCode。
- 删除派生数据。
- 重新启动了我的系统。(必须尝试这个,因为第 1 步到第 3 步对我不起作用,正如其他帖子中所建议的那样)。
After this created an app archive and it worked.
在这之后创建了一个应用程序存档并且它起作用了。
回答by Lawrence Du
Ok this is incredibly dumb, but I had the exact same issue when working on two open projects at once in Xcode 11. The apparent solution was to quit and restart Xcode. I suspect there is some sort of Xcode bug or failure to context switch.
好的,这非常愚蠢,但是在 Xcode 11 中同时处理两个打开的项目时,我遇到了完全相同的问题。明显的解决方案是退出并重新启动 Xcode。我怀疑存在某种 Xcode 错误或上下文切换失败。
回答by Nikos M.
The appID in the Apple developer portal (and the assigned to it distribution provisioning profile) is not the same as the bundle id in your project. You should change one of them. They should match in order to upload the app in the app store.
Apple 开发人员门户中的 appID(以及分配给它的分发配置文件)与项目中的 bundle id 不同。你应该改变其中之一。它们应该匹配才能在应用商店中上传应用。