Skip to content

ChromeDevTools: If you close the socket the app will crash on the device/emulator #1122

@vhristov5555

Description

@vhristov5555
  1. Run tns debug android
  2. Open the generated link in Chrome
  3. Refresh the link in the Chrome browser
    Actual: The app will crash on the device/emulator. Also this error will be loged in the console:
System.err: java.io.IOException: Broken pipe
System.err: 	at android.net.LocalSocketImpl.write_native(Native Method)
System.err: 	at android.net.LocalSocketImpl.access$700(LocalSocketImpl.java:33)
System.err: 	at android.net.LocalSocketImpl$SocketOutputStream.write(LocalSocketImpl.java:145)
System.err: 	at fi.iki.elonen.NanoWSD$WebSocketFrame.write(NanoWSD.java:700)
System.err: 	at fi.iki.elonen.NanoWSD$WebSocket.sendFrame(NanoWSD.java:271)
System.err: 	at fi.iki.elonen.NanoWSD$WebSocket.close(NanoWSD.java:135)
System.err: 	at fi.iki.elonen.NanoWSD$WebSocket.handleCloseFrame(NanoWSD.java:184)
System.err: 	at fi.iki.elonen.NanoWSD$WebSocket.handleWebsocketFrame(NanoWSD.java:218)
System.err: 	at fi.iki.elonen.NanoWSD$WebSocket.readWebsocket(NanoWSD.java:246)
System.err: 	at fi.iki.elonen.NanoWSD$WebSocket.access$200(NanoWSD.java:65)
System.err: 	at fi.iki.elonen.NanoWSD$WebSocket$1.send(NanoWSD.java:88)
System.err: 	at fi.iki.elonen.NanoHTTPD$HTTPSession.execute(NanoHTTPD.java:1011)
System.err: 	at fi.iki.elonen.NanoHTTPD$LocalClientHandler.run(NanoHTTPD.java:251)
System.err: 	at java.lang.Thread.run(Thread.java:818)
ActivityManager: Process org.nativescript.templatehelloworldng (pid 9644) has died

Expected: The app should not crash. Also you should be able to continue debugging.

Metadata

Metadata

Labels

Type

No type

Projects

No projects

Milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions