linkml / linkml-runtime

Runtime support for linkml generated models
https://linkml.io/linkml/
Creative Commons Zero v1.0 Universal
22 stars 21 forks source link

Add inheritance ordering, unify element ordering #313

Closed sneakers-the-rat closed 3 months ago

sneakers-the-rat commented 3 months ago

Schemaview seems like the right place to keep sorting methods that will be used by all the generators. Lo and behold, it already is!

Added the inheritance ordering method used by pythongen and pydanticgen, put all ordering into a single method.

Must be merged before the adjoining linkml PR (will add link in a second) and linkml lockfile must be regenerated to reflect the release containing this PR

codecov[bot] commented 3 months ago

Codecov Report

Attention: Patch coverage is 52.17391% with 22 lines in your changes are missing coverage. Please review.

Project coverage is 62.84%. Comparing base (deb2ba3) to head (e5b903e). Report is 4 commits behind head on main.

Files Patch % Lines
linkml_runtime/utils/schemaview.py 51.11% 20 Missing and 2 partials :warning:
Additional details and impacted files ```diff @@ Coverage Diff @@ ## main #313 +/- ## ========================================== - Coverage 62.92% 62.84% -0.09% ========================================== Files 62 63 +1 Lines 8532 8580 +48 Branches 2436 2444 +8 ========================================== + Hits 5369 5392 +23 - Misses 2553 2576 +23 - Partials 610 612 +2 ```

:umbrella: View full report in Codecov by Sentry.
:loudspeaker: Have feedback on the report? Share it here.