Validate against external profile
See original GitHub issueOverview
I want to validate my package against an external profile that is an extension of tabular-data-package
. If I read the specs (https://specs.frictionlessdata.io/profiles/#profile-property) correctly:
Custom profiles MUST have a profile property, where the value is a unique identifier for that profile. This unique identifier MUST be a string and can be in one of two forms. It can be an id from the official Data Package Schema Registry, or, a fully-qualified URL that points directly to a JSON Schema that can be used to validate the profile.
This can be done with:
"profile": "https://my-profile.json",
However, it seems only very specific values for profile
are checked, and otherwise it falls back to tabular-data-package
? If I validate the same data package with:
- `“profile”: “tabular-data-package” => valid
"profile": "fiscal-data-package"
=> several validation errors, including:
The data package has an error: “‘fiscal-data-package’ is not one of [‘tabular-data-package’]” at “profile” in metadata and at “allOf/0/properties/profile/enum” in profile
"profile": "https://specs.frictionlessdata.io/schemas/fiscal-data-package.json"
=> valid
Is this expected behaviour? Would it be possible to:
- Validate against the linked schema, if that is a valid JSON Schema?
- Raise an error if the value for
profile
is not a valid JSON Schema or a string value listed on https://specs.frictionlessdata.io/schemas/registry.json?
Please preserve this line to notify @roll (lead of this repository)
Issue Analytics
- State:
- Created 3 years ago
- Reactions:8
- Comments:11 (11 by maintainers)
Thanks @peterdesmet,
I’ll investigate
@peterdesmet Yes. E.g. for the
data-package
profile internally it just drops theresources
JSON Schema rules from the package profile and uses it for every resource individually