ci: preserve SCA compatibility without ONNX - #445
Merged
Conversation
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.
What changed
Follow up #444 so the reusable SCA workflow follows the native dependency contract of the checked-out MatrixOne branch instead of always imposing current
main's ONNX requirement.thirdparties/Makefileexposes theonnxruntimetarget.Resolve PR license scopeon the legacymake static-checkpath, where its outputs are never consumed.Why
matrixorigin/CI/.github/workflows/ci.yaml@mainis also consumed by maintenance branches. MatrixOne4.1-devhas the other native SCA prerequisites and buildscgo/libmo.apluscgo/libmo.so, but predates the ONNX target. After #444, an exact native cache for that branch could never be considered usable and the post-build ONNX assertion would deterministically fail.The license-scope action was also invoked unconditionally even though legacy branches exit through
make static-check. That added an unnecessary GitHub API dependency and latency without changing the result.Behavior matrix
main,4.2-dev4.1-devmake static-checkfallback.This is intentionally scoped to the regression introduced by #444. Older 2.x branches already lack other native prerequisites required by the reusable workflow; this PR does not claim to restore that pre-existing compatibility.
Risk and performance
Validation
actionlint -shellcheck= -pyflakes= .github/workflows/ci.yamlnode --test actions/resolve-sca-license-scope/scope.test.js(11/11 passed)bash actions/restore-sca-analysis-cache/cache-state.test.shbash actions/restore-sca-analysis-cache/environment-hash.test.shthirdparties/Makefileonmain,4.2-dev, and4.1-dev: ONNX is present on the first two and absent on4.1-dev.4.1-dev's CGo Makefile still owns bothlibmo.aandlibmo.sooutputs.