CoreData: annotation: Failed to load optimized model (React Native)

Viewed 9101

I can not start my react native application anymore. I updated XCode yesterday, maybe it has to do with it?

$ react-native run-ios

Found Xcode workspace xyz.xcworkspace
CoreData: annotation:  Failed to load optimized model at path '/Applications/Xcode.app/Contents/Applications/Instruments.app/Contents/Frameworks/InstrumentsPackaging.framework/Versions/A/Resources
/XRPackageModel.momd/XRPackageModel 9.0.omo'
dyld: Symbol not found: _SimAudioHostUseSystemDefaultDeviceUID
Referenced from: /Applications/Xcode.app/Contents/Developer/usr/bin/../../Library/PrivateFrameworks/SimulatorKit.framework/Versions/A/SimulatorKit (which was built for Mac OS X 10.12)
Expected in: /Library/Developer/PrivateFrameworks/CoreSimulator.framework/Versions/A/CoreSimulator
in /Applications/Xcode.app/Contents/Developer/usr/bin/../../Library/PrivateFrameworks/SimulatorKit.framework/Versions/A/SimulatorKit
6 Answers

I simply had to start XCode one time after the update and then I was asked if I want to install additional components. That's all.

+1 on what @Jan mentioned. This happened to me after upgrading XCode to latest, and then running react-native run-ios threw the same error. Booting up XCode prompted me to install additional components, and that resolved the issue.

If you just updated your Xcode to Xcode 11.1 simply go to Xcode->preferences->Locations and change the command line tool to 11.0, this worked for me!

I was running XCode v9.2 and I was getting this error. Basically Then I had to Upgrade to Mac 10.13.2 (Sierra to High Sierra) and then download XCode v9.4. When I opened XCode 9.4 for the first time I was asked to download the components that everyone is talking about. I no longer had the error.

Couldn't figure it out, but I realized that running from Xcode directly works.

Related