React Native WebSocket模块连接呼叫在Android设备上崩溃

时间:2018-10-23 19:33:56

标签: android react-native websocket

当我在Android设备上打开应用程序时,看到以下堆栈跟踪。在模拟器上运行良好。

  

/com.samplernwsproj E / WebViewFactory:Chromium WebView包确实可以   不存在       android.webkit.WebViewFactory $ MissingWebViewPackageException:无法加载WebView提供程序:未安装WebView           在android.webkit.WebViewFactory.getWebViewContextAndSetProvider(WebViewFactory.java:319)           在android.webkit.WebViewFactory.getProviderClass(WebViewFactory.java:383)           在android.webkit.WebViewFactory.getProvider(WebViewFactory.java:194)           在android.webkit.CookieManager.getInstance(CookieManager.java:39)           在com.facebook.react.modules.network.ForwardingCookieHandler.getCookieManager(ForwardingCookieHandler.java:162)           在com.facebook.react.modules.network.ForwardingCookieHandler.get(ForwardingCookieHandler.java:59)           在com.facebook.react.modules.websocket.WebSocketModule.getCookie(WebSocketModule.java:373)           在com.facebook.react.modules.websocket.WebSocketModule.connect(WebSocketModule.java:95)           在java.lang.reflect.Method.invoke(本机方法)           在com.facebook.react.bridge.JavaMethodWrapper.invoke(JavaMethodWrapper.java:372)           在com.facebook.react.bridge.JavaModuleWrapper.invoke(JavaModuleWrapper.java:160)           在com.facebook.react.bridge.queue.NativeRunnable.run(本机方法)           在android.os.Handler.handleCallback(Handler.java:790)           在android.os.Handler.dispatchMessage(Handler.java:99)           在com.facebook.react.bridge.queue.MessageQueueThreadHandler.dispatchMessage(MessageQueueThreadHandler.java:29)           在android.os.Looper.loop(Looper.java:164)           在com.facebook.react.bridge.queue.MessageQueueThreadImpl $ 3.run(MessageQueueThreadImpl.java:192)           在java.lang.Thread.run(Thread.java:764)2018-10-14 05:08:59.583 22125-22176 / com.samplernwsproj E /未知:ReactNative:   本机呼叫异常       android.util.AndroidRuntimeException:android.webkit.WebViewFactory $ MissingWebViewPackageException:失败   加载WebView提供程序:未安装WebView           在android.webkit.WebViewFactory.getProviderClass(WebViewFactory.java:423)           在android.webkit.WebViewFactory.getProvider(WebViewFactory.java:194)           在android.webkit.CookieManager.getInstance(CookieManager.java:39)           在com.facebook.react.modules.network.ForwardingCookieHandler.getCookieManager(ForwardingCookieHandler.java:162)           在com.facebook.react.modules.network.ForwardingCookieHandler.get(ForwardingCookieHandler.java:59)           在com.facebook.react.modules.websocket.WebSocketModule.getCookie(WebSocketModule.java:373)           在com.facebook.react.modules.websocket.WebSocketModule.connect(WebSocketModule.java:95)           在java.lang.reflect.Method.invoke(本机方法)           在com.facebook.react.bridge.JavaMethodWrapper.invoke(JavaMethodWrapper.java:372)           在com.facebook.react.bridge.JavaModuleWrapper.invoke(JavaModuleWrapper.java:160)           在com.facebook.react.bridge.queue.NativeRunnable.run(本机方法)           在android.os.Handler.handleCallback(Handler.java:790)           在android.os.Handler.dispatchMessage(Handler.java:99)           在com.facebook.react.bridge.queue.MessageQueueThreadHandler.dispatchMessage(MessageQueueThreadHandler.java:29)           在android.os.Looper.loop(Looper.java:164)           在com.facebook.react.bridge.queue.MessageQueueThreadImpl $ 3.run(MessageQueueThreadImpl.java:192)           在java.lang.Thread.run(Thread.java:764)        原因:android.webkit.WebViewFactory $ MissingWebViewPackageException:失败   加载WebView提供程序:未安装WebView           在android.webkit.WebViewFactory.getWebViewContextAndSetProvider(WebViewFactory.java:319)           在android.webkit.WebViewFactory.getProviderClass(WebViewFactory.java:383)           在android.webkit.WebViewFactory.getProvider(WebViewFactory.java:194)           在android.webkit.CookieManager.getInstance(CookieManager.java:39)           在com.facebook.react.modules.network.ForwardingCookieHandler.getCookieManager(ForwardingCookieHandler.java:162)           在com.facebook.react.modules.network.ForwardingCookieHandler.get(ForwardingCookieHandler.java:59)           在com.facebook.react.modules.websocket.WebSocketModule.getCookie(WebSocketModule.java:373)           在com.facebook.react.modules.websocket.WebSocketModule.connect(WebSocketModule.java:95)

0 个答案:

没有答案