Bug - Fixed NoSuchMethod error in CommandQueueHandler when updating svn

Sytras

Member
Kolmafia hangs and prints a trace in the console whenever i run "svn update" and it finds a script that needs to be updated.
Trying to run any other commands queues them behind the stuck svn update and I need to close and restart the jar to fix it.

I am using kolmafia r18478 and java 1.8.0_131 on a windows 10 x64 machine.

Code:
Exception in thread "CommandQueueHandler" java.lang.NoSuchMethodError: java.nio.ByteBuffer.clear()Ljava/nio/ByteBuffer;
        at org.tmatesoft.svn.core.internal.delta.SVNDeltaReader.<init>(SVNDeltaReader.java:50)
        at org.tmatesoft.svn.core.internal.io.dav.handlers.BasicDAVDeltaHandler.init(BasicDAVDeltaHandler.java:48)
        at org.tmatesoft.svn.core.internal.io.dav.handlers.DAVEditorHandler.<init>(DAVEditorHandler.java:249)
        at org.tmatesoft.svn.core.internal.io.dav.DAVRepository.runReport(DAVRepository.java:1325)
        at org.tmatesoft.svn.core.internal.io.dav.DAVRepository.update(DAVRepository.java:863)
        at org.tmatesoft.svn.core.internal.wc2.ng.SvnNgAbstractUpdate.updateInternal(SvnNgAbstractUpdate.java:247)
        at org.tmatesoft.svn.core.internal.wc2.ng.SvnNgAbstractUpdate.update(SvnNgAbstractUpdate.java:111)
        at org.tmatesoft.svn.core.internal.wc2.ng.SvnNgUpdate.run(SvnNgUpdate.java:38)
        at org.tmatesoft.svn.core.internal.wc2.ng.SvnNgUpdate.run(SvnNgUpdate.java:18)
        at org.tmatesoft.svn.core.internal.wc2.ng.SvnNgOperationRunner.run(SvnNgOperationRunner.java:20)
        at org.tmatesoft.svn.core.internal.wc2.SvnOperationRunner.run(SvnOperationRunner.java:21)
        at org.tmatesoft.svn.core.wc2.SvnOperationFactory.run(SvnOperationFactory.java:1235)
        at org.tmatesoft.svn.core.wc2.SvnOperation.run(SvnOperation.java:294)
        at org.tmatesoft.svn.core.wc.SVNUpdateClient.doUpdate(SVNUpdateClient.java:311)
        at org.tmatesoft.svn.core.wc.SVNUpdateClient.doUpdate(SVNUpdateClient.java:291)
        at org.tmatesoft.svn.core.wc.SVNUpdateClient.doUpdate(SVNUpdateClient.java:387)
        at net.sourceforge.kolmafia.svn.SVNManager.update(SVNManager.java:306)
        at net.sourceforge.kolmafia.svn.SVNManager.update(SVNManager.java:283)
        at net.sourceforge.kolmafia.svn.UpdateRunnable.run(UpdateRunnable.java:141)
        at net.sourceforge.kolmafia.RequestThread.postRequest(RequestThread.java:286)
        at net.sourceforge.kolmafia.RequestThread.postRequest(RequestThread.java:271)
        at net.sourceforge.kolmafia.svn.SVNManager$2.run(SVNManager.java:1304)
        at net.sourceforge.kolmafia.RequestThread.postRequest(RequestThread.java:286)
        at net.sourceforge.kolmafia.RequestThread.postRequest(RequestThread.java:271)
        at net.sourceforge.kolmafia.svn.SVNManager.doUpdate(SVNManager.java:1315)
        at net.sourceforge.kolmafia.textui.command.SVNCommand.run(SVNCommand.java:63)
        at net.sourceforge.kolmafia.KoLmafiaCLI.doExecuteCommand(KoLmafiaCLI.java:596)
        at net.sourceforge.kolmafia.KoLmafiaCLI.executeCommand(KoLmafiaCLI.java:549)
        at net.sourceforge.kolmafia.KoLmafiaCLI.executeLine(KoLmafiaCLI.java:450)
        at net.sourceforge.kolmafia.KoLmafiaCLI.executeLine(KoLmafiaCLI.java:318)
        at net.sourceforge.kolmafia.swingui.CommandDisplayFrame$CommandQueueHandler.handleQueue(CommandDisplayFrame.java:187)
        at net.sourceforge.kolmafia.swingui.CommandDisplayFrame$CommandQueueHandler.run(CommandDisplayFrame.java:163)

