Bug - Fixed Chat issues - r15180

Here's what happened:

I tried to post a message to chat in the relay browser. The message never showed up. I then went into mafia chat, noticed it thought I wasn't listening to the channel I just attempted to post in, so typed /l [channelname] into KoLmafia chat to force things. That also had no immediate effect. Frustrated, I logged out... and that's when I got a debug log! I wonder if the lack of response from KoL was due to lag.

Code:
=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
          KoLmafia v16.7 r15180, Mac OS X, Java 1.8.0_25
=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
 Please note: do not post this log in the KoLmafia thread of KoL's
 Gameplay-Discussion forum. If you would like the KoLmafia dev team
 to look at it, please write a bug report at kolmafia.us. Include
 specific information about what you were doing when you made this
 and include this log as an attachment.
=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
 Timestamp: Tue Jan 13 05:11:57 EST 2015
=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=


Unexpected error, debug log printed.
class java.lang.StringIndexOutOfBoundsException: String index out of range: -1
java.lang.StringIndexOutOfBoundsException: String index out of range: -1
	at java.lang.String.substring(String.java:1954)
	at net.sourceforge.kolmafia.chat.ChatParser.parseListen(ChatParser.java:191)
	at net.sourceforge.kolmafia.chat.ChatSender.processResponse(ChatSender.java:233)
	at net.sourceforge.kolmafia.chat.ChatSender.sendRequest(ChatSender.java:218)
	at net.sourceforge.kolmafia.chat.ChatSender.sendMessage(ChatSender.java:173)
	at net.sourceforge.kolmafia.chat.ChatSender.sendMessage(ChatSender.java:124)
	at net.sourceforge.kolmafia.swingui.ChatFrame$ChatPanel$ChatEntryListener.submitChat(ChatFrame.java:452)
	at net.sourceforge.kolmafia.swingui.ChatFrame$ChatPanel$ChatEntryListener.execute(ChatFrame.java:408)
	at net.sourceforge.kolmafia.swingui.listener.ThreadedListener.run(ThreadedListener.java:239)
	at net.sourceforge.kolmafia.RequestThread$SequencedRunnable.run(RequestThread.java:418)
	at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:511)
	at java.util.concurrent.FutureTask.run(FutureTask.java:266)
	at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1142)
	at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:617)
	at java.lang.Thread.run(Thread.java:745)

EDIT: Never mind, it looks like the lack of chat response is coincident with a KoL server freeze. Still not sure why KoLmafia barfed, though.
 
Last edited:

Veracity

Developer
Staff member
Revision 15185 protects against KoL sending back an empty response. (Or not sending a response at all, if you have opted to use the harmful "request timeout" setting.)
 
Top