Bug - Fixed Can't log in (IOException during data post (login.php)

For the last week or so I haven't been able to log in via mafia on this computer. I've tried every version of mafia that's been released and tried deleting the folder and starting fresh. I could have sworn the first time I checked the CLI it didn't say anything but I checked again and I get
Code:
IOException during data post (login.php)

I know this isn't a bug with mafia (or I don't think it is at least) because it works fine on every other computer I've tried it on, but I don't know what else to call it.

Would anyone know what's going on?
 
I looked through the forums for other instances of this and it's a timeout message apparently.

I'm not sure what could be causing it on this computer, as I know it's not the internet and it's not the computer, as I've had 2 internet sources and three different computers.
 

Theraze

Active member
Unless you've set an invalid proxy or something similar...

A debug log would help in our troubleshooting, since the issue is something about your setup, whether that's Java version, mafia settings, or some other program interfering...
 
I tried that, the only change is that instead of saying "requests completed" it says IOException during data post (login.php) on the login thing instead of just on the CLI.
 

Theraze

Active member
You're using Java 7, which keeps getting broken with new versions. If you don't have a specific reason for it, please uninstall that and install Java 6, and see if the problem remains...
 

Catch-22

Active member
It would nice to get this actually fixed, because Java 6 officially goes end of life in a few months time.

The issue is probably related to IPv6 in Windows 7/Java 7. I recently realized that because I disable the IPv6 stack on most of the Windows machines I use, I rarely run into these kinds of connectivity issues.

In the long term, better support for IPv6 connections should probably be implemented. In the short term, calling System.setProperty("java.net.preferIPv4Stack" , "true"); as part of KoLmafia's initialization would probably fix it.
 

Darzil

Developer
I recently realized that because I disable the IPv6 stack on most of the Windows machines I use, I rarely run into these kinds of connectivity issues.

Only negative I've had disabling IPv6 so far is that Windows Homegroups stop working, though it does fix some iTunes issues (iTunes preferentially uses IP6, so if you have IP6, but your router isn't routing it, iTunes does some weird stuff).
 

Catch-22

Active member
Only negative I've had disabling IPv6

Just for clarity, the fixes I proposed don't actually disable IPv6 at the OS level and would only affect the running instance of KoLmafia.

I only turn off IPv6 at the OS level because I'm often on networks that don't play nice with Teredo, I don't recommend people disable it at an OS level unless they have a specific need to do so. Although if you would like to troubleshoot why Java 7 won't work on your IPv6 enabled OS, perhaps you could run your JVM with the command line argument -Djava.net.preferIPv4Stack=true, which effectively applies the short term fix I mentioned above in a less convenient manner.
 
Last edited:

roippi

Developer
It would be nice if we could track down the java 7 connection issues. That sounds like a reasonable cause of the intermittent-ness.

If there's no dev that can confirm that it works okay on an ipv6*java7 box, I'll just commit it anyway. It's not like we currently guarantee java 7 functionality.
 

roippi

Developer
I was waiting for a point release to commit this one. r11695 tries catch22's suggestion of disabling the ipv6 stack. I have no access to ipv6 myself so we'll see how it affects those who have it.
 
Top