Tell users when a registered extension loads nothing (instead of silently skipping it)#131
Merged
JordanMarr merged 1 commit intoJun 10, 2026
Conversation
…ension A type-mapping extension registered via TOML ([extensions] type_mappings) that yields zero ISqlHydraExtension implementations — a wrong/typo'd assembly name, or one that failed to load — was silently ignored: generation ran without the mapping and the affected columns were simply missing from the output, with dotnet sqlhydra exiting 0. loadNamed now raises a clear, actionable error in that case, pointing at the likely fixes (the TOML name vs the package/assembly that implements the extension; or a load failure). Adds DB-free unit tests for the named-but-empty and missing-dll paths. Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
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.
small usability fix to the cli when using extensions ...
Register an extension in your TOML (
[extensions] type_mappings) that loads noIExtendTypeMapping— a wrong/typo'd name, the wrong assembly, or types that failed to load — and SqlHydra silently ignores it: generation runs without the mapping and exits0, so the only symptom is the affected columns quietly coming out unmapped, w ith no error.loadNamednow errors instead, naming the extension and pointing at the likely fixes (does the[extensions]name match the package that implements it, is it referenced, did its types fail to load?).