10

I downloaded Xcode and am getting "Interface builder Storyboard Compiler Error" when I try and run any project.

So far to troubleshoot this I have(based off any similar threads): -cleaned the file -created a new blank file (which still gives the compiler error message) -uninstalled and reinstalled Xcode (Version 8.2.1) -tried installing Xcode 8.3 beta 5 (still gives me the same error)

so far nothing has fixed this error. Also I'm up to date on OS, running macOS Sierra version 10.12.3

I am learning swift for work and am hoping to get this figured out soon.

Thank you!

(This is a picture of the Error code screenshot)

Eric Aya
  • 69,473
  • 35
  • 181
  • 253
RyGuy
  • 101
  • 1
  • 3
  • 1
    File a bug report at http://bugreport.apple.com with those diagnostics to get help from Apple, and/or provide them somewhere for us to look at if you want help from the community. – Jeremy Huddleston Sequoia Apr 02 '17 at 14:45

11 Answers11

18

Xcode 8.2.1:

  • quit Xcode
  • delete .xcuserdatad folder inside xcuserdata of .xcworkspace(if using Cocoapods) or .xcodeproj
  • reopen Xcode, clean project and clean build folder (Under Product option)

That should be ok!

Desmond DAI
  • 485
  • 5
  • 13
5

I had the same problem while trying to archive my app for the app store. I tried twice and same problem occurs.

Then i deleted the derived data, cleaned the project and restarted Xcode - THAT FIXED it.

Hopefully this will help someone else

Stan
  • 1,513
  • 20
  • 27
5

I Solved the problem by cleaning the build folder.

Just use cmd + option + shift + k and then build the project by using cmd + B and hopefully solve the problem.

AKIL KUMAR
  • 287
  • 3
  • 8
1

I was having this error for xCode 9.

An .xib file was creating the error. What I did was,

  • removed .xib file
  • added it back to the project
  • cleaned and built the project

That solved my problem.

Hima
  • 1,249
  • 1
  • 14
  • 18
1

I also ran into this with XCode 9 Beta - 2, the quick nuke from orbit didn't fix it. Just check out the Log file it points you to and you can at least patch the offending issue, even if it a bug on Apple's end. For me, the TabBar didn't like an icon image, removed it for now and it Built fine.

I'll try replacing it yet with another image. Apparently it doesn't like its own System-provided Images.

Exception name: NSInvalidArgumentException
Exception reason: System-provided UIImage instances cannot be encoded 
in NIBs - raised for instance '<UIImage: 0x7fd377eb4510>, {18, 20}'
1

None of the above suggestions worked for me. After further research I found that I had dragged a segue (popover) from a button inside of a tableview cell.

This is not allowed, as the touch anchor screen location is dynamic while the table scrolls.

I fixed the problem by anchoring the whole tableview instead and programmatically altering the popover arrow placement to be in line with the cell's button.

William T.
  • 12,831
  • 4
  • 56
  • 53
0

I just had the same problem.

After systematically removing objects from the xib I found that a button which was disabled and hidden created the internal error. After removing the button it works. (I tried to set the button back to normal : visible and enabled but that was not sifficient).

Hope that help you.

I have filed a bug report.

JKvr
  • 650
  • 7
  • 15
0

I have solved this issue by following below steps:

1. cmd + shift + k
2. cmd + option + shift + k
3. Restart Xcode
4. Restart you mac.

Hope this will also help you. Thanks!

Jigar Tarsariya
  • 3,189
  • 3
  • 14
  • 38
0

I had this same error after updating to xcode 9.4. After doing a Product -> Clean and then Product -> Build still no luck. Then Done a clean again and restarted. After the reboot the build succeeded.

sabrefm1
  • 61
  • 1
  • 9
0

I use Xcode 9.4.1 and Xcode 10 beta 4 on macOS 10.14 beta 4. I opened the project that threw this error in both versions of Xcode.

While removing different files from bundle resources, I also got several other errors, such as "Interface builder XIB Compiler Error" and "Failed to launch IBCocoaTouchImageCatalogTool via CoreSimulator spawn".

After trying every other solution I could find, what finally worked for me is reinstalling Xcode 9.4.1, reopening the project and cleaning the project/build folder.

I speculate that this happened because there were times when both Xcode versions were open simultaneously. The two versions use common files and the simultaneous usage possibly caused an internal inconsistency in the rendering of Interface Builder.

Tamás Sengel
  • 55,884
  • 29
  • 169
  • 223
0

I had this problem too, in Xcode 11; In my case it happens after solving conflicts on .xcodeproject during merging code.

I followed below steps:

  1. Remove storyboard from reference of project.
  2. Select MyProject.xcodeproj and show content of that, then open project.pbxproj by Xcode or text.
  3. Search for storyboard name and removed all line contains that names.
  4. Build project
  5. Add storyboard to project.
  6. Build project again.
Fa.Shapouri
  • 988
  • 2
  • 12
  • 30