Xcode 8 - IB Designables - Failed to render and update auto layout status, The agent crashed
You can try one of the following to figure out the cause:
- look for the
IBDesignablesAgentCocoaTouch
logs in this directory:~/Library/Logs/DiagnosticReports
and see the cause.
Note: for user with Catalina: look for
IBDesignablesAgent-iOS_<DATE>-<MAC_NAME>.crash
Go to the Editor -> Debug Selected View while selecting your
@IBDesignable UIView
in your storyboard, and see the stack trace.Delete Derive Data folder.
Xcode Preference -> Location -> Derived Data /Users/YourMacName/Library/Developer/Xcode/DerivedData
Clean your project
Shift
+Command
+Alt
+K
.Build your project
Command
+B
.
I solved the problem by doing the following:
- Go to
File > Workspace settings
. - Click the little right arrow beside "Derived data". This opens the Finder app at the location of the
DerivedData
folder. - Go inside the
DerivedData
folder, and delete the folder corresponding to your project. - Quit Xcode, and re-open it.
- Clean your project shiftcommandk.
- build your project commandb.
- Open your storyboard.
- Go to
Editor > Refresh all views
.
Updated
Sometimes just directly Go to Editor > Refresh all views
worked. If Refresh all views
is disabled, quit Xcode and try again.
I just delete the view that is failed and press command+Z to undo deletion. It works for me.
If editing the failed view later, the error may occur again, do the above again.