iOS Simulator constantly failing when App encounters an error

Steps to reproduce:

  • Open XDE
  • Make a bug
  • Try to click “refresh” (freezes)
  • Try to restart simulator (XDE works)
  • Simulator freezes
Error running `xcrun simctl openurl booted exp://localhost:19000`: An error was encountered processing the command (domain=NSPOSIXErrorDomain, code=60):
The operation couldn’t be completed. Operation timed out
Operation timed out
11:21:03 PM
Error installing or running app. Error: Process exited with non-zero code: 60

Must close Simulator, press “Restart”, Press Device → iOS Simulator

Is this me?

It seems like Apple’s iOS simulator sometimes just gets into this state, independent of Expo. There are a lot of google results for that error string. I think the best bet is to just Reset Content and Settings on your simulator.

If you can find some JS code in your Expo project which consistently reproduces this behavior 100% of the time, I’d be interested to see a Snack or other repro for that.

1 Like

Hey Ben,

Thanks for the reply! Sorry for the delay. Holidays

The weird thing is that when I create a new project and detach via create-react-native-app, I don’t run into this issue at all.

  1. create-react-native-app
  2. eject
  3. make a couple of syntax errors, reload

My simulator works fine. I’d be happy to share any details

Error: not opened
    at WebSocket.send (/Users/peter/Projects/preposterous/orchard-react-native/node_modules/ws/lib/WebSocket.js:219:16)
    at send (/Users/peter/Projects/preposterous/orchard-react-native/node_modules/react-native/local-cli/server/util/webSocketProxy.js:26:12)
    at WebSocket.debuggerSocket.onmessage (/Users/peter/Projects/preposterous/orchard-react-native/node_modules/react-native/local-cli/server/util/webSocketProxy.js:49:46)
    at WebSocket.onMessage (/Users/peter/Projects/preposterous/orchard-react-native/node_modules/ws/lib/WebSocket.js:442:14)
    at emitTwo (events.js:106:13)
    at WebSocket.emit (events.js:191:7)
    at Receiver.ontext (/Users/peter/Projects/preposterous/orchard-react-native/node_modules/ws/lib/WebSocket.js:841:10)
    at /Users/peter/Projects/preposterous/orchard-react-native/node_modules/ws/lib/Receiver.js:536:18
    at /Users/peter/Projects/preposterous/orchard-react-native/node_modules/ws/lib/Receiver.js:368:7
    at /Users/peter/Projects/preposterous/orchard-react-native/node_modules/ws/lib/PerMessageDeflate.js:249:clock5:``` 

always seems to break on the web socket, but works fine in vanilla React Native

I think it could be something to do with the way my project is set up.

I created a brand new Expo projects and none of issues take place!

Could it be the size of my bundle?