[Schema Consistency] Schema Consistency Check - Cross-Schema Inconsistencies (2025-11-28) #4969
Closed
Replies: 2 comments 1 reply
-
|
/plan |
Beta Was this translation helpful? Give feedback.
1 reply
-
|
⚓ Avast! This discussion be marked as outdated by Schema Consistency Checker. |
Beta Was this translation helpful? Give feedback.
0 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Uh oh!
There was an error while loading. Please reload this page.
-
Analysis of cross-schema consistency between
main_workflow_schema.json,included_file_schema.json, andmcp_config_schema.jsonrevealed 6 significant inconsistencies primarily related to MCP tool definitions, permissions handling, and engine configurations.Key Findings: stdio_mcp_tool definition mismatch, missing permissions in main schema, engine enum differences, and $defs duplication without consistency.
Critical Issues (3 High/Medium Severity)
1. stdio_mcp_tool Definition Mismatch⚠️ HIGH
Problem: The
stdio_mcp_tool$def has inconsistent property definitions across schemas.Details:
headersandurlproperties (only in http_mcp_tool)headersandurlproperties instdio_mcp_toolEvidence:
Impact:
Location:
pkg/parser/schemas/included_file_schema.json:450-578(stdio_mcp_tool $def)Recommendation: Remove
headersandurlfrom included schema's stdio_mcp_tool definition to match main schema.2. Permissions Field Missing in Main Schema⚠️ MEDIUM
Problem: The
permissionsproperty is missing entirely from main_workflow_schema.json but fully defined in included_file_schema.json.Details:
permissionsproperty but NO sub-properties defined (empty object)Impact:
Recommendation: Copy the complete permissions property definition from included schema to main schema.
3. Engine Configuration Mismatch⚠️ MEDIUM
Problem: Engine enum values differ between main and included schemas.
Details:
$refto#/$defs/engine_configwith enums:["claude", "codex", "copilot", "custom"]["claude", "codex", "custom"](missing "copilot")Impact:
Location:
pkg/parser/schemas/included_file_schema.json:216-263Recommendation: Add "copilot" to included schema engine enum, or use $ref to engine_config.
Moderate Issues (3 Medium/Low Severity)
4. anyOf Requirements Inconsistency
Severity: MEDIUM
Main schema's
stdio_mcp_toolrequires eithercommandorcontainer, but MCP config schema'sanyOfis more flexible, allowing type inference fromtype,url,command, orcontainerfields.Recommendation: Align anyOf requirements - MCP config approach is more user-friendly.
5. Network Field Description Mismatch
Severity: LOW
Recommendation: Use main schema's comprehensive description in both places.
6. $defs Duplication Without Consistency
Severity: MEDIUM
Both main and included schemas define
stdio_mcp_toolandhttp_mcp_toolin their$defs, but with different properties. This violates DRY principle and creates maintenance burden.Impact:
Recommendation: Extract common $defs to shared schema file and use $ref, or designate main schema as authoritative.
Positive Findings ✅
commandandcontainercannot both be specifiedcontainerwhennetworkfield is presentTechnical Analysis Details
Comparison Matrix
Parser Implementation (mcp.go:66)
The parser struct accepts both
URLandHeadersfor all connection types (comments say "for http"). This permissive parsing relies on downstream validation, but included schema fails to restrict these fields properly.Cross-Schema $defs
Main schema $defs:
engine_config,github_token,http_mcp_tool,stdio_mcp_toolIncluded schema $defs:
http_mcp_tool,safe_job,stdio_mcp_toolThe overlapping
stdio_mcp_toolandhttp_mcp_tooldefinitions should be identical but aren't.Recommendations & Next Steps
High Priority
✅ Fix stdio_mcp_tool in Included Schema
headersandurlproperties from$defs.stdio_mcp_toolpkg/parser/schemas/included_file_schema.json:450-578✅ Add Permissions to Main Schema
✅ Add "copilot" to Included Schema
["claude", "codex", "copilot", "custom"]$refto#/$defs/engine_config(preferred)pkg/parser/schemas/included_file_schema.json:228Medium Priority
Unify $defs Across Schemas
Align anyOf Requirements
Standardize Descriptions
Low Priority
Parser Validation Enhancement
Documentation Update
Strategy Performance
Strategy Used: Cross-Schema Consistency & Type Analysis (Strategy #4)
Effectiveness: VERY HIGH
Why It Worked:
Key Insights:
Should Reuse: YES - Use every 4-5 analyses to catch schema drift in multi-schema projects.
Analysis Date: 2025-11-28
Schemas Analyzed: 3 (main_workflow_schema.json, included_file_schema.json, mcp_config_schema.json)
Total Inconsistencies: 6 (3 high/medium severity, 3 moderate/low severity)
Method: Automated jq-based schema comparison + parser code analysis
Files Examined: Schema files, pkg/parser/mcp.go, docs/src/content/docs/reference/tools.md
Beta Was this translation helpful? Give feedback.
All reactions