Uploaded image for project: 'Minecraft: Java Edition'
  1. Minecraft: Java Edition
  2. MC-256823

Advancement titles of 0-characters long are valid, but title isn't optional

XMLWordPrintable

    • Icon: Bug Bug
    • Resolution: Works As Intended
    • None
    • 1.19.2, 22w42a, 1.19.3, 1.19.4
    • None
    • Plausible
    • Advancements, Resource Packs

      Advancements correctly require a title if they have a display object (or they won't load). HOWEVER, the title does not have minimum character limit set, allowing the creation of 0-character long titles.

      Steps to reproduce:

      • Add the following advancement:
        {
            "display": {
                "icon": {
                    "item": "minecraft:flower_banner_pattern"
                },
                "title": {
                    "text": ""
                },
                "description": {
                    "text": "Test"
                },
                "background": "minecraft:textures/gui/advancements/backgrounds/stone.png"
            },
            "criteria": {
                "tick": {
                    "trigger": "minecraft:tick"
                }
            }
        }
      • Observe how the advancement is valid
      • Remove the "title" field
      • Observe how the advancement fails to load.

      Expected behavior:
      Either title is optional, or has a minimum of 1 character required.

      Current behavior:
      Title is required, but no minimum character limit is present.

      Note:
      Since advancement titles can use translations, and translations can be empty strings, the better fix would just be to make title optional and make it act as "text":"" when left out.

            Unassigned Unassigned
            jirauser71590 user-f2760 (Inactive)
            Votes:
            2 Vote for this issue
            Watchers:
            3 Start watching this issue

              Created:
              Updated:
              Resolved:
              CHK: