Server crash when pathfinding to player that is teleporting away
I've had this crash dozens of times throughout 1.16.x (and possibly earlier) on my public vanilla server. It's not easy to reproduce as it does not happen frequently, but every time it does happen it's because a player has teleported away from an area while there were mobs aggroed by him, as far as I can tell always zombified piglins.
There are 2 teleportation mechanisms on the server, both can trigger this crash:
1 - summon an armorstand, execute a function as that armorstand which sets its Pos field and then teleports the player in question to itself.
2 - teleport to another player directly through functions.
When crashing, the server takes takes 60 seconds until it times out. I have attached 4 de-obfuscated crash reports. I can provide more if necessary, but they all follow a similar pattern.
Edit: Was able to reproduce it. https://www.youtube.com/watch?v=DFa4wSobUY8
2020-12-28, 07:10 PM
2021-05-25, 03:18 PM
2021-05-25, 03:18 PM
4
7
aggro, crash, pathfind, pathfinding, teleport, zombified_piglin