pydantic2linkml complains about not able to translate the logic in validation function as in
or via grep -n -A1 "Unable to translate the logic contained in the after validation" dandischema/models.yaml.
Cause
These are the result of pydantic2linkml not able translate runtime logic in Pydantic validation functions to LinkML.
Stats
The validation functions that are causing the complains:
| Function |
Count |
Lines in models.yaml the complain appears |
AccessRequirements.open_or_embargoed |
1 |
331 |
Contributor.ensure_contact_person_has_email |
5 |
419, 423, 719, 732, 736 |
dandischema.models.BareAsset.digest_check |
1 |
461 |
dandischema.models.DandiBaseModel.ensure_schemakey |
1 |
658 |
dandischema.models.PropertyValue.ensure_value |
1 |
703 |
pydantic.networks.EmailStr._validate |
1 |
487 |
pydantic.types.ByteSize._validate |
1 |
395 |
Resource.identifier_or_url |
1 |
631 |
Total complains: 12
Solution
The runtime logic in each Pydantic validation function has to be evaluated individually for translation.
pydantic2linkml complains about not able to translate the logic in validation function as in
or via
grep -n -A1 "Unable to translate the logic contained in the after validation" dandischema/models.yaml.Cause
These are the result of pydantic2linkml not able translate runtime logic in Pydantic validation functions to LinkML.
Stats
The validation functions that are causing the complains:
models.yamlthe complain appearsAccessRequirements.open_or_embargoedContributor.ensure_contact_person_has_emaildandischema.models.BareAsset.digest_checkdandischema.models.DandiBaseModel.ensure_schemakeydandischema.models.PropertyValue.ensure_valuepydantic.networks.EmailStr._validatepydantic.types.ByteSize._validateResource.identifier_or_urlTotal complains: 12
Solution
The runtime logic in each Pydantic validation function has to be evaluated individually for translation.