HYPERFLEET-1024: automate OpenAPI pipeline + Go module#2
Merged
Conversation
Owner
mliptak0
commented
May 7, 2026
- HYPERFLEET-853 - feat: Add Reconciled to OpenAPI spec
- HYPERFLEET-853 - feat: Fix ReconciledReason and message
- HYPERFLEET-853 - feat: Fix Reconciled message and add Finalized implementation
- HYPERFLEET-853 - feat: Fix observed_generation for all inconsistent examples (removed aliases inclusion
- HYPERFLEET-978 - feat: Add PUT command for internal status endpoints (1/2)
- HYPERFLEET-1024 - feat: automate OpenAPI pipeline, add Go module, and schema linting
- HYPERFLEET-1024 - chore: switch spectral lint to stoplightio/spectral-action
- HYPERFLEET-1024 - chore: add checks:write permission and bump action versions
- HYPERFLEET-1024 - chore: switch spectral lint to CLI with github-actions format
- HYPERFLEET-1024 - fix: install spectral-cli globally to avoid AJV lock file conflict
- HYPERFLEET-1024 - fix: change Error.instance format from uri to uri-reference
- try non-main branch
…xamples (removed aliases inclusion
HYPERFLEET-853 - feat: Add Reconciled to OpenAPI spec
HYPERFLEET-978 - feat: (1/2) Add PUT command for internal status endpoints …
… schema linting - Add CI workflow (ci.yml): builds all 4 schemas, checks consistency against committed files, lints with Spectral, and enforces version bump on every PR and push to main - Replace release.yml: triggers on push to main instead of manual tag; auto-creates annotated tag from main.tsp version; uploads all 4 schema artifacts (core+gcp openapi+swagger); idempotent on re-runs - Add go.mod + schemas/schemas.go: exposes all 4 generated schemas via //go:embed as embed.FS, enabling downstream Go consumers to import versioned schemas as a module dependency without local copies - Add .spectral.yaml with spectral:oas ruleset for OpenAPI 3.0 linting - Add @stoplight/spectral-cli ^6.15.1 as devDependency Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
…-action Replace manual npx spectral invocation with stoplightio/spectral-action@v0.8.13. The action bundles its own Spectral binary, avoiding Node.js version compatibility issues with npx. Remove @stoplight/spectral-cli devDependency as it is no longer needed. Update TypeSpec compiler to @1.11 in both workflows. Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
…versions Add checks:write to CI job so stoplightio/spectral-action can post inline PR annotations via GitHub API. Without this permission, the action fails with "Resource not accessible by integration" even when linting passes. Note: fork PRs cannot receive checks:write (GitHub security restriction) so annotation posting will still fail there, but branch PRs on the real repo will work correctly. Bump actions/checkout and actions/setup-node from v4 to v6 (Node.js 24 runtime) ahead of the June 2nd, 2026 Node.js 20 forced deprecation. Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
…ons format Replace stoplightio/spectral-action (Docker, hides output behind GitHub API annotations) with a direct npx spectral lint invocation using --format github-actions. This format emits ::error and ::warning workflow commands to stdout, which GitHub Actions renders as inline PR annotations natively without requiring checks:write or any API call. Output is fully visible in step logs. Remove checks:write permission as it is no longer needed. Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
…k file conflict The lock file (generated on Node.js 25) pins a nested AJV build inside @stoplight/spectral-core that fails in CI. Installing spectral-cli globally with npm install -g resolves a fresh compatible dependency tree, bypassing the lock file. Call spectral directly (not via npx) and keep it out of devDependencies since it is a CI-only tool installed separately. Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
…eference Per RFC 7807, the instance field identifies a specific occurrence of a problem and may be a relative URI reference. The example /api/hyperfleet/v1/clusters is a valid relative URI reference but not a valid URI (missing scheme), which caused Spectral's oas3-valid-schema-example rule to error. Changing the format annotation to uri-reference is semantically correct and fixes the lint error. Rebuild all four schema artifacts. Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
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.