-
-
Notifications
You must be signed in to change notification settings - Fork 63
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Use standard meta schema #199
Comments
@sim642: did you find the answer? |
No, I just ended up removing the meta schema reference before validation in a GitHub Actions workflow where I'm using ajv: - name: Work around meta-schema missing error # https://github.com/ajv-validator/ajv-cli/issues/199
run: |
sed -i 's|"$schema": "http://json-schema.org/draft-04/schema#",||' src/util/options.schema.json It's very ugly and not scalable to actual local usage of ajv-cli conveniently. |
Ajv doesn’t support draft4 in after v6. There is an option “draft” that would include the correct meta schema automatically without referencing it. |
What option? There isn't one here. I did find https://ajv.js.org/json-schema.html#draft-04, but installing ajv-draft-04 made no difference. I guess that cannot be used with ajv-cli? I also found |
From ajv's documentation I see there are standard meta schemas that can be used, but how to do that from the CLI?
Using
-m /usr/share/nodejs/ajv/lib/refs/json-schema-draft-04.json
doesn't seem to help at all:The text was updated successfully, but these errors were encountered: