artumi artumi - 1 year ago 193
iOS Question

Xcode Server Bot Issue: warning. Build Service Error. Issue: archive at path 'some/path' is malformed

I'm using Cocoapods and KIF to run Continuous Integration on an Xcode server. I have successfully set this up for one project to report on each commit. I'm now using a second project and get the error:

Bot Issue: warning. Build Service Error.
Issue: archive at path '/Library/Developer/XcodeServer/Integrations/Integration-81d42936b22a04037fd4aebed1074e5e/Archive.xcarchive' is malformed.
Integration Number: 1.
Description: archive at path '/Library/Developer/XcodeServer/Integrations/Integration-81d42936b22a04037fd4aebed1074e5e/Archive.xcarchive' is malformed.

The tests passed when ran on the Xcode server machine using Xcode. I tried downloading Provisioning Profiles etc via Xcode but that didn't help. I deleted the Bot and created a new one but that also did't help.

Any help is welcome

Answer Source

At least in my case (and there may be multiple causes), this was caused by having "Skip Install" set on every target, which causes you to end up with an empty archive (but only on Xcode Server).

Basically, xcodebuild (the command-line tool) has lots of critical differences from Xcode in the way it handles archiving. It builds targets that aren't listed in the scheme, and it obeys the Skip Archive flag even for targets listed in the scheme. By contrast, when building locally, Xcode ignores the Skip Archive flag and archives any targets in the scheme (and only the targets listed in the scheme).

I would encourage you to file a bug every time you run into situations where a project builds locally but fails on the server. If everyone did this, perhaps these differences would eventually get fixed....

Recommended from our users: Dynamic Network Monitoring from WhatsUp Gold from IPSwitch. Free Download