github / github/vscode-github-actions
Feature: warn when workflow YAML validates but would fail at runtime (schema vs runner gap)
- Lenguaje dominante
- TypeScript
- Estrellas
- 660
- Forks
- 213
- Métricas de merge de PR
- Sin PR fusionados en 30 d
Descripción
### Summary
Extension validates workflow YAML against the schema, but many mistakes only surface after `git push` triggers a runner:
- `runs-on:` referencing a self-hosted label that has no online runner
- `uses: owner/repo@ref` where `ref` no longer resolves (deleted tag/branch, moved SHA)
- `secrets: inherit` on a reusable workflow whose caller does not actually inherit
- `permissions:` narrower than what a step needs (e.g. `contents: read` + a step that pushes)
- `if:` expression referencing a context that is empty for the trigger (e.g. `github.event.pull_request.*` on `push`)
Each case validates green locally, then burns a runner minute and a red X on the PR.
### Proposal
A "runtime-plausibility" pass, opt-in (`github-actions.runtimeChecks.enabled`), that runs alongside schema validation and surfaces `Information`-level diagnostics for:
1. Unresolvable `uses:` refs (HEAD probe via the authenticated session already used for the API tree)
2. `runs-on:` labels not present in the repo's runner list
3. `permissions:` narrower than the union of permissions declared by any resolvable action's `action.yml`
4. Context references that are empty for the declared `on:` triggers
None block save; all are dismissible. Runs on open + on save, cached by workflow-file hash.
### Why not `act` / nektos
`act` runs the whole workflow in Docker; this is a static, seconds-scale lint. Complementary, not overlapping.
### Related
- #593 (commit-pinned actions reported unresolved) - same "static analysis of `uses:`" surface
- #609 (false-positive missing-required-inputs) - related schema-vs-runtime gap in the other direction
Guía de contribución
Línea de trabajo
Comienza rastreando el punto de entrada existente para la validación del esquema YAML del workflow y la sesión autenticada que ya se utiliza para el árbol de API. Revisa cómo se resuelven los archivos action.yml y los disparadores del workflow; después, determina cómo encajan las cuatro comprobaciones de tiempo de ejecución opt-in y la caché workflow-file-hash junto a la validación. Se considera terminado cuando los diagnósticos de Information descartables se ejecutan al abrir y guardar sin bloquear los guardados.
Escrito por el modelo de indexación a partir del texto del issue.
Evaluación
- Stack tecnológico
- github-actions, typescript
- Área
- ci-cd, devtools
- Tipo de issue
- Nueva funcionalidad
- Dificultad
- 5/5
- Tiempo estimado
- Más de una semana
- Estado de actividad
- Tranquilo
- Claridad
- Bastante claro
- Aptitud para principiantes
- 35/100