Git Product home page Git Product logo

Comments (4)

darrachequesne avatar darrachequesne commented on September 24, 2024

Hi! It seems like there is a problem when establishing the SSL connection. Did you find the culprit?

Reference: https://developer.android.com/privacy-and-security/security-config

from socket.io-client.

darrachequesne avatar darrachequesne commented on September 24, 2024

For future readers:

Please check our React Native guide: https://socket.io/how-to/use-with-react-native

I'm closing this now, please reopen if needed.

from socket.io-client.

enaluz avatar enaluz commented on September 24, 2024

@darrachequesne I'm experiencing a similar issue on version 4.7.5 (expo 49.0.21). I'm pointing to a non-local api (not on localhost), but the connection never happens successfully.

It works perfectly fine on iOS, but on Android, no connection happens, nor is there an error message. No logs of importance seem to come up when I run expo start in debug mode either.

The socket-io docs you listed above only apply for development right?

When I remove the transports field, it works perfectly fine 🤔

    globalSocket = io(Env.apiUrl, {
      auth: { token },
      transports: ['websocket'],
      ...
    });

from socket.io-client.

darrachequesne avatar darrachequesne commented on September 24, 2024

@enaluz plain HTTP or HTTPS? Self-signed certificate?

If it works without transports and not with transports: ['websocket'], then this might indicates that something between the client and the server is preventing the WebSocket connection.

See also: https://socket.io/docs/v4/troubleshooting-connection-issues/

from socket.io-client.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.