Feature - Implemented KoLmafia and Java 7 are incompatible

lostcalpolydude

Developer
Staff member
If you install Java 7, KoLmafia will no longer work properly. If this has happened for you, you will need to uninstall Java 7 and install an older version. The latest Java 6 version can be downloaded from here.
 

holatuwol

Developer
It turns out that Java 7 compatibility will require dropping Foxtrot, so you'll see commits over time which will slowly remove the different parts of KoLmafia that make use of it. Once you see Foxtrot formally removed, we'll revisit this to see if KoLmafia works under Java 7 in Windows.
 

Catch-22

Active member
It turns out that Java 7 compatibility will require dropping Foxtrot, so you'll see commits over time which will slowly remove the different parts of KoLmafia that make use of it. Once you see Foxtrot formally removed, we'll revisit this to see if KoLmafia works under Java 7 in Windows.

Yeah just thought I'd chime in that I've been using KoLmafia in CLI mode since Java 7 was in beta (crazy, right?).

Running the latest build as we speak:
Code:
KoLmafia v14.8 r9933
Released on September 15, 2011

Currently Running on Windows Vista
Local Directory is C:\KoLmafia
Using Java 1.7.0
 
Just tested KoLmafia on JDK 7 Developer Preview for Mac OS X.

It hangs after logging in and never shows a GUI. I wonder if Foxtrot has something to do with this?
 

holatuwol

Developer
Okay, KoLmafia appears to work with Java 7 on Ubuntu 11.10, which shipped with openjdk-7. Anyone on Windows who wants to run some tests to see how things are going?
 

Kirkpatrick

New member
Mafia r9957 seems to be working fine under JRE 7u1 on Windows 7 Ultimate 64 for me. Is there anything I can/should do to test it more than aftercore farming / ascending today?
 

brianjbatchelor

New member
Upgrading to Java 7 fixed the "Pause Event in Dispatch Thread" error I was having, but now I seem to be logging in after every command. Lots of PW Hash mismatches from GM scripts:

Password hash mismatch
Path: "/inv_use.php?pwd==3&whichitem=4502&ajax=1&_=1320353617054"
Validating login server (www.kingdomofloathing.com)...
926 players online.
Sending login request...
Synchronizing moon data...
Requests complete.

Validating login server (www.kingdomofloathing.com)...
926 players online.
Sending login request...
Synchronizing moon data...
Requests complete.

You have the maximum number of AT buffs already.
You acquire an effect: Donho's Bubbly Ballad (duration: 60 Adventures)
Validating login server (www.kingdomofloathing.com)...
925 players online.
Sending login request...
Synchronizing moon data...
Requests complete.

Validating login server (www.kingdomofloathing.com)...
925 players online.
Sending login request...
Synchronizing moon data...
Requests complete.
 
I'm not sure how much of this is from upgrading to java 7 or other changes made to mafia code, but I'm seeing a LOT of slowdowns and stalls in mafia now. During any action, really, but automating turns makes it stand out the most since it's constant. It can take mafia several seconds to respond to actions, like clicking a tab in the GUI, or typing in chat, when I'm automating turns. My processor load never exceeds 30%, and I've plenty of memory left. But even regular actions have problems. Even before switching to j7 I was seeing similar issues when eating and drinking (program suddenly stops responding for a second or two, then suddenly the action finishes all at once). It just seems to have gotten a lot worse since I upgraded to j7 yesterday.

I've also done several macro'd combats by adventuring in the relay browser, and tabbed over to mafia to see that it still hadn't processed the results of the fight, and have to wait a little bit before it unsticks and displays the results.
 
slyz said:
This seems fixed for me, as of r9948.

I'm in 9961, and was definitely in a higher version than 9948 when I was last aggravated by this issue. Automating turns on another character in 9961 right now and I'm noticing a slight sluggishness, but not the several seconds worth I've seen before. Doesn't mean it doesn't still do that, just not doing it to me right now.

EDIT: Yep, there it goes. Do a macro'd combat in the relay browser, tab back, sit and wait over a second for mafia to catch up and display the rounds in the gCLI.

During automation, I'm accustomed to seeing "Request X of N in progress..." before each adventure, but sometimes mafia stalls at the end of one combat, and then suddenly BLAM another combat appears (and in this case scrolls the previous combat entirely, and chunks of the most recent one, off the screen, since I'm prolonging the fights with an NPZR).

So, yeah, just a lot of sluggishness, and "jerky" output into the CLI. Just seems to stall at somewhat random times at somewhat random places and takes a visually noticeable amount of time to recover. Output that once felt like a fluid stream now comes in jerky chunks, and program responsiveness goes down or outright vanishes during the jerks.
 
Last edited:
I'm not running Java 7 either, and the issue is only partially fixed.

Sometimes the relay browser stops responding for no apparent reason - KoLmafia itself is still responding, as is KoL. Restarting it fixes this temporarily, but chat goes away so I must re-enter it.
Also, I can consistently reproduce the unresponsive GUI issue when logging out of KoLmafia using the Quit KoLMafia command in Mac OS X.
 

chef noodleman

New member
Upgrading to Java 7 fixed the "Pause Event in Dispatch Thread" error I was having, but now I seem to be logging in after every command.

I'm having this exact issue, under the following circumstances. OSX Leopard, Java 6, build 9957 was totally stable for me. I upgraded to 10014 (still Java 6) and started getting this bug that brianbatchelor is describing, in addition to the 'doesn't open the gui' bug (I was able to use the preferences window workaround). Both issues persisted when I reverted back to 9957.
 

Veracity

Developer
Staff member
I believe that the current version - which has now been released to the world as KoLmafia 15.0 - is compatible with Java 7.
I am unstickying this thread.

If anybody comes up with Java 7 issues in the future, I am sure they will write a Bug Report about it.
 
Top