triplea-game / triplea

TripleA is a turn based strategy game and board game engine, similar to Axis & Allies or Risk.
https://triplea-game.org/
GNU General Public License v3.0
1.35k stars 399 forks source link

InvalidClassException - ClientModel.startGameInNewThread: games.strategy.engine.data.Unit; local class incompatible: stream classdesc serialVersionUID = -79061939642779999, local class serialVersionUID = -7906193079642776282 #6301

Closed tripleabuilderbot closed 4 years ago

tripleabuilderbot commented 4 years ago

User Description

trying to start a solo game of domination.

Log Message

Failed to load game

TripleA Version

2.0.18746

Java Version

11.0.6

Operating System

Windows 10

Exception

java.io.InvalidClassException: games.strategy.engine.data.Unit; local class incompatible: stream classdesc serialVersionUID = -79061939642779999, local class serialVersionUID = -7906193079642776282

Stack Trace

java.base/java.io.ObjectStreamClass.initNonProxy(ObjectStreamClass.java:689) java.base/java.io.ObjectInputStream.readNonProxyDesc(ObjectInputStream.java:1958) java.base/java.io.ObjectInputStream.readClassDesc(ObjectInputStream.java:1827) java.base/java.io.ObjectInputStream.readOrdinaryObject(ObjectInputStream.java:2115) java.base/java.io.ObjectInputStream.readObject0(ObjectInputStream.java:1646) java.base/java.io.ObjectInputStream.readObject(ObjectInputStream.java:464) java.base/java.io.ObjectInputStream.readObject(ObjectInputStream.java:422) java.base/java.util.ArrayList.readObject(ArrayList.java:928) java.base/jdk.internal.reflect.GeneratedMethodAccessor13.invoke(Unknown Source) java.base/jdk.internal.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43) java.base/java.lang.reflect.Method.invoke(Method.java:566) java.base/java.io.ObjectStreamClass.invokeReadObject(ObjectStreamClass.java:1160) java.base/java.io.ObjectInputStream.readSerialData(ObjectInputStream.java:2271) java.base/java.io.ObjectInputStream.readOrdinaryObject(ObjectInputStream.java:2142) java.base/java.io.ObjectInputStream.readObject0(ObjectInputStream.java:1646) java.base/java.io.ObjectInputStream.defaultReadFields(ObjectInputStream.java:2410) java.base/java.io.ObjectInputStream.readSerialData(ObjectInputStream.java:2304) java.base/java.io.ObjectInputStream.readOrdinaryObject(ObjectInputStream.java:2142) java.base/java.io.ObjectInputStream.readObject0(ObjectInputStream.java:1646) java.base/java.io.ObjectInputStream.defaultReadFields(ObjectInputStream.java:2410) java.base/java.io.ObjectInputStream.readSerialData(ObjectInputStream.java:2304) java.base/java.io.ObjectInputStream.readOrdinaryObject(ObjectInputStream.java:2142) java.base/java.io.ObjectInputStream.readObject0(ObjectInputStream.java:1646) java.base/java.io.ObjectInputStream.defaultReadFields(ObjectInputStream.java:2410) java.base/java.io.ObjectInputStream.readSerialData(ObjectInputStream.java:2304) java.base/java.io.ObjectInputStream.readOrdinaryObject(ObjectInputStream.java:2142) java.base/java.io.ObjectInputStream.readObject0(ObjectInputStream.java:1646) java.base/java.io.ObjectInputStream.defaultReadFields(ObjectInputStream.java:2410) java.base/java.io.ObjectInputStream.readSerialData(ObjectInputStream.java:2304) java.base/java.io.ObjectInputStream.readOrdinaryObject(ObjectInputStream.java:2142) java.base/java.io.ObjectInputStream.readObject0(ObjectInputStream.java:1646) java.base/java.io.ObjectInputStream.readObject(ObjectInputStream.java:464) java.base/java.io.ObjectInputStream.readObject(ObjectInputStream.java:422) java.base/java.util.ArrayList.readObject(ArrayList.java:928) java.base/jdk.internal.reflect.GeneratedMethodAccessor13.invoke(Unknown Source) java.base/jdk.internal.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43) java.base/java.lang.reflect.Method.invoke(Method.java:566) java.base/java.io.ObjectStreamClass.invokeReadObject(ObjectStreamClass.java:1160) java.base/java.io.ObjectInputStream.readSerialData(ObjectInputStream.java:2271) java.base/java.io.ObjectInputStream.readOrdinaryObject(ObjectInputStream.java:2142) java.base/java.io.ObjectInputStream.readObject0(ObjectInputStream.java:1646) java.base/java.io.ObjectInputStream.defaultReadFields(ObjectInputStream.java:2410) java.base/java.io.ObjectInputStream.defaultReadObject(ObjectInputStream.java:600) games.strategy.engine.data.GameData.readObject(GameData.java:106) java.base/jdk.internal.reflect.NativeMethodAccessorImpl.invoke0(Native Method) java.base/jdk.internal.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62) java.base/jdk.internal.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43) java.base/java.lang.reflect.Method.invoke(Method.java:566) java.base/java.io.ObjectStreamClass.invokeReadObject(ObjectStreamClass.java:1160) java.base/java.io.ObjectInputStream.readSerialData(ObjectInputStream.java:2271) java.base/java.io.ObjectInputStream.readOrdinaryObject(ObjectInputStream.java:2142) java.base/java.io.ObjectInputStream.readObject0(ObjectInputStream.java:1646) java.base/java.io.ObjectInputStream.readObject(ObjectInputStream.java:464) java.base/java.io.ObjectInputStream.readObject(ObjectInputStream.java:422) games.strategy.engine.framework.GameDataManager.loadGame(GameDataManager.java:95) org.triplea.io.IoUtils.readFromMemory(IoUtils.java:57) games.strategy.engine.framework.startup.mc.ClientModel.startGameInNewThread(ClientModel.java:321) games.strategy.engine.framework.startup.mc.ClientModel.startGame(ClientModel.java:304) games.strategy.engine.framework.startup.mc.ClientModel$2.doneSelectingPlayers(ClientModel.java:137) java.base/jdk.internal.reflect.NativeMethodAccessorImpl.invoke0(Native Method) java.base/jdk.internal.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62) java.base/jdk.internal.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43) java.base/java.lang.reflect.Method.invoke(Method.java:566) games.strategy.engine.message.unifiedmessenger.EndPoint.invokeSingle(EndPoint.java:136) games.strategy.engine.message.unifiedmessenger.EndPoint.lambda$invokeMultiple$0(EndPoint.java:120) java.base/java.util.stream.ReferencePipeline$3$1.accept(ReferencePipeline.java:195) java.base/java.util.Spliterators$ArraySpliterator.forEachRemaining(Spliterators.java:948) java.base/java.util.stream.AbstractPipeline.copyInto(AbstractPipeline.java:484) java.base/java.util.stream.AbstractPipeline.wrapAndCopyInto(AbstractPipeline.java:474) java.base/java.util.stream.ReduceOps$ReduceOp.evaluateSequential(ReduceOps.java:913) java.base/java.util.stream.AbstractPipeline.evaluate(AbstractPipeline.java:234) java.base/java.util.stream.ReferencePipeline.collect(ReferencePipeline.java:578) games.strategy.engine.message.unifiedmessenger.EndPoint.invokeMultiple(EndPoint.java:121) games.strategy.engine.message.unifiedmessenger.EndPoint.invokeLocal(EndPoint.java:111) games.strategy.engine.message.unifiedmessenger.UnifiedMessenger.lambda$processMessage$0(UnifiedMessenger.java:317) java.base/java.util.concurrent.CompletableFuture$AsyncRun.run(CompletableFuture.java:1736) java.base/java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1128) java.base/java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:628) java.base/java.lang.Thread.run(Thread.java:834)

