Bug - Fixed Crash, Bug, Ouch!

Spiny

Member
r8392

While adventuring in the relay browser, the browser started to hang excessively. The last thing I saw in the CLI was receiving experience for my last fight. When this happens, I generally close the relay browser and it knocks things loose. I closed the browser and tried to relaunch it and nothing happened, so I tried to log out thru mafia, so I could ultimately relog in. My shell was full of spam:

Code:
Exception in thread "LocalRelayAgent6" java.lang.ArrayIndexOutOfBoundsException: 33                                                                             
        at javax.swing.plaf.basic.BasicListUI.updateLayoutState(BasicListUI.java:1351)                                                                          
        at javax.swing.plaf.basic.BasicListUI.maybeUpdateLayoutState(BasicListUI.java:1294)                                                                     
        at javax.swing.plaf.basic.BasicListUI$Handler.valueChanged(BasicListUI.java:2610)                                                                       
        at javax.swing.DefaultListSelectionModel.fireValueChanged(DefaultListSelectionModel.java:167)                                                           
        at javax.swing.DefaultListSelectionModel.fireValueChanged(DefaultListSelectionModel.java:147)                                                           
        at javax.swing.DefaultListSelectionModel.fireValueChanged(DefaultListSelectionModel.java:194)                                                           
        at javax.swing.DefaultListSelectionModel.removeIndexInterval(DefaultListSelectionModel.java:660)                                                        
        at javax.swing.plaf.basic.BasicListUI$Handler.intervalRemoved(BasicListUI.java:2588)                                                                    
        at javax.swing.AbstractListModel.fireIntervalRemoved(AbstractListModel.java:161)                                                                        
        at net.java.dev.spellcast.utilities.LockableListModel.fireIntervalRemoved(LockableListModel.java:218)                                                   
        at net.java.dev.spellcast.utilities.LockableListModel.removeVisibleElement(LockableListModel.java:613)                                                  
        at net.java.dev.spellcast.utilities.LockableListModel.removeVisibleElement(LockableListModel.java:584)
        at net.java.dev.spellcast.utilities.LockableListModel.remove(LockableListModel.java:576)
        at net.java.dev.spellcast.utilities.LockableListModel$ListModelIterator.remove(LockableListModel.java:498)
        at net.java.dev.spellcast.utilities.LockableListModel.retainAll(LockableListModel.java:661)
        at net.sourceforge.kolmafia.swingui.GearChangeFrame.updateEquipmentList(GearChangeFrame.java:669)
        at net.sourceforge.kolmafia.swingui.GearChangeFrame.ensureValidSelections(GearChangeFrame.java:477)
        at net.sourceforge.kolmafia.swingui.GearChangeFrame.access$1300(GearChangeFrame.java:79)
        at net.sourceforge.kolmafia.swingui.GearChangeFrame$EquipPanel.setEnabled(GearChangeFrame.java:219)
        at net.sourceforge.kolmafia.KoLmafia.updateDisplayState(KoLmafia.java:652)
        at net.sourceforge.kolmafia.KoLmafia.updateDisplay(KoLmafia.java:633)
        at net.sourceforge.kolmafia.request.GenericRequest.run(GenericRequest.java:1056)
        at net.sourceforge.kolmafia.chat.ChatPoller.getEntries(ChatPoller.java:135)
        at net.sourceforge.kolmafia.request.RelayRequest.handleChat(RelayRequest.java:1327)
        at net.sourceforge.kolmafia.request.RelayRequest.run(RelayRequest.java:1454)
        at net.sourceforge.kolmafia.LocalRelayAgent.readServerResponse(LocalRelayAgent.java:420)
        at net.sourceforge.kolmafia.LocalRelayAgent.performRelay(LocalRelayAgent.java:132)
        at net.sourceforge.kolmafia.LocalRelayAgent.run(LocalRelayAgent.java:109)

I'm not sure what caused that, perhaps me being too fast for lag and being a bit hasty in closing things down? I'm not sure. In any event, I relogged in and to my surprise, I was dead. I recently read the kolmafia thread at the kol forums so I know this can happen, I'm just surprised as I didn't realize I was in a new fight. Checking my session log shows the following:

