I'm creating just a simple bot for TwitchTV and recently they updated their MOTD to:
=======
Looking up
irc.twitch.tv Connecting to
irc.twitch.tv ( 23199.9.250.229:6667 )
Connected. Now logging in.
CAP :Unknown command
Welcome, GLHF!
Your host is
tmi.twitch.tvThis server is rather new
-
-
You are in a maze of twisty passages, all alike.
>
====== (Not part of MOTD)
Which causes an exception at the first "-"
====
[main] ERROR org.pircbotx.PircBotX - Exception encountered when parsing line
java.lang.IndexOutOfBoundsException: Index: 1, Size: 1
at java.util.ArrayList.rangeCheck(ArrayList.java:638)
at java.util.ArrayList.get(ArrayList.java:414)
at org.pircbotx.ServerInfo.parse004(ServerInfo.java:113)
at org.pircbotx.ServerInfo.parse(ServerInfo.java:106)
at org.pircbotx.InputParser.processServerResponse(InputParser.java:709)
at org.pircbotx.InputParser.handleLine(InputParser.java:323)
at org.pircbotx.PircBotX.startLineProcessing(PircBotX.java:275)
at org.pircbotx.PircBotX.connect(PircBotX.java:236)
at org.pircbotx.PircBotX.startBot(PircBotX.java:151)
at hitabotx.HitaBotX.main(HitaBotX.java:56)
====
Can this be safety ignored? Going back in the exception it seems to bring me to 'serverName' which I assume it tries using "-" for the Server Name. Should I just ignore this as it ... doesn't seem to cause an issue or report this on the issue tracker?
I tried my bot on Freenode and it doesn't cause this exception, so it's not something I put in the bot. (Also expecting Twitch to change the MOTD is like asking a wall to move)
Thanks!