Fix autoentity validation & CLI/Schema mismatch bugs#3416
Open
RubenCerna2079 wants to merge 6 commits intomainfrom
Open
Fix autoentity validation & CLI/Schema mismatch bugs#3416RubenCerna2079 wants to merge 6 commits intomainfrom
RubenCerna2079 wants to merge 6 commits intomainfrom
Conversation
This was
linked to
issues
Apr 6, 2026
Contributor
There was a problem hiding this comment.
Pull request overview
This PR addresses two CLI/autoentities bugs in Data API builder: aligning the dab auto-config option naming with the JSON schema and improving dab validate behavior/error messaging when autoentity generation fails due to conflicts.
Changes:
- Renames the CLI option from
template.mcp.dml-tooltotemplate.mcp.dml-toolsto match the schema and updates related wiring in config generation. - Updates the autoentity/entity name conflict message in the MSSQL metadata provider to be more actionable.
- Wraps CLI validation in try/catch to avoid unhandled exceptions and log errors instead.
Reviewed changes
Copilot reviewed 3 out of 3 changed files in this pull request and generated 5 comments.
| File | Description |
|---|---|
| src/Core/Services/MetadataProviders/MsSqlMetadataProvider.cs | Updates conflict exception text for autoentity generation. |
| src/Cli/ConfigGenerator.cs | Adds exception handling to IsConfigValid and renames template MCP dml-tools option usage. |
| src/Cli/Commands/AutoConfigOptions.cs | Renames the CLI option to template.mcp.dml-tools and updates the corresponding property. |
souvikghosh04
requested changes
Apr 7, 2026
Contributor
souvikghosh04
left a comment
There was a problem hiding this comment.
Added some comments
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.
Why make this change?
autoentities.<def-name>.template.mcp.dml-tools, need to ensure that they are the same.dab validateproduces the wrong output message.What is this change?
For issue #3375:
AutoConfigOption.csfile so that it uses the proper name and changed the name of the variable to also match the schema in theConfigGenerator.cs.For issue #3335:
MsSqlMetadataProvider.csso that it is easier for the user to understand the error.ConfigGenerator.csso that instead of outputing an exception when dab throws an error it just logs the exception.How was this tested?
The issues were related to mismatches or to the output of log messages that can only be tested locally.
Sample Request(s)
dab auto-config --template.mcp.dml-tools true/false
dab validate --config test.json