Code:
[1733] Battlefield (Frat Uniform)
Encounter: War Hippy Elite Rigger
Round 0: Tango Clubdancer loses initiative!
Round 1: war hippy elite rigger takes 1 damage.
Round 1: war hippy elite rigger takes 4 damage.
Round 1: war hippy elite rigger takes 5 damage.
You lose 28 hit points
Round 1: Tango Clubdancer casts WAVE OF SAUCE!
Round 2: war hippy elite rigger takes 154 damage.
You gain 16 hit points
You gain 5 Mana Points
You acquire an effect: Soul Freeze (duration: 1 Adventure)
Round 2: Tot looks at a nearby window with his blue eye. You write your name in the frost that forms.
Round 2: war hippy elite rigger takes 3 damage.
Round 2: war hippy elite rigger takes 3 damage.
Round 2: war hippy elite rigger takes 4 damage.
You lose 33 hit points
Round 2: Tango Clubdancer casts WAVE OF SAUCE!
Round 3: war hippy elite rigger takes 150 damage.
You gain 16 hit points
You gain 4 Mana Points
You gain 25 Mana Points
Round 3: Tot's red eye glances at an ant crawling at your feet. The ant turns red and begins to smoke. Not, like, cigarettes... Like something that's about to burst into flames.
You acquire an item: pink clay bead
You gain 10 Muscleboundness
You gain 29 Wizardliness
You gain 11 Chutzpah
You gain a Moxie point!
4 hippies defeated; 368 down, 632 left.

[1733] Battlefield (Frat Uniform)

=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
               Player Snapshot
=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=

So the session log reflects the new log in after what appears to be an incomplete fight--the details of which is not in my session log, but it is in my cli as part of the login:

Code:
Validating login server (www3.kingdomofloathing.com)...
Redirected to www4.kingdomofloathing.com...
512 players online.
Sending login request...
Initializing session for Tango Clubdancer...
Refreshing session data...
Synchronizing moon data...
Retrieving character data...
Round 0: Tango Clubdancer attacks!
Strategy: (omitted).kolmafia/ccs/tangodefault.ccs [default]

Round 1: takes 1 damage.
Round 1: takes 8 damage.
Round 1: takes 5 damage.
You lose 27 hit points
Round 1: Tango Clubdancer attacks!
Round 2: Tot's red eye glances at an ant crawling at your feet. The ant turns red and begins to smoke. Not, like, cigarettes... Like something that's about to burst into flames.
Round 2: takes 2 damage.
Round 2: takes 6 damage.
Round 2: takes 4 damage.
You lose 28 hit points
Round 2: Tango Clubdancer attacks!
Round 3: A balloon floats into the path of Tot's blue eye. The balloon falls to the ground and shatters. Science is awesome!
Round 3: takes 1 damage.
Round 3: takes 8 damage.
Round 3: takes 4 damage.
You lose 28 hit points
Round 3: Tango Clubdancer attacks!
Round 4: Tot's yellow eye gazes upon a passing frat boy. There's a gentle *pop,* then just the lingering scent of cheap cologne and desperation.
Round 4: takes 2 damage.
Round 4: takes 8 damage.
Round 4: takes 4 damage.
You lose 27 hit points
Round 4: Tango Clubdancer attacks!
Round 5: Tot looks at a passing frat boy with his blue eye. The frat boy pulls his popped collar up even higher to cover his ears.
Round 5: takes 1 damage.
Round 5: takes 5 damage.
Round 5: takes 4 damage.
You lose 28 hit points
Retrieving familiar data...
Familiar data retrieved.
Refreshing closet...
Updating consumable items...
Updating miscellaneous items...
Refreshing stickers...
Retrieving campground data...
Retrieving storage list...
Session data refreshed.
Visiting Crimbo Tree in clan VIP lounge
8 days until Dependence Day, Mysticism bonus tomorrow (not today).
37 prices updated from http://kolmafia.us/scripts/updateprices.php?action=getmap

Mind you, the above did not use my ccs, though the action is set to use the ccs and it appears to want to use it.

In response to someone else, Jason addressed this in the KoL forums:

Code:
that's a known problem that nobody has found the time to properly fix. It's tricky because there's no way for mafia to determine most aspects of your character state, as needed for many of mafia's features to operate correctly, until the combat is resolved. Note that it's NOT actually using your combat settings at all, it's just attacking - since it's unable to read your character sheet to determine what other options you might actually have!

The best advice I can give at this point is to briefly log in directly from the browser when this happens, then re-login with mafia once you've finished the combat. 
-by JasonHarper

In conclusion, I wasn't aware a new battle had started when I lagged/crashed or I'd have logged in manually to avoid death, but that's really my own fault for not double-checking first. My real question/bug report/issue is the spam in my shell and what the cause of it was? So I can avoid it in the future if it was my fault....

Thanks!
 
Top