SocketIOSharp icon indicating copy to clipboard operation
SocketIOSharp copied to clipboard

Client not connecting

Open givowo opened this issue 5 years ago • 5 comments

I have a js socket.io server running on port 3000 and im unable to connect to it. Here is the code im using:

client = new SocketIOClient(new SocketIOClientOption(EngineIOScheme.http, "localhost", 3000));
client.On(SocketIOEvent.CONNECTION, () =>
{
   Console.WriteLine("Good");
});
client.Connect();

i have logs in my js code that lets me know when someone is connected. I can see the logs when connecting with a browser, but not with this

givowo avatar Dec 09 '20 20:12 givowo

Im using socket.io 3.0.0 currently, ill install 2.3 to see if that works

givowo avatar Dec 10 '20 15:12 givowo

Update: i was able to get the example working perfectly, so ill just use it as a base and copy over my code.

givowo avatar Dec 10 '20 15:12 givowo

2.4v JS client also works fine

IliasPoli avatar Feb 10 '21 12:02 IliasPoli

hey i have the very same problem! server in node.js with socket.io version 4.1.2, and I cant get this client-example to connect to it. How did you solve? I hope not by downgrading, since I'm basically using this package because I need a 4.x client in c#

Confirming this works.

Server : C# Client : nodejs client should be 2.4v below (3.1.3 does not work)

ralphskie avatar Jul 01 '21 03:07 ralphskie