fastlane 打包报错信息如下
[15:37:11]: Going to update project 'xxx.xcodeproj' with UUID
[15:37:11]: Updating target xxx...
[15:37:11]: Skipping configuration Debug as it doesn't match the filter 'Release'
[15:37:11]: Updating configuration Release...
[15:37:11]: undefined method `[]' for nil:NilClass
具体是错误在 update_project_provisioning.rb:73:
/Users/xxx/.rvm/gems/ruby-2.6.3/gems/fastlane-2.204.3/fastlane/lib/fastlane/actions/update_project_provisioning.rb:73:in `block (2 levels) in run': [!] undefined method `[]' for nil:NilClass (NoMethodError)
打开文件错误位置 ,
build_configuration.build_settings["PROVISIONING_PROFILE"] = data["UUID"]
看样子是这句赋值是空的,
我的解决方案:
新增 get_provisioning_profile
, 更新所有provisioning profile
文件 设置force: true,
get_provisioning_profile( # Create or get provisioning profile
adhoc: false, # true: AdHoc Profiles, false: App Store Profiles
force: true, # Renew provisioning profiles regardless of its state - to automatically add all devices for ad hoc profiles
)
更多参考方案看这里
网友评论