Hi everyone, I have a problem with chat bot. Over time I get blank IRC message and after short time I don’t get any messages from chat. Help me please, what wrong?!
Sounds like your bot is not responding to PING’s correctly and is being disconnected from chat, which your bot is also not catching
No, my bot catching Ping correctly:
I discovered, and I think it was Barry or another person that pointed it out to me, that you at times have to send a PING yourself. For example, I found with a bot that I work on, that if users run it from the Azure Cloud, that it times out well before Twitch sends a PING. Have you tried implementing a PING yourself more frequently? This is precisely what I had to do in some instances.
Yeah, most of my bots don’t get a ping in a paticular timeframe so I/the bot pings itself.
My next suggestion would be to pull the RAW IRC lines and see if theres an error or disconnect.
And/or if you bot framework has a PING timeout for “missed”(never sent) server pings
Are you catching any particular errors from your IRC connection to see if the connection is closed by either the server or client? I do see that you stop receiving messages, but nothing else of value, unfortunately.
How to catch errors?
I do not know what language you are using for your bot. I use Java and wrote an interface that uses WebSockets to communicate with Twitch WS IRC servers. For that, internally, I catch any error that comes from the WebSocket interface and log it and then attempt a reconnect, for example.
Your solution would be based on (a) what language you are using and (b) what library (if any) you are using.
This topic was automatically closed 30 days after the last reply. New replies are no longer allowed.