Update linkml dependency to latest in main? #10
Labels
No labels
bug
duplicate
enhancement
help wanted
invalid
question
wontfix
No milestone
No project
No assignees
1 participant
Notifications
Due date
No due date set.
Dependencies
No dependencies set
Reference
q02/concepts.trr379.de#10
Loading…
Reference in a new issue
No description provided.
Delete branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
While generating the exports from the updated
dfg-cp-surveyschema (see #9), I came across a linkml error when POSTing aContributorrecord to a newdumpthingsbackend using the updated schema:This seems to be a known issue in LinkML: https://github.com/linkml/linkml/issues/3590, which is fixed by https://github.com/linkml/linkml/pull/3596. My understanding is that the error relates to an enum being inlined as a list (or part of an object that is inlined as a list), and before the linkml fix the code would convert such enum options to a set, which would not be hashable.
I tested the latest version of linkml
main, with my local dumpthings service, and the error disappeared:This leads to the question: should we make this concepts toolset dependent on latest linkml? or at least a recent commit that includes the fix(es)? That is, if there are no detrimental effects on the processes and outputs related to the other schemas in this toolset.
See
9d833ebddbI did an in-depth investigation. Explaining my approach/progress to future me or anyone else:
The starting point is the
dfg-cp-surveyschema (specifically with the updates in #9) and the fact that there is a submission workflo bus as explained above.So
linkmlneeds to be updated to the latest commit inmain, specifically fordumpthings, in order to solve this issue during record POSTing. I am going off of the assumption that it is good/useful to make the samelinkmlversion update to the schema generation workflow (i.e. on the concepts side). But perhaps this assumption needs to be questioned?I'm first moving forward from the concept side. I've generated the schema outputs using the previous setup (linkml v1.11.1, with existing patches, all succeeding).
And then I'm generating the same outputs with a new setup:
With the latter setup applying the
shaclgen.pypatches fails, so that needs to be fixed first.Interim comment from @c.moench:
Here is the updated patch for the state of linkml at the specific commit:
This now runs without failure.
Now I have
dfg-cp-surveyschema outputs for both versions of linkml.First check: there is no difference between the two yaml files.
It is difficult to determine differences in shacl outputs, because linkml changed the way it renders the TTL (property shapes were embedded in node shapes previously, now they are only referenced)
**Second check: in the exported SHACL, the prefixes are different for the
family_nameslot of theContributorclass: **1.11.1:dlthings:Person->dlthings:family_name1.11.1:trr379cps:Contributor->dlthings:family_namemain:dlthings:Person->dlthings:family_namemain:trr379cps:Contributor->trr379cps:family_name@c.moench pointed out the following:
I confirmed that applying these changes to the schema also has the desired effect in SHACL export.
Looking into the LinkML code:
Generator.schemaview.class_induced_slots()Generator.schemaviewcomes fromSchemaView, which is imported fromlinkml_runtime