Skip to content

refactor!: move v1alpha1 validation logic to it's own package#4544

Merged
AustinAbro321 merged 2 commits intomainfrom
v1alpha1-move-validate
Jan 28, 2026
Merged

refactor!: move v1alpha1 validation logic to it's own package#4544
AustinAbro321 merged 2 commits intomainfrom
v1alpha1-move-validate

Conversation

@AustinAbro321
Copy link
Copy Markdown
Member

@AustinAbro321 AustinAbro321 commented Jan 22, 2026

Description

Create an internal package to host v1alpha1 specific validation logic. Follow strategy laid out by zarf-dev/proposals#49

This PR includes SDK breaking changes:

  • removes ValidatePackageSchema function which is replaced by the existing function ValidatePackageSchemaAtPath()
  • lint.SupportedOS() -> v1alpha1.SupportedOS()
  • lint.IsLowercaseNumberHyphenNoStartHyphen -> state.DeployedPackageNameRegex

Related Issue

Relates to #3433

Checklist before merging

Signed-off-by: Austin Abro <austinabro321@gmail.com>
@netlify
Copy link
Copy Markdown

netlify Bot commented Jan 22, 2026

Deploy Preview for zarf-docs canceled.

Name Link
🔨 Latest commit e0474a1
🔍 Latest deploy log https://app.netlify.com/projects/zarf-docs/deploys/69726d218dd6bf000825927f

@codecov
Copy link
Copy Markdown

codecov Bot commented Jan 22, 2026

Codecov Report

❌ Patch coverage is 25.00000% with 3 lines in your changes missing coverage. Please review.

Files with missing lines Patch % Lines
src/api/v1alpha1/component.go 0.00% 2 Missing ⚠️
src/pkg/packager/generate.go 0.00% 1 Missing ⚠️
Files with missing lines Coverage Δ
src/internal/api/v1alpha1/validate.go 90.72% <ø> (ø)
src/pkg/lint/schema.go 67.69% <ø> (+11.69%) ⬆️
src/pkg/packager/load.go 66.44% <ø> (-0.87%) ⬇️
src/pkg/packager/load/load.go 43.45% <100.00%> (ø)
src/pkg/state/state.go 30.63% <ø> (ø)
src/pkg/packager/generate.go 0.00% <0.00%> (ø)
src/api/v1alpha1/component.go 18.36% <0.00%> (-0.79%) ⬇️

... and 3 files with indirect coverage changes

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.
  • 📦 JS Bundle Analysis: Save yourself from yourself by tracking and limiting bundle sizes in JS merges.

Signed-off-by: Austin Abro <austinabro321@gmail.com>
@AustinAbro321 AustinAbro321 marked this pull request as ready for review January 22, 2026 20:38
@AustinAbro321 AustinAbro321 requested review from a team as code owners January 22, 2026 20:38
Copy link
Copy Markdown
Member

@brandtkeller brandtkeller left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

lgtm

@AustinAbro321 AustinAbro321 added this pull request to the merge queue Jan 28, 2026
Merged via the queue into main with commit 502a6be Jan 28, 2026
30 checks passed
@AustinAbro321 AustinAbro321 deleted the v1alpha1-move-validate branch January 28, 2026 18:33
@github-project-automation github-project-automation Bot moved this to Done in Zarf Jan 28, 2026
AustinAbro321 added a commit that referenced this pull request Feb 4, 2026
Signed-off-by: Austin Abro <austinabro321@gmail.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

Status: Done

Development

Successfully merging this pull request may close these issues.

2 participants