Custom LAN

Custom LAN

13.2k Downloads

Error when saving the world

mpustovoi opened this issue · 6 comments

commented

So, after updating to [1.20-1.20.1] Custom LAN 2.3.0 after quitting the world, it always takes about 2 minutes to save it. Moreover, it doesn't depend on whether I did something in this world by loading chunks maybe or I immediately left it.
I looked at latest.log after leaving my main and test world. Every time at the end of the logs, I see an error pointing to your mod:

[21:12:14] [Server thread/INFO]: ThreadedAnvilChunkStorage (Test): All chunks are saved
[21:12:14] [Server thread/INFO]: ThreadedAnvilChunkStorage: All dimensions are saved
[21:12:14] [Server thread/INFO]: ThreadedAnvilChunkStorage (DIM-1): All chunks are saved
[21:12:14] [Server thread/INFO]: ThreadedAnvilChunkStorage (otherside): All chunks are saved
[21:12:14] [Server thread/INFO]: ThreadedAnvilChunkStorage (DIM1): All chunks are saved
[21:12:14] [Server thread/INFO]: closing rrp ebe:base_resources
[21:12:14] [Server thread/ERROR]: Exception stopping the server
java.lang.NullPointerException: Cannot invoke "com.dimitrodam.customlan.TunnelType.stop(net.minecraft.server.MinecraftServer)" because the return value of "net.minecraft.server.MinecraftServer.getTunnelType()" is null
	at net.minecraft.server.MinecraftServer.handler$cgj000$customlan$postShutdown(MinecraftServer.java:5313) ~[client-intermediary.jar:?]
	at net.minecraft.server.MinecraftServer.method_3782(MinecraftServer.java:619) ~[client-intermediary.jar:?]
	at net.minecraft.class_1132.method_3782(class_1132.java:209) ~[client-intermediary.jar:?]
	at net.minecraft.server.MinecraftServer.method_29741(MinecraftServer.java:703) ~[client-intermediary.jar:?]
	at net.minecraft.server.MinecraftServer.method_29739(MinecraftServer.java:265) ~[client-intermediary.jar:?]
	at java.lang.Thread.run(Thread.java:833) ~[?:?]
[21:12:14] [Server thread/INFO]: [FastQuit] The world "Test" has been successfully saved. (1min 46s)
[21:12:14] [Render thread/INFO]: closing rrp ebe:base_resources

Apart from this error, everything works fine and I don't see any problems in the latest.log.
Moreover, this error occurs despite the fact that I didn't even open the world to the LAN. That is, I can literally enter the world, immediately exit it, and I still have to wait almost 2 minutes until this error is apparently forcibly terminated.
And yes, with version [1.20-1.20.1] Custom LAN 2.2.3 this error didn't occur.

commented

This error in particular shouldn't cause any problems… If anything, it should crash the game, not make it take a long time to save. I have a fix ready, but I decided that it's not worth releasing an entire version for that little bugfix, so it'll be included in the next release.

Are you sure the slow saving is because of Custom LAN, and if so, does it happen on v2.2.3?

commented

I'll test that on different setups later.
Btw, surprisingly, issue isn't there if I'm using Custom LAN v2.3.0 on Forge with Sinytra Connector.

commented

Yes, this error occurs on my other setups (a smaller ones).
Will be waiting for the next release with a fix.

commented

Over 300, so I don't think it's possible to figure out which particular one causes that.

commented

As I said, this error is unrelated to the slow saving and should be harmless.
I was unable to replicate the slow saving, so it is most likely caused by another mod. Which other mods are you using?

commented

In that case I'll consider the slow saving another mod's fault. If you get more insight into it, leave a comment.

As for the error, it'll be fixed in the next release.