iOS Provisioning Profile总莫名其妙失效问题

来源:互联网 发布:java split函数 多个 编辑:程序博客网 时间:2024/06/07 07:05

iOS Provisioning Profile总莫名其妙失效问题

刚做iOS不太久,遇到一个非常奇怪的问题:证书明明还有一年的时间,可是在把App安装到真机上时,三天两头出现“已过期”之类的提示,不得不经常重复以下动作序列:

  • 删除Mac上的Profile
  • 删除手机上的Profile
  • 在Appple Member Center重新Edit(以让其有效)
  • Mac重新取Profile
  • 安装到真机

真的是“三天两头”出现,有时正着急要看效果时,这个问题就给你捣乱……

曾经google多次,得到的线索有(可能导致Profile失效的原因):

  • App ID 改变
  • 在Member Center新加了device
  • App的Capabilities改变

都试过了,没有好转

在经历了大约3个月的苦难日子之后,在MemberCenter闲逛,发现其中有Developers,猛然意识到,我们几个developer用的Certificate都是当时申请开发者账号的那个邮箱地址zhxxx@xxx.com,是不是这样乱用会带来问题?

进一步看了以下,申请账号的那个邮箱的角色是Agent,他可以邀请100个developer(发邮件给他们,他们再通过自己的Apple ID)登录Member Center,完成邀请流程,从而具有和Agent一样的“读”权限,(当然,“写”权限比较低)。这应该是正确的做法。之前那样的乱用,效果相当于一个人不停地从一台Mac切换到另一台,又切换到另另一台。看起来像下面这种情况:

https://developer.apple.com/library/ios/documentation/IDEs/Conceptual/AppDistributionGuide/Troubleshooting/Troubleshooting.html

If the certificate already exists in Member Center, a “Your account already has a valid certificate” dialog appears. Typically, this happens when you move from one Mac to another. If possible, export your certificates as a developer profile file on the other Mac, and then import them on your new Mac, as described in Exporting and Importing Certificates and Profiles. If you don’t have a backup of your developer profile, click the “Revoke and Request” button when the “Your account already has a valid certificate” dialog appears.You can also request specific types of certificates, as described in Requesting Signing Identities.

于是,试着向正确的方式迁移:给每个developer发一个邀请,然后大家再逐一在Member Center完成该走的
流程。这样的方式实行了两个周多,没有再出现过失效,我心安了。



文/NoteCode(简书作者)
原文链接:http://www.jianshu.com/p/45a2a51edacd
著作权归作者所有,转载请联系作者获得授权,并标注“简书作者”。
0 0
原创粉丝点击