ChemROF currently cannot move cleanly to linkml==1.10.0 or linkml==1.11.0rc3 because SQL DDL generation fails in LinkML.
Upstream LinkML issue: linkml/linkml#3501
Symptom
Running ChemROF generation with newer LinkML fails during gen-project / gen-sqlddl:
sqlalchemy.exc.NoReferencedColumnError: Could not initialize target column for ForeignKey 'AtomOccurrence.id' on table 'AtomicBond': table 'AtomOccurrence' has no column named 'id'
The relevant ChemROF shape is:
ChemicalRelationship is an abstract parent with no authored identifier.
AtomOccurrence extends it and declares name as its identifier.
AtomicBond.subject and AtomicBond.object range over AtomOccurrence.
The expected SQL FKs are:
FOREIGN KEY(subject) REFERENCES "AtomOccurrence" (name)
FOREIGN KEY(object) REFERENCES "AtomOccurrence" (name)
Version boundary
A reduced LinkML reproducer shows this is not newly introduced by the 1.11.0rc3 release candidate:
linkml==1.8.7 + linkml-runtime==1.8.3: passes
linkml==1.9.6 + linkml-runtime==1.9.5: passes
linkml==1.10.0: fails
linkml==1.11.0rc3: fails
So this appears to be a LinkML 1.10.0 regression that ChemROF encounters when upgrading beyond the 1.9.x-era behavior.
Local verification
With linkml==1.11.0rc3, make test fails at project generation with the AtomOccurrence.id FK error.
With a local LinkML patch for linkml/linkml#3501, ChemROF make test completes successfully in a throwaway worktree, and generated SQL uses AtomOccurrence.name for AtomicBond.subject and AtomicBond.object.
Suggested action
Track linkml/linkml#3501 and retest ChemROF once a LinkML release or patch release includes the SQL DDL fix.
ChemROF currently cannot move cleanly to
linkml==1.10.0orlinkml==1.11.0rc3because SQL DDL generation fails in LinkML.Upstream LinkML issue: linkml/linkml#3501
Symptom
Running ChemROF generation with newer LinkML fails during
gen-project/gen-sqlddl:The relevant ChemROF shape is:
ChemicalRelationshipis an abstract parent with no authored identifier.AtomOccurrenceextends it and declaresnameas its identifier.AtomicBond.subjectandAtomicBond.objectrange overAtomOccurrence.The expected SQL FKs are:
Version boundary
A reduced LinkML reproducer shows this is not newly introduced by the
1.11.0rc3release candidate:So this appears to be a LinkML
1.10.0regression that ChemROF encounters when upgrading beyond the 1.9.x-era behavior.Local verification
With
linkml==1.11.0rc3,make testfails at project generation with theAtomOccurrence.idFK error.With a local LinkML patch for linkml/linkml#3501, ChemROF
make testcompletes successfully in a throwaway worktree, and generated SQL usesAtomOccurrence.nameforAtomicBond.subjectandAtomicBond.object.Suggested action
Track linkml/linkml#3501 and retest ChemROF once a LinkML release or patch release includes the SQL DDL fix.