--- a/net/minecraft/world/item/component/UseRemainder.java
+++ b/net/minecraft/world/item/component/UseRemainder.java
@@ -8,7 +_,7 @@
 public record UseRemainder(ItemStack convertInto) {
     public static final Codec<UseRemainder> CODEC = ItemStack.CODEC.xmap(UseRemainder::new, UseRemainder::convertInto);
     public static final StreamCodec<RegistryFriendlyByteBuf, UseRemainder> STREAM_CODEC = StreamCodec.composite(
-        ItemStack.STREAM_CODEC, UseRemainder::convertInto, UseRemainder::new
+        ItemStack.STREAM_CODEC.apply(net.minecraft.network.codec.ByteBufCodecs::increaseDepth), UseRemainder::convertInto, UseRemainder::new // Paper - Track codec depth
     );
 
     public ItemStack convertIntoRemainder(ItemStack stack, int count, boolean hasInfiniteMaterials, UseRemainder.OnExtraCreatedRemainder onExtraCreated) {
