refactor: promote the extension interfaces out of the internal namespace - #116
Merged
ehennestad merged 1 commit intoSep 3, 2026
Merged
Conversation
ehennestad
force-pushed
the
promote-extension-interfaces
branch
from
August 31, 2026 10:39
fe30dda to
29ac583
Compare
Contributor
Test Results (R2022a)764 tests 763 ✅ 2m 30s ⏱️ Results for commit 0b30a27. ♻️ This comment has been updated with latest results. |
Contributor
Codecov Report✅ All modified and coverable lines are covered by tests. Additional details and impacted files@@ Coverage Diff @@
## fix-collection-store-options #116 +/- ##
===============================================================
Coverage ? 80.29%
===============================================================
Files ? 424
Lines ? 4065
Branches ? 0
===============================================================
Hits ? 3264
Misses ? 801
Partials ? 0 ☔ View full report in Codecov by Harness. 🚀 New features to boost your workflow:
|
ehennestad
force-pushed
the
promote-extension-interfaces
branch
2 times, most recently
from
September 1, 2026 20:58
6402b97 to
ed9b383
Compare
ehennestad
force-pushed
the
promote-extension-interfaces
branch
2 times, most recently
from
September 2, 2026 14:56
8eff264 to
bd0f589
Compare
ehennestad
force-pushed
the
promote-extension-interfaces
branch
from
September 2, 2026 16:37
bd0f589 to
083ed79
Compare
ehennestad
force-pushed
the
promote-extension-interfaces
branch
from
September 2, 2026 17:30
083ed79 to
5491383
Compare
ehennestad
force-pushed
the
promote-extension-interfaces
branch
from
September 2, 2026 17:51
5491383 to
3c95931
Compare
ehennestad
force-pushed
the
promote-extension-interfaces
branch
from
September 2, 2026 18:39
3c95931 to
1c77afe
Compare
External libraries integrate a database or format by subclassing the
serialization and resolution bases, but those classes lived in internal
namespaces, so building on openMINDS_MATLAB meant depending on its
internals. The extension surface is now public and grouped by kind:
openminds.interface.LinkResolver (was openminds.internal.resolver
.AbstractLinkResolver; contract only, sits beside MetadataStore,
and the rename drops the class attribute from the name)
openminds.abstract.BaseSerializer (was openminds.internal.serializer
.BaseSerializer; partial implementation meant for subclassing,
beside BaseVisitor and BaseTransformer)
openminds.abstract.BaseDeserializer (same move)
An external backend now implements openminds.interface.MetadataStore and
openminds.interface.LinkResolver, and subclasses the abstract serializer
pair only when it needs its own format. The JSON-LD implementations stay
internal.
struct2jsonld is deleted. Nothing has called it since deserialization
moved onto the deserializer.
Breaking change for openminds-kg-sync: KGResolver's superclass becomes
openminds.interface.LinkResolver, on top of the resolveNode rename it
already needs from the traversal rework.
Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
ehennestad
force-pushed
the
promote-extension-interfaces
branch
from
September 2, 2026 20:15
1c77afe to
0b30a27
Compare
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
External libraries integrate a database or format by subclassing the serialization and resolution bases, but those classes lived in internal namespaces. Building on openMINDS_MATLAB therefore meant depending on its internals — openminds-kg-sync subclasses
openminds.internal.resolver.AbstractLinkResolverandopenminds.internal.serializer.JsonLdSerializertoday. This promotes the extension surface, grouped by kind:openminds.internal.resolver.AbstractLinkResolveropenminds.interface.LinkResolverMetadataStore. The rename also stops the class attribute appearing in the name.openminds.internal.serializer.BaseSerializeropenminds.abstract.BaseSerializerBaseVisitorandBaseTransformer.openminds.internal.serializer.BaseDeserializeropenminds.abstract.BaseDeserializerThe story for an external backend is now: implement
openminds.interface.MetadataStoreandopenminds.interface.LinkResolver; subclass the abstract serializer pair only if the backend needs its own wire format. The JSON-LD implementations stay internal.struct2jsonldis deleted — nothing has called it since deserialization moved onto the deserializer earlier in this stack.Breaking change for openminds-kg-sync:
KGResolver's superclass becomesopenminds.interface.LinkResolver, on top of theresolveNoderename it already needs from #108.KGSerializerstill subclasses the internalJsonLdSerializer; promoting the concrete JSON-LD classes is left as a separate decision, since they are implementations rather than contracts.🤖 Generated with Claude Code
Note: an earlier revision of this PR accidentally included
code/livescripts/example_metadata.jsonld, a file the tutorial tests generate. It is removed from the commit, and the file is gitignored in the first PR of the stack.