Add lock schema compatibility gate for workflow lock files#16369
Closed
davidahmann wants to merge 1 commit intogithub:mainfrom
Closed
Add lock schema compatibility gate for workflow lock files#16369davidahmann wants to merge 1 commit intogithub:mainfrom
davidahmann wants to merge 1 commit intogithub:mainfrom
Conversation
Contributor
|
Accidental close |
Contributor
|
I still don't understand why we need this. |
Contributor
Author
|
You’re right, the current framing is too broad. The need is only for gh-aw metadata compatibility (fields/comments we parse ourselves), not GitHub Actions YAML schema validation. I’ll narrow this to metadata-dependent paths and drop schema gating for plain workflow-name parsing. If that still feels unnecessary, I’m happy to close this PR and revisit with a concrete migration breakage repro. |
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.
Problem
Lock files were parsed without an explicit schema compatibility gate. Incompatible lock schema changes could be consumed silently and lead to ambiguous behavior instead of a deterministic fail-closed error.
What changed
# gh-aw-lock-schema-version: 1) when writing lock output.Validation
go test ./pkg/workflow -run 'Test(WriteWorkflowOutput|ValidateLockSchemaCompatibility|ResolveWorkflowName_IncompatibleLockSchema|ProcessStopAfterConfiguration_FailsOnIncompatibleLockSchema|ExtractStopTimeFromLockFile)'✅make agent-finish❌ (environment/tooling mismatch while installingactionlint, compile errors inyaml.ParserErrorsymbols)make fmt✅go test ./pkg/workflow -short❌ (baseline shell incompatibility in existing git patch tests:TestGitPatchFromHEADCommits,TestGitPatchPrefersBranchOverHEAD,TestGitPatchNoCommitsdue${var@Q}bad substitution)Refs #16360