Mojira Archive
MC-269595

Summoning a large EXP orb damages mending items to negative durability or 0 durability

I was playing a world, and was experimenting with summoning large EXP orbs.

Note
It seems that in Snapshot 23w51a, a sub-bug was fixed in which the durability bar would not go outside the screen to the left
In Snapshot 24w10a, this bug no longer makes the durability ~ -63000, instead, it makes the durability 0

Expected:
Tools would mend

What Happened:
Tools went into the extreme negatives of the durability or 0 durability

Reproduce:
Video:
https://www.dropbox.com/scl/fi/u85c0455v409euxfbuy6t/bug.mov?rlkey=jhgpaju9yj3ppvz9ns238negd&dl=0
 
Run these commands and steps:
1.

1.20.4 and older (old NBT tag system)
/item replace entity @s weapon.mainhand with diamond_pickaxe{Damage:1.Enchantments:[{id:mending,lvl:1}]}
1.20.5 and up (new component system)
/item replace entity @s weapon.mainhand with diamond_pickaxe[damage=1,enchantments={levels:{mending:1}}] 

2.

This only works (breaks) if the item is in your off-hand or the SelectedItem slot.

/summon experience_orb ~ ~ ~ {Value:32768} // Must be bigger or equal to 32768