stephenmcd / gnotty

IRC web client and bot framework
http://gnotty.jupo.org
BSD 2-Clause "Simplified" License
162 stars 27 forks source link

Connection timeout to the chat server #22

Closed Adastra-thw closed 10 years ago

Adastra-thw commented 10 years ago

Hello! I'm testing gnotty to use it in my project and I've configured the application and I could see the "login" interface, however when I try to join to any channel I get this error: "Took too long to connect, please try again" I've checked the network connections and I'm seeing this one "http://0.0.31.144:8000/socket.io/1/?t=1391971501568&jsonp=0" This connection is performed when I click on the join botton. I've checked the gnotty.js file and the properties used and everything is ok, however... the js socket.io seems to "change" the host from "localhost" or "127.0.0.1" to "0.0.31.144" and I don't know why... I've re-readed the guide a lot of times and I'm still don't get where is the error. I'm using the files in the master branch. Thank you!

Adastra-thw commented 10 years ago

Well... There's a bug in the socket.io library. When you use 'localhost' or '127.0.0.1' as host, the library "magically" decides to change the host to: "0.0.31.144" how to resolve that? In my case: GNOTTY_HTTP_HOST="http://localhost" Note the http:// at the start. With that, socket.io performs the connection properly. This is the only problem that I've found. Gnotty works very fine. Thank you for develop it