All projects
CockroachDB
Postgres-matching error messages in CockroachDB's jsonpath scanner
Open source · Contributor · August 2026 — Present
Overview
CockroachDB is a distributed SQL database. I fixed how its jsonpath scanner reports errors for unquoted keys that start with a digit.
The fix
A key like $.2x was scanned as a number, so the error depended on the next character: $.2x came back as an invalid hexadecimal literal, $.2e as an invalid floating point literal, and $.2a as trailing junk. The fix reports all of them as trailing junk after the numeric prefix, matching Postgres, and updates the recorded Postgres differences. $[0x] keeps the hexadecimal message, since it is accurate there.
Contributions