Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

The requested item could not be loaded on Android 9 via 3G #92

Open
Kolyall opened this issue Nov 1, 2018 · 0 comments
Open

The requested item could not be loaded on Android 9 via 3G #92

Kolyall opened this issue Nov 1, 2018 · 0 comments

Comments

@Kolyall
Copy link

Kolyall commented Nov 1, 2018

Device: Android 9.0, Google Pixel 2 XL

 api('io.socket:socket.io-client:1.0.0') {
        exclude group: 'org.json', module: 'json'
    }

When I connecting to socket via Wi-Fi all works fine. But when I trying to connect via Mobile Internet the error occurs

mSocket.on(Socket.EVENT_CONNECT_ERROR, new Emitter.Listener() {
                @Override
                public void call(Object... args) {
                  if (args.length> 0 && args[0] instanceof EngineIOException){
                        ((EngineIOException)args[0]).printStackTrace();
                    }
               }
            });

Packet data:
parser error
EngineIOException:

io.socket.engineio.client.EngineIOException: server error
    at io.socket.engineio.client.Socket.onPacket(Socket.java:547)
    at io.socket.engineio.client.Socket.access$1000(Socket.java:36)
    at io.socket.engineio.client.Socket$5.call(Socket.java:335)
    at io.socket.emitter.Emitter.emit(Emitter.java:117)
    at io.socket.engineio.client.Transport.onPacket(Transport.java:126)
    at io.socket.engineio.client.transports.Polling.access$700(Polling.java:18)
    at io.socket.engineio.client.transports.Polling$2.call(Polling.java:127)
    at io.socket.engineio.parser.Parser.decodePayload(Parser.java:222)
    at io.socket.engineio.client.transports.Polling._onData(Polling.java:135)
    at io.socket.engineio.client.transports.Polling.onData(Polling.java:102)
    at io.socket.engineio.client.transports.PollingXHR$5$1.run(PollingXHR.java:125)
    at io.socket.thread.EventThread$2.run(EventThread.java:80)
    at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1167)
    at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:641)
    at java.lang.Thread.run(Thread.java:764)

Why polling got data as xml on Mobile Internet? And Content-Type: text/vnd.wap.wm?

neio.client.transports.Polling: polling got data <?xml version="1.0"?>
<!DOCTYPE wml PUBLIC "-//WAPFORUM//DTD WML 1.1//EN" "http://www.wapforum.org/DTD/wml_1.1.xml">

<wml>
<card id="FEHLER" title="ERROR">
<p>
The requested item could not be loaded <br/>
Wrong MIME-Type
<do type="prev" label="back">
<prev/>
</do>

</p>
</card>
</wml>

Here is log from logger:

2018-11-01 11:55:26.168 : io.socket.client.IO: ignoring socket cache for http://myserverexample.com:80/
2018-11-01 11:55:26.187 : io.socket.client.Manager: readyState CLOSED
2018-11-01 11:55:26.189 : io.socket.client.Manager: opening http://myserverexample.com:80/
2018-11-01 11:55:26.192 : io.socket.client.Manager: connection attempt will timeout after 20000
2018-11-01 11:55:26.195 : .socket.engineio.client.Socket: creating transport 'polling'
2018-11-01 11:55:26.199 : .socket.engineio.client.Socket: setting transport polling
2018-11-01 11:55:26.202 : neio.client.transports.Polling: polling
2018-11-01 11:55:26.203 : o.client.transports.PollingXHR: xhr poll
2018-11-01 11:55:26.205 : o.client.transports.PollingXHR: xhr open GET: http://myserverexample.com/socket.io/?EIO=3&transport=polling
2018-11-01 11:55:26.208 : o.client.transports.PollingXHR: sending xhr with url http://myserverexample.com/socket.io/?EIO=3&transport=polling | data null
2018-11-01 11:55:26.310 : neio.client.transports.Polling: polling got data <?xml version="1.0"?>
<!DOCTYPE wml PUBLIC "-//WAPFORUM//DTD WML 1.1//EN" "http://www.wapforum.org/DTD/wml_1.1.xml">

<wml>
<card id="FEHLER" title="ERROR">
<p>
The requested item could not be loaded <br/>
Wrong MIME-Type
<do type="prev" label="back">
<prev/>
</do>

</p>
</card>
</wml>

2018-11-01 11:55:26.216 : Request: +------ Request ------------------------------------------------------------------------
2018-11-01 11:55:26.217 : Request: ¦ URL: http://myserverexample.com/socket.io/?EIO=3&transport=polling
2018-11-01 11:55:26.218 : Request: ¦
2018-11-01 11:55:26.218 : Request: ¦ Method: @GET
2018-11-01 11:55:26.218 : Request: ¦
2018-11-01 11:55:26.219 : Request: ¦ Headers:
2018-11-01 11:55:26.219 : Request: ¦ + Accept: application/json
2018-11-01 11:55:26.219 : Request: ¦ + X-Request-ID: 43cb7c38-bf18-492a-beea-ceefbe2a8a9a
2018-11-01 11:55:26.221 : Request: ¦ + Accept-Language: ru-BY
2018-11-01 11:55:26.221 : Request: ¦ + Authorization: eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJpZCI6IjViNGM4YjdhMTY0ZGIwMDIxOGE4YjM1ZiIsImhhc2giOiIk
2018-11-01 11:55:26.222 : Request: ¦ MmEkMTAkM1hTM09NbVhxVjNITzVQTTFnTlBxLkE1LmltNElIR291S3E1Y1A1b2ZhUWxsRTlMaFhrNC4iLCJyb2xlIjoiNTlmODdlZTk2OWQzNG
2018-11-01 11:55:26.222 : Request: ¦ I0Njc2N2YyM2M5IiwiaWF0IjoxNTQxMDYyNDc5fQ.1wO1CYy5M-xJXOHz7pZ5-qRYbO87WZ1Ji5JE7SUr6Vc
2018-11-01 11:55:26.223 : Request: ¦

2018-11-01 11:55:26.224 : Request: ¦ Omitted request body
2018-11-01 11:55:26.224 : Request: +---------------------------------------------------------------------------------------
2018-11-01 11:55:26.290 : Response: +------ Response -----------------------------------------------------------------------
2018-11-01 11:55:26.291 : Response: ¦ /socket.io/ - is success : true - Received in: 64ms
2018-11-01 11:55:26.292 : Response: ¦
2018-11-01 11:55:26.293 : Response: ¦ Status Code: 200 / OK
2018-11-01 11:55:26.295 : Response: ¦
2018-11-01 11:55:26.297 : Response: ¦ Headers:
2018-11-01 11:55:26.297 : Response: ¦ + Access-Control-Allow-Origin: *
2018-11-01 11:55:26.298 : Response: ¦ + Cache-Control: no-cache
2018-11-01 11:55:26.300 : Response: ¦ + Content-Length: 333
2018-11-01 11:55:26.300 : Response: ¦ + Content-Type: text/vnd.wap.wml
2018-11-01 11:55:26.301 : Response: ¦ + Date: Thu, 01 Nov 2018 08:55:26 GMT
2018-11-01 11:55:26.301 : Response: ¦ + Set-Cookie: io=XbkfAUdWipwY_YUsAC2O; Path=/; HttpOnly
2018-11-01 11:55:26.304 : Response: ¦

2018-11-01 11:55:26.304 : Response: ¦ Omitted response body
2018-11-01 11:55:26.305 : Response: +---------------------------------------------------------------------------------------

2018-11-01 11:55:26.313 : .socket.engineio.client.Socket: socket received: type 'error', data 'parser error'
2018-11-01 11:55:26.316 : .socket.engineio.client.Socket: socket error io.socket.engineio.client.EngineIOException: server error
2018-11-01 11:55:26.316 : io.socket.client.Manager: connect_error
2018-11-01 11:55:26.317 : io.socket.client.Manager: cleanup
2018-11-01 11:55:26.320 : io.socket.client.Manager: disconnect
2018-11-01 11:55:26.321 : io.socket.client.Manager: cleanup
2018-11-01 11:55:26.322 : .socket.engineio.client.Socket: socket close with reason: forced close
2018-11-01 11:55:26.323 : neio.client.transports.Polling: transport open - closing
2018-11-01 11:55:26.324 : neio.client.transports.Polling: writing close packet
2018-11-01 11:55:26.325 : o.client.transports.PollingXHR: xhr open POST: http://myserverexample.com/socket.io/?EIO=3&transport=polling
2018-11-01 11:55:26.326 : o.client.transports.PollingXHR: sending xhr with url http://myserverexample.com/socket.io/?EIO=3&transport=polling | data 1:1
2018-11-01 11:55:26.327 : .socket.engineio.client.Socket: socket closing - telling transport to close
2018-11-01 11:55:26.328 : io.socket.client.Manager: disconnect
2018-11-01 11:55:26.328 : io.socket.client.Manager: cleanup
2018-11-01 11:55:26.330 : io.socket.client.Manager: disconnect
2018-11-01 11:55:26.331 : io.socket.client.Manager: cleanup
2018-11-01 11:55:26.331 : io.socket.client.Manager: disconnect
2018-11-01 11:55:26.332 : io.socket.client.Manager: cleanup
@Kolyall Kolyall changed the title The requested item could not be loaded on Android 9 The requested item could not be loaded on Android 9 via 3G Nov 1, 2018
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant