Skip to content

fix(cli): validate UModel YAML files#94

Open
Chloride233 wants to merge 1 commit into
alibaba:mainfrom
Chloride233:fix/cli-validate-yaml
Open

fix(cli): validate UModel YAML files#94
Chloride233 wants to merge 1 commit into
alibaba:mainfrom
Chloride233:fix/cli-validate-yaml

Conversation

@Chloride233

Copy link
Copy Markdown
Contributor

Summary

This closes a small gap in the local authoring loop: the CLI docs point umctl umodel validate at a quickstart UModel YAML file, but the command only wrapped JSON before calling the validate API.

Now umctl umodel validate can accept one schema-style UModel YAML file and send the same elements payload the API already expects.

Scope

  • Reuses the UModel payload normalizer from import parsing.
  • Keeps umodel put JSON-only.
  • No REST API, MCP, SDK, schema, or Web UI changes.

Tests

  • go test ./cmd/umctl/cmd -run 'TestUModelValidateAcceptsSchemaStyleYAMLFile|TestCLICommandsRouteToCorrectEndpoints' -count=1
  • go test ./internal/umodel/payload -count=1
  • go test ./internal/bootstrap ./internal/sampledata -run 'QuickStart|quickstart|Sample|Localization' -count=1
  • git diff --check

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant