0

I've been testing a simple React Native app heavily borrowed from the sample app, and ran into this problem only when I use network shared from my iPhone 4G/LTE hotspot. This won't be seen when connecting to a WiFi AP.

Here's the detailed error message:

Request.fetch.xhr.onload                                  index.ios.bundle:11123
  XMLHttpRequestBase.$XMLHttpRequestBase_sendLoad           index.ios.bundle:11569
  XMLHttpRequestBase.callback                               index.ios.bundle:11549
  XMLHttpRequest.<anonymous>                                index.ios.bundle:11330
  MessageQueueMixin._invokeCallback                         index.ios.bundle:7446
  Object.ErrorUtils.applyWithGuard                          index.ios.bundle:873
  guardReturn                                               index.ios.bundle:7277
  MessageQueueMixin.invokeCallbackAndReturnFlushedQueue     index.ios.bundle:7459
  messageHandlers.executeJSCall:method:arguments:callback:  debugger-ui:54
  WebSocket.ws.onmessage                                    debugger-ui:80

I tried to look for the similar issue but without success. Tracing back to the corresponding fetch.js for the XmlHttpRequest function doesn't help me to know the issue much either. Could anyone have the similar experience and help?

jotshin
  • 45
  • 1
  • 7
  • Is the URL you request a local network URL? For example localhost or ip based? – Wim Mostmans Apr 14 '15 at 20:05
  • It's not a local network URL. I just used the one Facebook tutorial shows: [JSON link](https://raw.githubusercontent.com/facebook/react-native/master/docs/MoviesExample.json) – jotshin Apr 15 '15 at 01:59

1 Answers1

2

This problem was solved by resetting the Xcode simulator.

See here for How to reset a simulator

Community
  • 1
  • 1
jotshin
  • 45
  • 1
  • 7
  • Resetting the sim solved a separate network issue for me [too](https://github.com/facebook/react-native/issues/863). – thisjustin Apr 15 '15 at 16:43