The bug
This issue was introduced in 24w36a.
Mob heads that are placed in dispensers can be equipped to mobs and players when the dispenser is activated. In previous versions, if there was no valid target, the dispenser would simply do nothing. Since 24w36a, the item is now instead ejected onto the ground.
This does not affect wither skeleton skulls or carved pumpkins. They still remain in the dispenser on failure, likely due to their additional functionality of spawning golems or the wither.
Note that other equippable items like armor pieces are also ejected on failure. It’s unclear which behavior is intended for heads.
Steps to reproduce:
Put all mob heads into a dispenser
Stand in front of the dispenser and activate it multiple times
Expected behavior
The first mob head should be equipped to you, subsequent mob heads should remain in the dispenser
Observed behavior
Subsequent mob heads are dispensed onto the ground like regular items
Environment
Everything was done on vanilla instances
Thank you for helping us improve Minecraft! We saved your files: