When I am opening my project in Xcode 9, getting above error for Storyboard and Launchscreen.
Note: Cleaning derived data didn't help me.
Please have a look at the screenshot.
You can find the issue in Problem Report, just clink on report a bug and open the log.txt file where you can find the issue. In my case i set invalid table row height.
Trash derived data by two ways either by command or Preferences.
rm -rf ~/Library/Developer/Xcode/DerivedData/
or
Xcode -> Preferences -> Location -> Derived Data
In Xcode menu go to product clear the project.
Disconnect connected device and restart Xcode and system.
More: https://www.e-learn.cn/content/wangluowenzhang/266937
I was getting same issue in Xcode 10.2.1
I have open interface builder (Story board) as source code just like attached screen shot by right click on storyboard file
Followed below steps
<document type="com.apple.InterfaceBuilder3.CocoaTouch.Storyboard.XIB" version="3.0"
Its get refreshed now and I was not getting error now and view was proper also
However when I revisted the spruce code of story board the version reverted to 3.0 again.
But this worked for as refresh and resolved my problem
This generally happens when you have a compiler error in the code that the editor can't figure out or handle. So it crashes. Unfortunately, the only way to fix this is to find out the piece of code and fix it.
I had this when Swift could not figure out the type for one of my variables.
This answer is worth checking out as well.
After quite some tries I was able to fix it here. Xcode-select was pointing to a wrong version of Xcode (here pointing to Xcode 8.3.3).
To check, use
xcode-select -p
To change, use
sudo xcode-select --switch /Applications/Xcode.app/Contents/Developer
The problem seems to occur when using a Xcode 9 instance while xcode-select points to a Xcode 8 version. In case you need to use Xcode 8.x again, don't forget to switch back.
When it was happen to me at that time I have configuration was like,
OS : macOS Sierra Version 10.12.6 Xcode : 9.0
I have created new project and open storyboard and this error was there.
Solution : I just quit the xcode and start again and error was not that.
So, it's just requires restart of xcode!
Mostly this error occurred when you have open 2 different version of Xcode. Solution: Please close both Xcode and clear drived data.now again try, use one Xcode at a time
Check image density. Change to 72dpi or more.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With