mojira.dev
MC-46089

Server world will not save on report of NullPointer while saving entity NBT [Found to relate to clerics]

So, on upgrade from 14w03b to 14w04b, I started getting a message about the server attempting to save entity NBT. At the point in time, There were item frames that items disappeared from, so I thought that was the problem. I removed the item frames, restarted the server, only to find that the world had not saved where it was before. This ONLY happened in the chunk that the item frames were in. Everything else in the world, except for that chunk saved. I stopped the server, went into MCEdit an removed the item frames. This still did not fix the problem. But I then remembered that, in the same chunk, below where the item frames were, there was the spawn villager trading center. (We had 1 of every type of villager, so to save them from zombification, I set their Invulnerable NBT tag to 1.) So, as far as I can tell, the villagers are preventing ONLY the chunk that they are in to not be saved by the world.

Server Error:

q: Saving entity NBT
        at ru.e(SourceFile:1149)
        at ru.d(SourceFile:1116)
        at arn.a(SourceFile:210)
        at arn.a(SourceFile:99)
        at nl.b(SourceFile:160)
        at nl.a(SourceFile:191)
        at nm.a(SourceFile:655)
        at net.minecraft.server.MinecraftServer.a(SourceFile:295)
        at net.minecraft.server.MinecraftServer.u(SourceFile:479)
        at net.minecraft.server.MinecraftServer.run(SourceFile:377)
        at mc.run(SourceFile:647)
Caused by: java.lang.NullPointerException
        at agx.j(SourceFile:115)
        at agy.a(SourceFile:125)
        at yw.b(SourceFile:212)
        at ru.e(SourceFile:1137)
        ... 10 more

This doesn't seem to be the same crash as the NullPointer Hopper crash

What I expected to happen was...:
Normal server world saving operation

What actually happened was...:
Only the chunk that the affected NBT entities are in does not save.

Steps to Reproduce:
Must❓ be on server
1. Create a villager
2. Use NBTEdit to set said villagers Invulnerable tag to 1
3. Close the world
4. Open the world, place some blocks and /save-all and stop the server.
5. Start up the sever again and you will find that whatever you placed is now gone, but it saved your movement, position, and inventory.

Video:
http://youtu.be/6u6veacFHhk
Updated video showing villager and cleric buginess:
http://youtu.be/x5HysqsuDeQ

Related issues

Comments

migrated

This must be why my server keeps my diamonds on (yay dupes), but my villager isnt Invulnerable at all. πŸ˜›

PS: There is no Invincible Tag. Its Invulnerable

migrated

Looking at it, the villagers are in the chunk that doesn't save in my world. Gonna try moving them and see if it helps.

Edit: Tried it, found the villager responsible. I moved all the villagers to a new chunk, saved and closed. The last two villagers I moved are missing which would suggest to me the previous villager was the problem child. Looking through his NBT tags, he doesn't have invulnerable set to 1, so are there any other tags I can check that would cause the problem? B.t.w give me 24 hours to respond - I have a long work day and can't reply until I get back home.

migrated

I have no idea if any other tags could be causing the problem. Maybe something about MC not liking villagers being converted between versions? Could it be related to something about the new villager AI. We've narrowed it down to the villagers AFAIK.

migrated

It's a new world I created in snapshot w03b, so none of the villagers were converted. It's definitely my cleric villager, maybe it's his trades as this started roughly once I got him to the final trade he has - glowstone and eye of ender. Dunno if its the actual trade or just having them at the final trade of any villager. Or maybe it was just that time I upgraded to w04b

migrated

This did start about the time that one guy took all the rotten flesh and mob drops from the spawn mob farm (which is what it is for...) and leveled up the cleric all the way. The cleric is also inside of that chunk and the only fully upgraded villager in the trading center, with the same glowstone trade in the last slot. Anyway, there is no way for me to tell what is even happening on the server, as anytime something happens in that chunk the console puts out the same error shown in the description 2 times in a row, without fail.

migrated

Best solution - prepare a chunk to be fenced off, move the cleric in there. Once the cleric is out then try changing things in the chunk he was in that had saving issues, if it saves then he is the cause. If you want to narrow it down that is.

migrated

I created a video showing me moving the cleric and the results. See the description for more details

migrated

Yeah, definitely the villagers causing it then. Likely the cleric given the video. Hopefully it's enough to convince someone to look into it πŸ˜‰

migrated

(Unassigned)

Unconfirmed

Minecraft 14w04b

Retrieved