The gcli shows:
Code:
> svn update

Checking all SVN projects...
slimetube is at HEAD (r15)
wrldwzrd89-mafia-scripts-trunk-pandamonium-quest is at HEAD (r8)
AllenTuring-KoL-MineVolcano-trunk is at HEAD (r61)
Ezandora-Lylefarm-branches-Release is at HEAD (r17)
balefull-raidlog-parser-branches-master is at HEAD (r3)
Ezandora-Guide-branches-Release is at HEAD (r512)
Ezandora-Briefcase-branches-Release is at HEAD (r78)
Ezandora-Spacegate-branches-Release is at HEAD (r36)
Ezandora-Choice-Override-branches-Release is at HEAD (r23)
mapledyne-yaaz-branches-master is at HEAD (r404)
Ezandora-Asdon-Martin-GUI-branches-Release is at HEAD (r9)
Ezandora-Far-Future-branches-Release is at HEAD (r38)
Ezandora-Genie-branches-Release needs updating from (r38) to (r39)
Ezandora-Detective-Solver-branches-Release is at HEAD (r19)
rlbond86-mafia-scripts-better_trainer-trunk is at HEAD (r37)
missingmanuel-trunk is at HEAD (r33)
slyz-nemesis is at HEAD (r12)
digitrev-fishbot is at HEAD (r151)
digitrev-telegram is at HEAD (r151)
bale-relay-woods_questStart is at HEAD (r139)
veracity0-vprops is at HEAD (r93)
bale-new-life is at HEAD (r70)
bale-ltt is at HEAD (r6)
ccascend-batfellow needs updating from (r1313) to (r1316)
bale-relay-Monster_Manuel_Improvement is at HEAD (r139)
ccascend-cc_ascend needs updating from (r1313) to (r1316)
therazekolmafia-thesea is at HEAD (r41)
bale-snojo is at HEAD (r2)
relaywtf-wtf is at HEAD (r42)
smartstasis is at HEAD (r39)
mafiarecovery is at HEAD (r36)
digitrev-NewYou is at HEAD (r151)
bumcheekascend-bumcheekascend is at HEAD (r664)
relaywtf-skillswtf is at HEAD (r42)
bale-relay-campground is at HEAD (r139)
guyymafia-displayshelves is at HEAD (r274)
formhtml is at HEAD (r1)
therazekolmafia-canadv is at HEAD (r96)
batbrain is at HEAD (r111)
kolm-prefs is at HEAD (r15)
bale-relay-manor_unlockInfo is at HEAD (r139)
relaywtf-vipwtf is at HEAD (r42)
bale-spelunky is at HEAD (r4)
bale-ns-tower-relay is at HEAD (r1)
kolm-noobsorb is at HEAD (r36)
zlib is at HEAD (r37)
bale-counterchecker is at HEAD (r23)
mafiachit is at HEAD (r567)
uberpvpoptimizer is at HEAD (r64)
winterbay-mafia-wham is at HEAD (r47)
guyymafia-dreaddrunk is at HEAD (r274)
relaywtf-shopwtf is at HEAD (r42)
relaywtf-inventorywtf is at HEAD (r42)
ccascend-snapshot needs updating from (r1313) to (r1316)
relaywtf-famswtf is at HEAD (r42)
winterbay-mafia-autobasement is at HEAD (r44)
therazekolmafia-eatdrink is at HEAD (r55)
guyymafia-tricktreat is at HEAD (r274)
Updating all SVN projects...
Validating repo...
Repo validated.
Updating ccascend-snapshot...
D:\Matt\Desktop\kolmafia\svn\ccascend-snapshot
Requests complete.
 

