Reputation: 71
The following error was outputted after I upgraded my IDE despite not changing anything else:
CompileAssetCatalog /Users/suy/Library/Developer/Xcode/DerivedData/MyADT-enhkcdzrxjsfitcgsibsehlazpgg/Build/Products/Release-iphonesimulator/MyADT.app MyADT/Images.xcassets
cd /Users/suy/Desktop/self-service-mobile-ios
export PATH="/Applications/Xcode.app/Contents/Developer/Platforms/iPhoneSimulator. platform/Developer/usr/bin:/Applications/Xcode.app/Contents/Developer/usr/bin:/usr/bin:/bin:/usr/sbin:/sbin"
/Applications/Xcode.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/usr/bin/actool --output-format human-readable-text --notices --warnings --export-dependency-info /Users/suy/Library/Developer/Xcode/DerivedData/MyADT-enhkcdzrxjsfitcgsibsehlazpgg/Build/Intermediates/MyADT.build/Release-iphonesimulator/MyADT.build/assetcatalog_dependencies.txt --output-partial-info-plist /Users/suy/Library/Developer/Xcode/DerivedData/MyADT-enhkcdzrxjsfitcgsibsehlazpgg/Build/Intermediates/MyADT.build/Release-iphonesimulator/MyADT.build/assetcatalog_generated_info.plist --app-icon AppIcon --launch-image LaunchImage --platform iphonesimulator --minimum-deployment-target 7.1 --target-device iphone --target-device ipad --compress-pngs --compile /Users/suy/Library/Developer/Xcode/DerivedData/MyADT-enhkcdzrxjsfitcgsibsehlazpgg/Build/Products/Release-iphonesimulator/MyADT.app /Users/suy/Desktop/self-service-mobile-ios/MyADT/Images.xcassets
2015-09-09 11:28:44.991 IBCocoaTouchImageCatalogTool[25293:921614] *** Terminating app due to uncaught exception 'IBAssertionFailure', reason: 'ASSERTION FAILURE:
Reason: code which should be unreachable has been reached
File: /SourceCache/IBAutolayoutFoundationIOS/IDEInterfaceBuilder-7706/Foundation/ImageCatalog/Compiler/IBICCoreThemeDocument.m:349
Method: -[IBICCoreThemeDocument coreUIResizingModeForResizingBehavior:]'
...
...
libc++abi.dylib: terminating with uncaught exception of type NSException
Command /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/usr/bin/actool failed with exit code 255
Upvotes: 2
Views: 367
Reputation: 1181
Your problem is indeed due to the format of xcassets being changed in xCode 7. However by removing the blocks you're losing image strech behaviour settings.
Instead you can fix this by changing "cap-insets"
to "capInsets"
and "mode" : "tile"
to "mode" : "fill"
Here's the resulting string for your case:
{
"images": [
{
"idiom": "universal",
"filename": "login_show_button.png",
"scale": "1x"
},
{
"resizing": {
"mode": "9-part",
"center": {
"mode": "tile",
"width": 4,
"height": 3
},
"cap-insets": {
"bottom": 5,
"top": 6,
"right": 7,
"left": 9
}
},
"idiom": "universal",
"filename": "[email protected]",
"scale": "2x"
},
{
"idiom": "universal",
"scale": "3x"
}
],
"info": {
"version": 1,
"author": "xcode"
}
}
Upvotes: 1
Reputation: 71
After some digging I found the issue with my Images.xcassets folder. Any Contents.json file has a block added to it by Xcode 7 beta 6.
{
"images" : [
{
"idiom" : "universal",
"filename" : "login_show_button.png",
"scale" : "1x"
},
{
"resizing" : {
"mode" : "9-part",
"center" : {
"mode" : "tile",
"width" : 4,
"height" : 3
},
"cap-insets" : {
"bottom" : 5,
"top" : 6,
"right" : 7,
"left" : 9
}
},
"idiom" : "universal",
"filename" : "[email protected]",
"scale" : "2x"
},
{
"idiom" : "universal",
"scale" : "3x"
}
],
"info" : {
"version" : 1,
"author" : "xcode"
}
}
I was able to remove the "resizing" and "cap-insets" blocks up until the "idiom" declaration. Doing this for all the Contents.json files allowed me to build successfully.
Upvotes: 0