Sponge Function throw : Unable to translate object to JSON


#1

My server crashed when player have some mods block/item in inventory, such as Modular Powersuits
or Buildcraft and save the world.


and here are my server log : pastebin.com/0xqdcm37

Sponge function (org.spongepowered.common.data.persistence.JsonDataFormat.write) might throw : Unable to translate object to JSON when plugin Project Inventory(PJI) call it.

Here are PJI code in call stack : github点com/trentech/ProjectInventories/blob/7733e7593ad9a00b20ca6149977d59f467a26d83/src/main/java/com/gmail/trentech/pji/data/PlayerInventoryData.java

Here are some code from PJI :
Line 18 : import org.spongepowered.api.data.DataContainer;
Line 242 : DataContainer container = DataContainer.createNew().set(NAME, this.name);
Line 249 : container.set(HELMET, this.helmet.get().toContainer());
And Sponge crashed.

For example , when I have a BluePrint (By Buildcraft) , and save the world . My server will crash.

I think some mod item like BluePrint have too more NBT data , Sponge JsonDataFormat can`t convert it to JSON.

I used MC 1.12.2 Forge 2768 and sponge 7.1.4 , crash at Line 9 : /save-all

And here are some plugin version
PJI : 0.11.2 (Jenkins : trentech.org/jenkins/job/ProjectInventories/44/ )
PJC : 0.2.1

LuckPerms:4.3.8
Nucleus : S7.1

And there are some other users Issues , they have similar problems.


Is it a Sponges Bug or PJIs bug?I think it is sponge`s.

Thanks for your reply.