Magus_Prime

Well-known member
I was about to report that "breakfast" wasn't running in either r18477 or r18478 but noticed this post. I'm seeing the same behavior when attempting to update from SVN. I'm guessing that the SVN failure is responsible for "breakfast" not running automatically.

Both SVN update and breakfast work as expected in r18473.
 
Last edited:

lostcalpolydude

Developer
Staff member
Both SVN update and breakfast work as expected in r18473.

Probably a coincidence with sourceforge deciding to be responsive? Nothing even remotely related to that code has changed recently, so unless you're going back several months there's nothing to gain by trying different versions.
 

fronobulax

Developer
Staff member
Probably a coincidence with sourceforge deciding to be responsive? Nothing even remotely related to that code has changed recently, so unless you're going back several months there's nothing to gain by trying different versions.

As a general philosophy, it would be nice if code behaved "nicely" even when SourceForge is not, but none of these things happened to me today with r18478.
 

Fessor Eli

New member
Another data point. SVN update did not work at all in r18478, and I tried r18469, and it worked perfectly. A gap in time of less than a minute.
 

lostcalpolydude

Developer
Staff member
Another data point. SVN update did not work at all in r18478, and I tried r18469, and it worked perfectly. A gap in time of less than a minute.

Or more likely, closing and reopening mafia made things work. Because nothing changed in mafia related to this between those versions.
 

Sytras

Member
I've tried closing and reopening mafia several times and still get the buggy behavior every time i run "svn update".
 

Sytras

Member
I'm guessing something closer to this post is what you need to do.

I've tried going back to r18475, r18476, r18477 and get the same error running "svn update" with all of them. I don't have any older jars.
I can try deleting each svn script and reinstalling them, but then "svn update" wouldn't actually try to update anything (because fresh copies don't have updates" so wouldn't this just hide any issues with the updating code?
 

lostcalpolydude

Developer
Staff member
The code wasn't changed recently. I suspect the problem is with a subversion repository, because something bad happened in response to sourceforge giving unexpected responses.

Mostly I'm just guessing though. But I'm sure no one is looking to fix code in mafia that hasn't been touched in the last year at least, so from your perspective, waiting for that to happen won't lead anywhere.
 

fronobulax

Developer
Staff member
I feel like I have mentioned this elsewhere but a non mafia SVN client will give error messages that usually point a finger at a problem that is not the mafia svn client. If there is something on your disk that is out of whack the client can usually detect and fix it easier.
 

Rinn

Developer
It looks like in JDK8 ByteBuffer inherited the clear() function from java.nio.Buffer and returned a Buffer object but in JDK9 clear() is overridden to return a ByteBuffer, so who knows what else could have changed that would expose this. Ryo_Sangnoir's guess about the new build server is probably correct if it's building against JDK9. When's the last time svnkit was updated?

When I was trying to repro this before I saw this thread I was able to do a successful svn update by force quitting mafia and retrying like 3 times and it finally succeeded with some warnings so there probably is some weirdness coming from SourceForge that is exposing this for specific repositories.

