简体   繁体   English

Xcode 自动登录和配置文件错误

[英]Xcode Automatic sign in and provisioning profile errors

I'm trying to run my iOS app on TestFlight.我正在尝试在 TestFlight 上运行我的 iOS 应用程序。 the app runs on the simulator but when I connect it to my iPhone and try to run it, the ffollowing error shows up.该应用程序在模拟器上运行,但是当我将它连接到我的 iPhone 并尝试运行它时,出现以下错误。 Automatic signing failed Xcode failed to provision this target.自动签名失败 Xcode 未能提供此目标。 Please file a bug report at https://bugreport.apple.com/ and include the Update Signing report from the Report navigator.请在https://bugreport.apple.com/提交错误报告,并包括报告导航器中的更新签名报告。

Provisioning profile "iOS Team Provisioning Profile: com.uditi.clima" doesn't support the Keychain Sharing capability.配置文件“iOS 团队配置文件:com.uditi.clima”不支持钥匙串共享功能。

Provisioning profile "iOS Team Provisioning Profile: com.uditi.clima" doesn't include the keychain-access-groups entitlement.配置文件“iOS 团队配置文件:com.uditi.clima”不包括钥匙串访问组权利。

I tried to change my bundle identifier.我试图更改我的包标识符。 I am new to iOS Dev and not sure how things work.我是 iOS Dev 的新手,不确定它是如何工作的。 error screenshot错误截图

I switched on keychain sharing but an error appears - Automatic sign in failed我打开钥匙串共享但出现错误 - 自动登录失败

Thanks!谢谢!

This is due to some certification issues over at Apple, but in the meantime here's a workaround:这是由于 Apple 的一些认证问题,但同时这里有一个解决方法:

  1. Open the project in Xcode.在 Xcode 中打开项目。 Select the project from the Project Navigator, then select your Target from the column.从项目导航器中选择项目,然后从列中选择您的目标。

  2. Click on the General tab, and under the Signing section, enable "Automatically manage signing".单击“常规”选项卡,然后在“签名”部分下,启用“自动管理签名”。

  3. Next, click on the Capabilities tab and make sure both "Keychain Sharing" and "App Groups" are switched to "On".接下来,单击“功能”选项卡并确保“钥匙串共享”和“应用程序组”都切换为“开”。 Ignore any error messages.忽略任何错误消息。

  4. An entitlements file will be generated in the Project Navigator.将在项目导航器中生成一个权利文件。 The file is recognizable by its extension .entitlements .该文件可通过其扩展名.entitlements识别。

  5. Move the .entitlements file to the root folder by dragging it until it's right underneath the project file..entitlements文件拖动到根文件夹,直到它位于项目文件的正下方。

  6. Now, back in the "Capabilities" tab, turn off "Keychain Sharing" and "App Groups".现在,返回“功能”选项卡,关闭“钥匙串共享”和“应用程序组”。 Ignore any error messages.忽略任何错误消息。

  7. Select the project and go to its "Build Settings" tab.选择项目并转到其“构建设置”选项卡。 Directly beneath the tab, select both "All" and "Combined".在选项卡正下方,同时选择“全部”和“组合”。 Scroll down (or use the search, upper right) to find the "Code Signing Identity" section and change all of the options to iOS Developer .向下滚动(或使用右上角的搜索)找到“代码签名身份”部分并将所有选项更改为iOS Developer

  8. Next, scroll to (or search for) the "Code Signing Entitlements" section.接下来,滚动到(或搜索)“代码签名权利”部分。 Double click the text field next to "Code Signing Entitlements" and type in the entire name of the .entitlements file you moved before.双击“代码签名权利”旁边的文本字段,然后输入您之前移动的.entitlements文件的全名。 For example, HelloWorld.entitlements .例如, HelloWorld.entitlements

This should solve the provisioning error until Apple addresses these certification issues.这应该可以解决配置错误,直到 Apple 解决这些认证问题。

只需在 Developer ID 证书颁发机构上将 Trust 更改为 System default

Recently I faced the exact same problem, Searched a lot with no success on the way others suggested.最近我遇到了完全相同的问题,按照其他人的建议进行了很多搜索,但没有成功。

I have found a work around by just removing every single capability below signing... like app group, network extension, keychain sharing, etc... I just remove everything below signing and then add them again right away then all error gone with a successful build.我找到了一种解决方法,只需删除签名下方的每一项功能……例如应用程序组、网络扩展、钥匙串共享等……我只是删除签名下方的所有内容,然后立即再次添加它们,然后所有错误都消失了成功构建。

if u want to use your m1 mac as phone: Are you maybe running Xcode in Rosetta mode?如果您想将 m1 mac 用作手机:您是否在 Rosetta 模式下运行 Xcode? I had this issue, exactly as mentioned above.我有这个问题,正如上面提到的。 To fix this I closed Xcode, turned off Rosetta and it's now working as expected.为了解决这个问题,我关闭了 Xcode,关闭了 Rosetta,它现在可以正常工作了。

https://developer.apple.com/forums/thread/676083 https://developer.apple.com/forums/thread/676083

Reboot of my laptop fixed the problem重启我的笔记本电脑解决了这个问题

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

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