`The workflow is not valid. ... (Line: 22, Col: 16): Unrecognized named-value: 'env'. Located at position 1 within expression: env.RUNNER`
IntermediateTroubleshootingWorkflows Not Triggering & Invalid Files
Answer
Likely causes → env context used where it is not available, such as runs-on, job-level if, concurrency at workflow level, or services.
Diagnose → Check the context availability table for that key.
Fix → Use vars.RUNNER or inputs.runner for runs-on, move the condition to step level, or compute the value in an earlier job and pass via needs.
Prevent → actionlint knows context availability and catches this before pushing.
More on Workflows Not Triggering & Invalid Files
You pushed a new workflow file and nothing appears in the Actions tab.Beginner`Invalid workflow file: .github/workflows/ci.yml#L14 You have an error in your yaml syntax on line 14`Beginner`The workflow is not valid. .github/workflows/ci.yml (Line: 9, Col: 5): Unexpected value 'steps'`BeginnerThe workflow runs on push to `main` but never on pull requests.BeginnerThe "Run workflow" button for `workflow_dispatch` does not appear.BeginnerA scheduled workflow stopped running weeks ago, no errors.Beginner