Code:
> svn update
Checking all SVN projects...
WARNING: An illegal reflective access operation has occurred
WARNING: Illegal reflective access by org.tmatesoft.svn.core.internal.util.SVNSocketFactory (file:/./Dropbox/kolmafia/kolmafia.jar) to method sun.security.ssl.SSLSocketImpl.setHost(java.lang.String)
WARNING: Please consider reporting this to the maintainers of org.tmatesoft.svn.core.internal.util.SVNSocketFactory
WARNING: Use --illegal-access=warn to enable warnings of further illegal reflective access operations
WARNING: All illegal access operations will be denied in a future release
almighty-saplings-ash-trunk-raidlogs not checked - exception: org.tmatesoft.svn.core.SVNException: svn: E160013: '/svn/trunk/raidlogs' path not found: 404 Not Found ([URL]http://almighty-saplings-ash.googlecode.com[/URL])
Ezandora-Detective-Solver-branches-Release is at HEAD (r19)
Ezandora-Source-Terminal-GUI-branches-Release is at HEAD (r19)
Ezandora-Briefcase-branches-Release is at HEAD (r78)
geistbar-autoVolcano-trunk is at HEAD (r22)
Ezandora-Guide-branches-Release is at HEAD (r512)
Ezandora-Far-Future-branches-Release is at HEAD (r38)
coandco-mafia-NewYou-trunk is at HEAD (r12)
mikebryant-kolmafia-lar-forecasting-branches-master-src is at HEAD (r54)
AllenTuring-KoL-MineVolcano-trunk is at HEAD (r61)
geistbar-autoGlacier-trunk is at HEAD (r24)
Ezandora-Spacegate-branches-Release is at HEAD (r36)
Ezandora-Choice-Override-branches-Release is at HEAD (r23)
AllenTuring-WitchessSolver-trunk is at HEAD (r50)
missingmanuel-trunk is at HEAD (r33)
guyymafia-dreaddrunk is at HEAD (r274)
relay-charsheet is at HEAD (r35)
bale-relay-Monster_Manuel_Improvement is at HEAD (r139)
bale-relay-woods_questStart is at HEAD (r139)
kolmafiascripts-cfstat is at HEAD (r2)
bale-relay-campground is at HEAD (r139)
bale-spelunky is at HEAD (r4)
bale-ltt is at HEAD (r6)
mafia-harvest is at HEAD (r34)
slyz-nemesis is at HEAD (r12)
72fd6657-9ca6-454e-98b5-a35926876534 is at HEAD (r11)
mafia-harvest-data is at HEAD (r4)
zlib is at HEAD (r37)
smartstasis is at HEAD (r39)
bale-advisor is at HEAD (r25)
batbrain is at HEAD (r111)
familiardrops is at HEAD (r6)
winterbay-mafia-wham is at HEAD (r47)
winterbay-mafia-farm is at HEAD (r27)
bestbetweenbattle is at HEAD (r21)
psychoseamatic is at HEAD (r12)
guyymafia-tricktreat is at HEAD (r274)
rlbond86-mafia-scripts-better_trainer-trunk is at HEAD (r37)
winterbay-mafia-sushi is at HEAD (r4)
therazekolmafia-eatdrink is at HEAD (r55)
kolmafiascripts-shop is at HEAD (r9)
clilinks is at HEAD (r6)
mafiarecovery is at HEAD (r36)
bale-relay-manor_unlockInfo is at HEAD (r139)
bale-ocd is at HEAD (r46)
digitrev-crimbo2015 is at HEAD (r151)
therazekolmafia-canadv is at HEAD (r96)
bale-counterchecker is at HEAD (r23)
644e5752-2eaa-4709-b570-332e7ec0dde8 is at HEAD (r64)
ccascend-batfellow needs updating from (r1315) to (r1317)
formhtml is at HEAD (r1)
bumcheekascend-bumpork is at HEAD (r664)
winterbay-mafia-autobasement is at HEAD (r44)
mafiachit is at HEAD (r567)
therazekolmafia-thesea is at HEAD (r41)
digitrev-telegram is at HEAD (r151)
ccascend-cc_ascend needs updating from (r1315) to (r1317)
acquirebuff is at HEAD (r1)
veracity0-vprops is at HEAD (r93)
veracity0-gingerbread is at HEAD (r93)
ccascend-snapshot needs updating from (r1315) to (r1317)
Updating all SVN projects...
Validating repo...
Repo validated.
Updating ccascend-batfellow...
.\kolmafia\svn\ccascend-batfellow
At revision 1317
Done.
Validating repo...
Repo validated.
Updating ccascend-cc_ascend...
.\kolmafia\svn\ccascend-cc_ascend
U         [URL]https://svn.code.sf.net/p/ccascend/code/cc_ascend/scripts/cc_ascend/cc_clan.ash[/URL]
U         [URL]https://svn.code.sf.net/p/ccascend/code/cc_ascend/scripts/cc_ascend/cc_adventure.ash[/URL]
[URL]https://svn.code.sf.net/p/ccascend/code/cc_ascend/scripts/cc_ascend[/URL]
[URL]https://svn.code.sf.net/p/ccascend/code/cc_ascend/scripts[/URL]
[URL]https://svn.code.sf.net/p/ccascend/code/cc_ascend[/URL]
At revision 1317
Pushing local updates...
cc_adventure.ash => .\kolmafia\scripts\cc_ascend\cc_adventure.ash
cc_clan.ash => .\kolmafia\scripts\cc_ascend\cc_clan.ash
Done.
Validating repo...
Repo validated.
Updating ccascend-snapshot...
.\kolmafia\svn\ccascend-snapshot
At revision 1317
Done.
Update log for <b>ccascend-cc_ascend</b>:
------
Commit <b>r1316<b>:
Author: asocasno


try to handle asventuring when drunk without relying on a local mafia edit.
Zatara handling should use responses for valdiation, not sure if we axtually care about making this function adaptable.
------
Commit <b>r1317<b>:
Author: asocasno


get_player_name is a custom function, not a vanilla mafia function, oops.
------
Checking for working copy modifications...
M .\kolmafia\svn\AllenTuring-WitchessSolver-trunk\scripts\witchess_solver.ash
M .\kolmafia\svn\bale-advisor\relay\relay_AdventureAdvisor.ash
M .\kolmafia\svn\bale-counterchecker\scripts\CounterChecker.ash
M .\kolmafia\svn\bale-ocd\relay\relay_OCD_dB_Manager.ash
M .\kolmafia\svn\bale-ocd\scripts\OCD Inventory Control.ash
M .\kolmafia\svn\ccascend-cc_ascend\scripts\cc_ascend.ash
M .\kolmafia\svn\ccascend-cc_ascend\scripts\cc_ascend\cc_mr2016.ash
M .\kolmafia\svn\ccascend-cc_ascend\scripts\cc_ascend\cc_community_service.ash
M .\kolmafia\svn\digitrev-telegram\scripts\telegram.ash
M .\kolmafia\svn\digitrev-telegram\scripts\telegram_combat.ash
M .\kolmafia\svn\geistbar-autoVolcano-trunk\scripts\autoVolcano.ash
Synchronizing with local copies...
Sync complete.
Requests complete.
 
Last edited:

Boesbert

Member
The problem I described here seemed to be affected by scripts hosted on github as well, though. Not sure if that is relevant, however.
 

Rinn

Developer
I was going to look into this but I had just deleted my local mafia code do to a fresh sync and there's some real irony where svn is timing out when I do the svn update.
 

heeheehee

Developer
Staff member
When's the last time svnkit was updated?

A few years ago. I didn't encounter anything particularly exciting when trying to update SVNKit locally (recently), just needed to fetch some new jars for jna / jna-platform.

As for speculation about the CI server:
Metadata from the JAR for r18475: "Created-By: 9.0.4+11 (Oracle Corporation)"
 
Last edited:

fronobulax

Developer
Staff member
A few years ago. I didn't encounter anything particularly exciting when trying to update SVNKit locally, just needed to fetch some new jars for jna / jna-platform.

As for speculation about the CI server:
Metadata from the JAR for r18475: "Created-By: 9.0.4+11 (Oracle Corporation)"

There is a size difference between the jar I built and the jar on the ci server. Some folks claim that is because of compilation time stamps are embedded and of variable length. The definitive answer is to unpack the jars, decompile the classes and compare but I have not made that work yet.
 

Rinn

Developer
If it's not a defect in svnkit I was thinking it would be prudent to just catch the exception from the svn call and let it fail gracefully without updating the affected repo if this is just going to continue being a problem in the future.
 

Ryo_Sangnoir

Developer
Staff member
AlbinoRhino, others who have it working on Java 9: are you running the jar with Java 8, or with Java 9?

I'm having problems when I run the Java 9-compiled jar file in Java 8. This evening, I'll try downloading Java 9 to see if that fixes the problem.
 
Top