Repository navigation
Conversation
Contributor
There was a problem hiding this comment.
🟡 Changes recommended
The change defaults model generation and conversion to JSON while pack manifests and CI workflows still recognize only YAML, so generated models would be omitted from CodeQL and workflow processing.
3 open issues
What changed in this PR
This pull request changes Models-as-Data generation and conversion tools to produce JSON output by default, but repository manifests and workflows still match only .model.yml files.
Changes:
- Defaults standalone and bulk model generation to JSON.
- Changes extension conversion to emit
.model.jsonfiles. - Requires coordinated updates to pack manifests and workflow globs so generated JSON files are consumed and staged.
| File | Description |
|---|---|
| misc/scripts/models-as-data/generate_mad.py | Defaults standalone model generation to JSON output. |
| misc/scripts/models-as-data/convert_extensions.py | Changes converted model extension files to use the .model.json format. |
| misc/scripts/models-as-data/bulk_generate_mad.py | Defaults bulk model generation to JSON output. |
Review effort: Lite (auto)
| "--extension-format", | ||
| choices=["json", "yaml"], | ||
| default="yaml", | ||
| default="json", |
| # N.B. change this to .model.json to change the output format: | ||
| self.modelFileExtension = ".model.yml" | ||
| # N.B. change this to .model.yml to change the output format: | ||
| self.modelFileExtension = ".model.json" |
| "--extension-format", | ||
| choices=["json", "yaml"], | ||
| default="yaml", | ||
| default="json", |
This branch has not been deployed
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.

Now that I'm merging PRs to convert all existing models to JSON, changing the default here ensures any new ones should also be generated in the JSON format.