【发布时间】:2015-02-16 12:15:20
【问题描述】:
我正在尝试在 Jenkins 中构建我的 iOS 项目。这就是 Jenkins 作业的设置方式:
- 从 git repo(Git 插件)获取源代码
- 外部库通过 CocoaPods(CocoaPods 插件)更新
- XCode 构建已启动(Xcode 插件、指定目标、架构、工作区文件和构建输出目录。“打包应用程序并构建 .ipa?”对于此测试无效。
一、二正常,第三步失败:
Validate build/MyApp.app
cd "/Users/myuser/.jenkins/workspace/MyApp Beta"
export PATH="/Applications/Xcode.app/Contents/Developer/Platforms/iPhoneOS.platform/Developer/usr/bin:/Applications/Xcode.app/Contents/Developer/usr/bin:/usr/bin:/bin:/usr/sbin:/sbin"
export PRODUCT_TYPE=com.apple.product-type.application
/Applications/Xcode.app/Contents/Developer/Platforms/iPhoneOS.platform/Developer/usr/bin/Validation /Users/myuser/.jenkins/workspace/MyApp\ Beta/build/MyApp.app
** BUILD FAILED **
Build step 'Xcode' marked build as failure
Finished: FAILURE
在此之前我看到的唯一错误如下:
CompileStoryboard MyApp/Base.lproj/Main_iPhone.storyboard
cd "/Users/myuser/.jenkins/workspace/MyApp Beta"
export PATH="/Applications/Xcode.app/Contents/Developer/Platforms/iPhoneOS.platform/Developer/usr/bin:/Applications/Xcode.app/Contents/Developer/usr/bin:/usr/bin:/bin:/usr/sbin:/sbin"
export XCODE_DEVELOPER_USR_PATH=/Applications/Xcode.app/Contents/Developer/usr/bin/..
/Applications/Xcode.app/Contents/Developer/usr/bin/ibtool --target-device iphone --errors --warnings --notices --module MyApp --minimum-deployment-target 7.0 --output-partial-info-plist /Users/myuser/Library/Developer/Xcode/DerivedData/MyApp-ddibhvvpirpyiwdhzlmbkpcqbjvq/Build/Intermediates/MyApp.build/AdHoc_Distribution-iphoneos/MyApp.build/Main_iPhone-SBPartialInfo.plist --auto-activate-custom-fonts --output-format human-readable-text --compile /Users/myuser/.jenkins/workspace/MyApp\ Beta/build/MyApp.app/Base.lproj/Main_iPhone.storyboardc /Users/myuser/.jenkins/workspace/MyApp\ Beta/MyApp/Base.lproj/Main_iPhone.storyboard
nwi_state: registration failed (1000000)
2014-12-16 22:03:44.263 Interface Builder Cocoa Touch Tool[8241:7877572] ***createStorageTaskManagerForPath:withIdentifier failed: Error Domain=NSCocoaErrorDomain Code=4099 "The operation couldn’t be completed. (Cocoa error 4099.)" (The connection to service named com.apple.nsurlstorage-cache was invalidated.) UserInfo=0x7fca32cd3c70 {NSDebugDescription=The connection to service named com.apple.nsurlstorage-cache was invalidated.}; {
NSDebugDescription = "The connection to service named com.apple.nsurlstorage-cache was invalidated.";
}
nwi_state: registration failed (1000000)
2014-12-16 22:03:46.899 Interface Builder Cocoa Touch Tool[8270:7877686] ***createStorageTaskManagerForPath:withIdentifier failed: Error Domain=NSCocoaErrorDomain Code=4099 "The operation couldn’t be completed. (Cocoa error 4099.)" (The connection to service named com.apple.nsurlstorage-cache was invalidated.) UserInfo=0x7fd1d9f06040 {NSDebugDescription=The connection to service named com.apple.nsurlstorage-cache was invalidated.}; {
NSDebugDescription = "The connection to service named com.apple.nsurlstorage-cache was invalidated.";
}
我没有发现任何对这个错误有帮助的东西,但我想这就是构建过程失败的原因。该应用程序在 Xcode 中构建良好。当我粘贴 ibtool 命令并直接执行它时,我得到了与 Jenkins 完全相同的错误。
您知道导致此错误的原因以及如何消除它吗?
【问题讨论】:
-
我已经有这个问题好几个月了...