fix(ci): use the languages input for CodeQL init#315
Merged
Conversation
The `github/codeql-action/init` input is `languages`, not `language`. With the singular key the action warned "Unexpected input(s) 'language'" and ignored it, falling back to language autodetection so both matrix legs analyzed the same detected set instead of the intended `go` and `actions`. Use `languages` so each leg initializes the language the matrix selects.
b751bce to
6fdf988
Compare
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 subscribe to this conversation on GitHub.
Already have an account?
Sign in.
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
Rename the CodeQL
initinput fromlanguagetolanguages, the name the action actually accepts.Why
With the singular
languagekey the action logs "Unexpected input(s) 'language'" and ignores it, then autodetects languages. Both matrix legs (go,actions) end up analyzing the same autodetected set instead of the language the matrix selected, so the intended per-language split is not honored.How to verify
The CodeQL run on this PR completes without the "Unexpected input(s) 'language'" annotation, and the
Analyze (go)andAnalyze (actions)jobs each initialize their own language.Notes for reviewers
The matrix dimension is still named
language; only the action input key changed.