Chest item with custom name accassionally gains empty "container" component

XMLWordPrintable

    • Type: Bug
    • Resolution: Unresolved
    • Priority: Minor
    • None
    • Affects Version/s: None
    • None
    • This server is running CraftBukkit version 4489-Spigot-3dafb73-d63a32e (MC: 1.21.5) (Implementing API version 1.21.5-R0.1-SNAPSHOT)
    • Yes

      I observed that chest items with custom data (e.g. a custom name) occassionally have an unexpected "minecraft:container": [] component added to them. I consider this component unexpected, since when trying to manually add such an empty container component to an item via the Minecraft /data command, the component is omitted (probably because it equals its default value).

      My current guess is that the component is added somewhere during the Bukkit<->MC ItemStack conversion. Reproduction example

      • Rename a chest item in the anvil.
      • Check the nbt data via Minecraft's /data command:The item has a custom_name but no empty "container" component.
      • Drag the item inside the player inventory. This isn one way to trigger the MC<->Bukkit ItemStack conversion (due to the inventory event).
      • Check the NBT data again: It now has the empty container component.

      Items with and without this empty container component are considered different items by Minecraft: They don't stack inside the inventory.

            Assignee:
            Unassigned
            Reporter:
            blablubbabc
            Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

              Created:
              Updated: