You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Nobody else seems to have discussed this, but it seems to be impossible ajv-cli to validate YAML files that contain multiple documents. My underlying goal is replacing RoadieHQ/backstage-entity-validator with more pure AJV, because BEV does not permit passing many of the AJV options.
The validator seems to throw strange errors
error: Invalid left-hand side expression in prefix operation
error: Unexpected identifier 'REDACTED-INTERNAL-STRING'
error: Unexpected token 'for'
I don't want to split the documents up into multiple files because I'd like to return original document line number references to the errors, to help end-users fix their documents.
data/schemas/allOf.v1alpha1.schema.json contains an allOf array w/ if/then conditionals to select between different schemas based on a value in a top-level key (it's not the name of the top-level key, so I can't use discriminator). The globbing hack is to avoid ingesting the allOf schema twice.
Nobody else seems to have discussed this, but it seems to be impossible
ajv-cli
to validate YAML files that contain multiple documents. My underlying goal is replacingRoadieHQ/backstage-entity-validator
with more pure AJV, because BEV does not permit passing many of the AJV options.The validator seems to throw strange errors
I don't want to split the documents up into multiple files because I'd like to return original document line number references to the errors, to help end-users fix their documents.
data/schemas/allOf.v1alpha1.schema.json
contains anallOf
array w/ if/then conditionals to select between different schemas based on a value in a top-level key (it's not the name of the top-level key, so I can't usediscriminator
). The globbing hack is to avoid ingesting theallOf
schema twice.The text was updated successfully, but these errors were encountered: