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

dataTag parsing/escaping issue

XMLWordPrintable

    • Icon: Bug Bug
    • Resolution: Fixed
    • Minecraft 14w31a
    • Minecraft 1.7.1, Minecraft 1.7.2, Minecraft 13w47e, Minecraft 13w48a, Minecraft 13w48b, Minecraft 1.7.9, Minecraft 14w20b, Minecraft 14w21a, Minecraft 14w21b
    • _All_
    • Unconfirmed

      *Update* apparently data tag is not JSON (why use your own almost-json implementation? You could use lenient gson).

      Valid JSON does not work with the /summon command.

      • Keys are not accepted unless they are un-quoted.
      • Escaping does not work (except for double-quotes)

      Not working:

      /summon Sheep ~ ~ ~ {"CustomName":"foobar"}
      

      (This works now)

      Not working:

      /summon Sheep ~ ~ ~ {"CustomName":"foobar\\"}
      

      It will take the first backslash as-is and then escape the double-quote, which of course causes an "Unbalanced quotation"

      My two examples are 100% valid JSON, see: (they are, but apparently data tags aren't JSON)

            jeb [Mojang] Jeb (Jens Bergensten)
            redstonesheep deleted
            Votes:
            1 Vote for this issue
            Watchers:
            4 Start watching this issue

              Created:
              Updated:
              Resolved: