ProtocolLib

3M Downloads

StreamSerializer compatible issues

caoli5288 opened this issue ยท 3 comments

commented
  • This issue is not solved in a development build

Describe the bug
ItemStack serialized by 4.x's cannot deserialize by 5.0.0

To Reproduce
Steps to reproduce the behavior:

  1. Serialize ItemStack by StreamSerializer.serializeItemStack on ProtocolLib-4.8.0
  2. Deserialize on ProtocolLib-5.0.0 from CI
  3. You got an exception

Expected behavior
:-)

Screenshots
None

Version Info
4.8.0

Additional context
None

commented

You got an exception

Please attach the exception.

commented
[11:08:14] [pool-31-1/0/WARN]: java.util.concurrent.CompletionException: java.lang.IllegalArgumentException: Illegal base64 character a
[11:08:14] [pool-31-1/0/WARN]: 	at java.base/java.util.concurrent.CompletableFuture.encodeThrowable(CompletableFuture.java:314)
[11:08:14] [pool-31-1/0/WARN]: 	at java.base/java.util.concurrent.CompletableFuture.completeThrowable(CompletableFuture.java:319)
[11:08:14] [pool-31-1/0/WARN]: 	at java.base/java.util.concurrent.CompletableFuture$AsyncSupply.run(CompletableFuture.java:1702)
[11:08:14] [pool-31-1/0/WARN]: 	at java.base/java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1128)
[11:08:14] [pool-31-1/0/WARN]: 	at java.base/java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:628)
[11:08:14] [pool-31-1/0/WARN]: 	at java.base/java.lang.Thread.run(Thread.java:829)
[11:08:14] [pool-31-1/0/WARN]: Caused by: java.lang.IllegalArgumentException: Illegal base64 character a
[11:08:14] [pool-31-1/0/WARN]: 	at java.base/java.util.Base64$Decoder.decode0(Base64.java:746)
[11:08:14] [pool-31-1/0/WARN]: 	at java.base/java.util.Base64$Decoder.decode(Base64.java:538)
[11:08:14] [pool-31-1/0/WARN]: 	at java.base/java.util.Base64$Decoder.decode(Base64.java:561)
[11:08:14] [pool-31-1/0/WARN]: 	at com.comphenix.protocol.utility.StreamSerializer.deserializeItemStack(StreamSerializer.java:188)