python-jsonschema / python-jsonschema/check-jsonschema
Feature request: Allow validation of $schema specified in JSON file
Nobody has claimed this yet.
- Dominant language
- Python
- Stars
- 341
- Forks
- 71
- Avg merge
- 15d 20h
- Merged PRs (30d)
- 4
Description
Heyho,
I have created a generic schema that I want to run against json files in different projects. This works great by passing in a schemafile to the validator. But some projects/files could use a more specific schema based on the generic one.
I could specify a $schema in the json contents, but that would get ignored in favor of the schemafile passed in as a CLI argument. In case the user uses a json language server, they would get the proper typehints.
Could the $schema be respected by this cli tool? Maybe even opt-in.
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 tracing the CLI path that accepts a schemafile and validates JSON input. Determine how an opt-in $schema choice should interact with the schemafile argument, including which source takes precedence. Done means the behavior is implemented with documented semantics and covered by validation tests.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- python
- Domain
- cli
- Issue type
- Feature
- Difficulty
- 5/5
- Estimated time
- Over a week
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 25/100