-
Notifications
You must be signed in to change notification settings - Fork 1
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
Build alternate serializations with linkml-convert #83
base: main
Are you sure you want to change the base?
Conversation
Doesn't work yet - getting this error when testing on a single yaml entry:
|
Using the pydantic classes yields a more informative error:
|
as an extra test, can you run the gen-linkml generator on your original schema, then with the output of that, generate the pydantic classes? that would help me debug. gen-linkml does a lot of inference that may or may not be taking advantage of in linkml-convert. |
OK - if I use gen-linkml like so:
and then make Pydantic like so:
Then if I run the linkml-convert alone with just the schema, I get this:
and if I use the pydantic, I get this:
|
pydantic isn't expected to work this way as it relies on conventions for the data classes (we should have an option for convert to bypass the schema/python - not necessary for most transforms!) I would first try simpler conversions, e.g json to json |
Needed to make some schema changes to get this to work: more classes needed
id
fields and needed to define their category with thedesignates_type
flag.