Traveler's Backpack

Traveler's Backpack

26M Downloads

Repeated client crash in OverlayHandledScreen.drawItemStack, unknown trigger

JiDW opened this issue ยท 13 comments

commented
  1. ALWAYS PROVIDE INFORMATION ABOUT MODLOADER (Fabric / Forge) AND MOD VERSION (For Example 1.19.2-8.2.10)

Fabric for 1.19.2, Travelers Backpack 8.2.29 (tested also 8.2.30 on the client side)

  1. Describe the bug

On our server, two different users suddenly crashed and were unable to log back into the game (crash on connect) with the following stack trace:

java.lang.NullPointerException: Cannot invoke "net.minecraft.class_327.method_1727(String)" because "$$0" is null
	at net.minecraft.class_918.method_4022(class_918.java:382)
	at net.minecraft.class_918.method_4025(class_918.java:366)
	at com.tiviacz.travelersbackpack.client.screen.OverlayHandledScreen.drawItemStack(OverlayHandledScreen.java:169)
	at com.tiviacz.travelersbackpack.client.screen.OverlayHandledScreen.renderOverlay(OverlayHandledScreen.java:81)
	at net.minecraft.class_329.handler$ipd000$travelersbackpack$renderOverlay(class_329.java:10487)
	at net.minecraft.class_329.method_1759(class_329.java:611)
	at net.minecraft.class_329.mixinextras$bridge$method_1759$112(class_329.java)
	at net.minecraft.class_329.wrapOperation$egf000$immediatelyfast$batching(class_329.java:1565)
	at net.minecraft.class_329.method_1753(class_329.java:204)
	at net.minecraft.class_757.method_3192(class_757.java:862)
	at net.minecraft.class_310.method_1523(class_310.java:1177)
	at net.minecraft.class_310.method_1514(class_310.java:768)
	at net.minecraft.client.main.Main.method_44604(Main.java:244)
	at net.minecraft.client.main.Main.main(Main.java:51)
	at net.fabricmc.loader.impl.game.minecraft.MinecraftGameProvider.launch(MinecraftGameProvider.java:468)
	at net.fabricmc.loader.impl.launch.knot.Knot.launch(Knot.java:74)
	at net.fabricmc.loader.impl.launch.knot.KnotClient.main(KnotClient.java:23)

The only way we found to fix it was to delete all the items from the backpack directly by editing the player data.

  1. Write steps to reproduce the bug
    We have not been able to find out what cause this bug.
    The items in the backpack are different and there is nothing special about them (nothing crazy like a Create contraption or anything like that, just random items).

I'm attaching one of the player data that had the bug and the crash report.

crash_report.txt

bugged_player_data_backpack.dat.txt

Thank you for your help!

commented

Surprisingly had this exact same scenario with my friend and I had to go into the player data and delete the items from the backpack. weird

[14:25:52] [Render thread/ERROR]:
Unreported exception thrown!
java.lang.NullPointerException: Cannot invoke "net.minecraft.class_327.method_1727(String)" because "$$0" is null
at net.minecraft.class_918.method_4022(class_918.java:382) ~[client-intermediary.jar:?]
at net.minecraft.class_918.method_4025(class_918.java:366) ~[client-intermediary.jar:?]
at com.tiviacz.travelersbackpack.client.screen.OverlayHandledScreen.drawItemStack(OverlayHandledScreen.java:169) ~[travelers-backpack-1.19.2-8.2.30.jar:?]
at com.tiviacz.travelersbackpack.client.screen.OverlayHandledScreen.renderOverlay(OverlayHandledScreen.java:81) ~[travelers-backpack-1.19.2-8.2.30.jar:?]
at net.minecraft.class_329.handler$gmc000$travelersbackpack$renderOverlay(class_329.java:9987) ~[client-intermediary.jar:?]
at net.minecraft.class_329.method_1759(class_329.java:611) ~[client-intermediary.jar:?]
at net.minecraft.class_329.method_1753(class_329.java:204) ~[client-intermediary.jar:?]
at net.minecraft.class_757.method_3192(class_757.java:862) ~[client-intermediary.jar:?]
at net.minecraft.class_310.method_1523(class_310.java:1177) ~[client-intermediary.jar:?]
at net.minecraft.class_310.method_1514(class_310.java:768) [client-intermediary.jar:?]
at net.minecraft.client.main.Main.method_44604(Main.java:244) [client-intermediary.jar:?]
at net.minecraft.client.main.Main.main(Main.java:51) [client-intermediary.jar:?]
at net.fabricmc.loader.impl.game.minecraft.MinecraftGameProvider.launch(MinecraftGameProvider.java:468) [fabric-loader-0.14.22.jar:?]
at net.fabricmc.loader.impl.launch.knot.Knot.launch(Knot.java:74) [fabric-loader-0.14.22.jar:?]
at net.fabricmc.loader.impl.launch.knot.KnotClient.main(KnotClient.java:23) [fabric-loader-0.14.22.jar:?]

latest.log

also how did you put that error into a cool box like that lmao

commented

do you know exact steps how to reproduce this issue? It has never happened in my dev workspace

commented

I do not know either, unfortunately. It happened to two different players on completely separate occasions. One was trying to put the backpack on the ground, the other one was just "collecting wood". I can't verify this, I'm just repeating what I've been told by the players.

Are you not able to reproduce it either by loading the player data I uploaded? I thought maybe it could contain something corrupted since removing the items from the backpack worked to fix the bug both time.

In case you need the modpack to be able to load the player data, here it is: https://modrinth.com/modpack/corsair-smp

commented

in my case i believe that i pressed the button to switch tools in the tool slots and swapped to another hotbar slot on the same frame. The game crashed and upon reopening it I couldn't load the world until I removed the backpack's data from the save

commented

also i uploaded the wrong log by accident. sorry
here:
2023-10-16-4.log
https://mclo.gs/NhC6Xge

commented

I sadly was not able to recreate it though.

I have also noticed that both of us have similar modpacks so we might both have a mod that caused the crash

commented

you uploaded dat with txt extension

commented

Yeah Github refuse to upload .dat files

commented

I've just opened the world without any crash while using backpack from your dat file.
image
I don't know why there was sand block in tool slot though

commented

im pretty sure its caused by some other mod, probably injecting mixin somewhere to the code that renders itemstack idk

commented

Hmm yeah, that's strange. I'm not sure how the "swap" feature works, so I wouldn't know.

Thanks for looking into it, if it happens again I'll update this ticket

commented

there was a problem with durability101 mod and it caused similiar crash like this

commented

if you find the cause, reopen or open new issue