我构建 CI 服务器并使用 Xcode bot 构建我的项目。我有一个问题,为什么机器人需要这么长时间才能集成(超过 30 分钟)。似乎 Xcode 机器人必须检查所有源代码才能为每个集成构建。即使我在清理项目后从头开始正常构建也只需要大约 15 分钟。第二次集成只是比第一次快一点。我想知道当 Xcode bot 集成时会发生什么。是检查每个集成的新源代码还是只更新旧源代码?为什么要花这么多时间?
问问题
827 次
1 回答
0
我有一个类似的问题。结果发现目录名称源代码在 CI 服务器上被检出损坏。我从位于MyProject - iOS
目录中的项目创建了 Xcode Bot,此信息被传送到没有正确处理空格的 bot。
如果您查看日志,您将看到目录名称被转义到MyProject%20-%20iOS
然后再次进入MyProject%2520-%2520iOS
.
Mar 2 10:56:01 [3230] <Info>: Will attempt to update checkout cache for bot
Mar 2 10:56:01 [3230] <Info>: Xcode Source Control Blueprint was valid.
Mar 2 10:56:01 [3230] <Info>: About to update/checkout:
https://ciuser@code-ci.mycompany.com/MyProject Branch: develop into MyProject%20-%20iOS/
Mar 2 10:56:01 [3230] <Warning>: Could not load cached workspace: Error Domain=XCSIntegrationService Code=2 "The repositories have changed since the last integration. Falling back to a clean checkout." UserInfo={NSLocalizedDescription=The repositories have changed since the last integration. Falling back to a clean checkout.}
Mar 2 10:56:01 [3230] <Warning>: An error occurred updating existing checkout: Error Domain=XCSIntegrationService Code=2 "The repositories have changed since the last integration. Falling back to a clean checkout." UserInfo={NSLocalizedDescription=The repositories have changed since the last integration. Falling back to a clean checkout.}
Mar 2 11:04:31 [3230] <Info>: 0.40% Compressing objects: 4% done
Mar 2 11:10:26 [3230] <Info>: Counting objects: 69562, done.
Mar 2 11:10:26 [3230] <Info>: 13.57% Receiving objects: 1,7 MB done
[...cut...]
Mar 2 11:35:45 [3230] <Info>: Completed checkout of:
https://ciuser@code-ci.mycompany.com/MyProject Branch: develop (@24cec9eca484405f7d2819f3652e34f67853b6fe) into MyProject%2520-%2520iOS/
为了解决这个问题,我不得不删除机器人,将存储库目录名称从 更改MyProject - iOS
为MyProject
并从头开始创建机器人。
于 2018-03-02T14:40:27.103 回答