feat(validation): Support v1 Extension Format in Bundle Validation #242
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.
Description
Fixes bundle validation to support the v1 extension format while maintaining backward compatibility with the legacy format (PR #226). This resolves bundle upload failures for AnthroCollect and other apps using the newer extension system.
Problem:
Bundle uploads were failing with:
Root Cause:
renderer/tester)path/exportproperties)Solution:
Updated validation to support both formats with auto-detection:
renderer/testerwithpath/export"html"to known formats (used byHtmlLabelRenderer)Type of Change
Component(s) Affected
Related Issue(s)
PR #226.
Changes Made
Core Implementation
Updated
ExtensionDefinitionstruct:Version,Description, andSchemasfields for v1 formatDefinitionsfor legacy supportCreated
ExtensionModuleReferencestruct:pathandexportfields used in v1 formatUpdated
ExtensionRendererstruct:Rendererfromstringto*ExtensionModuleReference(supports objects)Testerfromstringto*ExtensionModuleReference(supports objects)Name,Format,Module) for backward compatibilityUpdated validation logic:
renderer.path/exportandtester.path/exportname,format,modulefieldsFixed
ext.jsonfile handling:ext.jsonfiles from form file validationext.jsonfrom being treated as invalid form filesAdded HTML format support:
"html"toknownFormatslist in both schema and UI schema validationHtmlLabelRendererwhich usesformat: "html"Test Coverage
Testing
Unit Tests
✅ All tests pass (16/16):
Real Bundle Testing
✅ Tested with actual AnthroCollect bundle (
bundle-v1.0.6.zip):Test Results
Breaking Changes
Documentation Updates
Files Modified
synkronus-cli/pkg/validation/bundle.go- Main validation logicsynkronus-cli/pkg/validation/bundle_test.go- Test casesImpact
Related PRs
Checklist