Trying to run an existing react-native app using ios simulator: react-native run-ios
I have looked here and tried all of the helpful answers: react-native run-ios can not find any simulator
I have also checked other github issues for react-native here: https://github.com/react-native-community/cli/issues/418 and here: https://www.bram.us/2019/09/04/react-native-could-not-find-iphone-x-simulator/ and nothing that was said has worked for me.
This is the full error log:
LO60188:appfolder mac$ react-native run-ios
Scanning folders for symlinks in /Users/mac/../../node_modules (10ms)
Found Xcode workspace MyAppName.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'
Could not find iPhone 6 simulator
I have ran npm audit fix
as per suggested solutions to this, now I'm getting a build error, although the simulator runs with no app inside it.
The following build commands failed:
CompileC /Users/../../../appfolder/ios/build/CC/Build/Intermediates.noindex/ReactNativeConfig.build/Debug-iphonesimulator/ReactNativeConfig.build/Objects-normal/x86_64/ReactNativeConfig.o /Users/../../../appfolder/node_modules/react-native-config/ios/ReactNativeConfig/ReactNativeConfig.m normal x86_64 objective-c com.apple.compilers.llvm.clang.1_0.compiler
(1 failure)
I then tried a specific iphone simulator, to no avail either (same build error as above):
react-native run-ios --simulator="iPhone SE"
React native version for the project is: 0.55 but changed to 0.61.4 after running npm audit fix
Is it something to do with the podfile? As I had to run pod init
and pod install
to install the podfile
Any guidance greatly appreciated