Closed itsdinkd closed 2 years ago
Interesting, let's break this down:
ChestBlock.onUse
enableRandomSeedLootPerPlayer = true
so it generates new random loot for the player -> generateRandomLoot
ExplorationMapLootFunction
ChunkGenerator.locateStructure
and JigsawFeature.method_38676
StructurePoolBasedGenerator.generate
java.lang.Error: Watchdog
It looks like there have been other reports of Explorer Maps causing timeouts, but that's when Optifine or generate-structures=false
in server.properties: https://bugs.mojang.com/browse/MC-126244, https://bugs.mojang.com/browse/MC-130449
Do you know if either of those cases apply to you?
Step (2) where myLoot generates new random loot for the player is the same code as vanilla, and invoked the same way - when the player opens the inventory that should generate loot i.e. the ChestBlock.
I'm thinking some structure, or the worldgen for the chunks the structure is in is taking too long to generate causing the timeout.
Any chance you could fetch the world seed and modpack version you're using so I can see if I can reproduce it?
Unfortunately from the logs, I can't figure out which structure it's trying to locate - which might be the issue. I'll also look into whether there's a way for myLoot to skip or generate this in a different way so it doesn't hang the server thread
I actually found a similar crash report in my own server for this as well, only happened one time for me though. It's the same issue where it generates loot one of which is the Explorer Map, and triggers structure /locate which times out.
In my case though, this is purely the vanilla checkLootInteraction
(MyLootChestBlockEntity just calls the vanilla checkLootInteraction
), where it's the very first time the loot is generated for the ChestBlock, so it doesn't run through the myLoot random loot generation per player. This makes me highly suspect it's because Explorer Maps trigger locate and structure/chunk generation which can be especially slow in heavily modded worlds. I'll try to reproduce it still
Do you have terralith installed?
I was able to reproduce this and found out the Explorer Map turns into a Terralith Traveler's Map which has known issues with timing out: https://www.curseforge.com/minecraft/mc-mods/terralith?comment=918
And from the Terralith Discord:
Here are the commands for easy copy-pasting:
/scoreboard objectives add tr.disable_maps dummy
/scoreboard players set %DISABLE_MAP tr.disable_maps 1
/loot give @p loot terralith:random_traveler_map
The Traveler's map generates a dummy structure in some biome, to create a map that can locate a Biome - which is why the original crash report showed it was trying to locate a structure and generating the Biome/Chunk it's in.
I was able to reproduce this issue using my own crash report to generate the same world. Running those commands to disable Terralith Traveler's Maps fixed the issue.
In summary, this issue is unrelated to myLoot and is due to the Terralith Traveler's Map which can be disabled using the commands above. Let me know if after running those commands, there's still an issue you see related to myLoot
@itsdinkd
If it helps, I have a mod that allows you to trigger commands on server startup which you could add those /scoreboard
commands to: https://www.curseforge.com/minecraft/mc-mods/starter-items
I needed this for my own modpack
Shiiiiiet i never saw this! im getting a lot of these crashes lately. nice okay I'm going to add that scoreboard now.
also @spoorn I have several different watchdog crashes that involve MyLoot. CAn I send them your way?
also @spoorn I have several different watchdog crashes that involve MyLoot. CAn I send them your way?
sure
also @spoorn I have several different watchdog crashes that involve MyLoot. CAn I send them your way?
sure
https://mclo.gs/GKCLiWX https://mclo.gs/moRAP4h https://mclo.gs/MLgN9Tz
that is 1.19.2 btw
Noticed this crash log in AQM2's official server. Can't really give much details as it wasn't reported to me, just saw it happened a few times in the crash reports folder.
https://pastebin.com/n1tSyCLh