2

Currently using the latest version of socket.io. I'm wondering how to connect to a namespaced socket via python (using the websocket module for instance).

My main goal is to send a message to the server. Just that. Is there anyone who knows how I can achieve this ?

I saw the SocketIO-client package on Pypi but it seems that it only works with Python 2.7 and I'm using 3.3.4.

I tried this what is said on this post and adaptating it to my python version. Though that's what I get in my hskey object :

>>> h = http.client.HTTPConnection('localhost:8008')
>>> h.request('POST', '/socket.io/1')
>>> resp = h.getresponse()
>>> hskey = resp.read()
>>> hskey
b'{"code":0,"message":"Transport unknown"}'
Community
  • 1
  • 1
Depado
  • 4,811
  • 3
  • 41
  • 63
  • Did you ever find a solution to this? If so, please post it in an answer. I am having the same problem. – Stephen Feb 19 '15 at 20:00
  • I think I never managed to solve the problem there. I just switched to something else I think (can't remember) – Depado Feb 23 '15 at 16:56

0 Answers0