Giter Site home page Giter Site logo

Comments (5)

handrews avatar handrews commented on June 15, 2024

@gavinwahl the percent encoding comes from section 6 of the JSON Pointer RFC 6901. So while it's technically not part of the JSON Schema suite of specifications, it's something that would be easy to get wrong if you're doing your own URI encoding of JSON Pointers.

Does that address your concerns about the validity of the test?

from json-schema-test-suite.

gavinwahl avatar gavinwahl commented on June 15, 2024

"A JSON Pointer can be represented in a URI fragment identifier by encoding it into octets using UTF-8 [RFC3629], while percent-encoding those characters not allowed by the fragment rule in [RFC3986]."

Are refs JSON Pointers, or JSON Pointers encoded as URI fragment identifiers? I don't think the linked section can apply, because refs are not encoded into octets. (There's no way to represent octets in JSON, only unicode code points)

from json-schema-test-suite.

handrews avatar handrews commented on June 15, 2024

@gavinwahl percent-encoded octets are being used here the same way as they are throughout URIs as described in RFC3986. The value of a "$ref" is a URI reference. There is nothing special about it. It's encoded into UTF-8 (or UTF-16 or UTF-32) like any other string data for JSON. URI-encoded JSON Pointers are one type of fragment supported by application/schema+json. So the pointer gets encoded into a URI fragment per RFCs 6901 and 3986, and the resulting URI is represented in JSON the same way any URI would be.

from json-schema-test-suite.

epoberezkin avatar epoberezkin commented on June 15, 2024

close?

from json-schema-test-suite.

handrews avatar handrews commented on June 15, 2024

Yeah, no reply for two months.

from json-schema-test-suite.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.