Integrated Dynamics

Integrated Dynamics

63M Downloads

Named Variable Cards lose names server restart

ScottDTA opened this issue ยท 12 comments

commented

Issue type:

  • ๐Ÿ› Bug

Short description:

Named Variable cards lose names on server restart

Steps to reproduce the problem:

  1. Name a variable card with the labeler.
  2. put in a variable store or interface
  3. restart server

Expected behaviour:

Cards will keep names.


Versions:

  • This mod: 1.0.6

  • Minecraft: 1.12.2

  • Forge: 14.23.5.2781

  • Pack: Enigmatica 2 Expert Skyblock ver 1.24

Log file:

Not a crash, but I can get one if needed.

commented

Same issue as #703.

Can you try reproducing this without any other mods installed?
Another mod is possibly causing changes/errors during world saving, which causes labels to not be saved. (You may be able to see this in the server logs during server shutdown)

commented

I'm on vacation end of week and next. I'll dig into it and see if can isolate the issue. I've also posted it on the packs issue tracker.

commented

Here is the log entries from when the server is stopping. no errors listed.

https://pastebin.com/mURvUskE

On startup, there a lot of errors listed in the full log, but nothing in regards to world save loading. Does spit out a bunch of parsing advancement errors for ID/T as well as other mods with the same issues.

Will spend some time this weekend running a server with just ID/T and start adding other mods from the pack to see if I can track down what is causing the issue.

NillerMedDild says he is also working on updating the pack, so maybe that will also fix it. Will keep digging.

Pastebin
commented

Checking the integrateddynamics_Labels.dat file on the server and all of the labels appear to still be in there, so not sure why they are not loading in game.

image

commented

Thanks for that info! Perhaps something is blocking label packets to be sent to the client.

I've seen problems like that before. Note to self: investigate if this line can cause problems: https://github.com/CyclopsMC/IntegratedDynamics/blob/master-1.12/src/main/java/org/cyclops/integrateddynamics/core/persist/world/LabelsWorldStorage.java#L109

GitHub
A Minecraft mod to take full and automated control of your appliances. - CyclopsMC/IntegratedDynamics
commented

There should be a world object in the event to use to check if remote instead of checking is client side?

I'll look at the logs on both server and client to see if any errors show on player login.

commented

Had some time at work to pull a log off the Server. Appears there is an error on player login.

https://pastebin.com/rVWBHTbW

Could be an issue also from that with fast workbench mod?

Pastebin
commented

I think you just found the cause of the issue! :-)

The problem is definitely caused by ID. For some reason, some labels are null, so I should add a workaround/fix for that.

commented

Great. Glad I could help.

Next step, clear the dat file then and see if i can reproduce making a null one in the 1st place

commented

Now that I think about it. Could be inventory tweaks that caused null entries to start with.

When trying to name a card in the logic programmer, some keys would cause it to close the ui and throw the card on ground.

Happens with the labeller ui as well, but since that one requires clicking on write I don't think it registered the label to start with.

commented

Well I have spent the evening trying to duplicate getting a null entry again, but was not able to do so.

I did find the null entry in the dat file and fix that. It had the ID tag but no string tag.

I did learn that naming a card and then destroying the card in creative menu doesn't remove the entry from the list. This could lead to the file growing larger then it needs to be, as there was no way to get that same ID back again.

commented

Thanks for your efforts! I'll see what I can do to fix it. But I don't expect any major problems.

I did learn that naming a card and then destroying the card in creative menu doesn't remove the entry from the list.

Indeed, that's something that can not be solved unfortunately. Because MC internally destroys/copies items all the time, so there's no good way to know when an item has actually been removed from the game. Labels are not that big, so this should not cause any issues.