SilverBullet1234 commented 4 years ago

SilverBullet,,,, i was trying to launch a domination solo game and got this error message,,, i get it when i try any map now, but i ran a couple games yesterday or the day before. not sure what changed.

DanVanAtta commented 4 years ago

You're loading save games @SilverBullet1234 ?

Save game compatibility was broken extremely recently. Saving on versions @ 2.0.18746 or later should work.

DanVanAtta commented 4 years ago

To some extent we don't expect players who play only releases to ever see this issue as we would increment the version number. In theory we already on a 3.0, but given that all 2.0.x's have been non-compatible development versions so far, we have by convention have not been incrementing the major version number.

If the game major version number were 3.0 then the error message would probably be clean.

There is argument to clean up this error message regardless (and probably still allow for bug report submission as could be a legitimate problem)

SilverBullet1234 commented 4 years ago

no, i dont really play "domination" so i have no saved games, i just wanted to test it out and launch it.

---------- Original Message ---------- From: Dan Van Atta notifications@github.com To: triplea-game/triplea triplea@noreply.github.com Cc: SilverBullet1234 rifleman1234@netzero.net, Mention mention@noreply.github.com Subject: Re: [triplea-game/triplea] InvalidClassException - ClientModel.startGameInNewThread: games.strategy.engine.data.Unit; local class incompatible: stream classdesc serialVersionUID = -79061939642779999, local class serialVersionUID = -7906193079642776282 (#6301) Date: Mon, 20 Apr 2020 22:03:24 -0700

You're loading save games @SilverBullet1234 ? Save game compatibility was broken extremely recently. Saving on versions @ 2.0.18746 or later should work. — You are receiving this because you were mentioned. Reply to this email directly, view it on GitHub, or unsubscribe.