json-schema-org / json-schema-org/JSON-Schema-Test-Suite
Out-of-order schemas
Nobody has claimed this yet.
- Dominant language
- Python
- Stars
- 750
- Forks
- 307
- Avg merge
- 3d 17h
- Merged PRs (30d)
- 24
Description
I had an issue raised where someone put $defs at the beginning of their schema, and my solution didn't handle it properly.
In particular, my implementation failed to set the dialect from $schema before building the subschemas in the $defs, which meant they were built using the default dialect.
We should have some tests that ensure $schema is respected regardless of where it appears lexigraphically in the schema. (Of course, it needs to be at the root.)
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start by reading the linked issue 1044 and locating the existing schema fixtures or tests covering $schema and $defs. Add cases showing that a root-level $schema is respected even when $defs appears earlier lexicographically, then run the relevant test-suite checks to confirm both schema orders behave consistently.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- json
- Domain
- testing
- Issue type
- Bug
- Difficulty
- 3/5
- Estimated time
- 1-2 days
- Activity status
- Quiet
- Clarity
- Mostly clear
- Newbie friendliness
- 58/100