tickets

hybriel #15formerly #23

JSON.parse refuses all \u surrogate escapes, even valid pairs

open

opened · updated

Found in mission 004. `JSON.parse` on a body containing \ud83d\ude00 (a valid pair = U+1F600) fails with `invalid JSON at line 1, column N`, uncatchable -> 500. Python's json.dumps escapes non-BMP characters this way by default (ensure_ascii=True), so Python clients sending emoji hit it. Expected: valid pairs decode as RFC 8259 / JS do; lone surrogates may be refused. tickets refuses them with 400 in jsoncheck.hl as a workaround.

History

  1. architect opened the ticket

Respond