claude-executor: fail when claude-code-action skips itself

Aperta Adatta ai principianti
#72 0 commenti 0 reazioni 0 assegnatari Vedi su GitHub

Nessuno ha ancora preso questa issue.

Valutazione

Difficoltà
2/5
Tempo stimato
1-3 ore
Idoneità per principianti
82/100
Tipo di issue
Bug
Chiarezza
Specificata chiaramente
Stato di attività
Attiva
Stack tecnologico
github-actions, yaml
Ambito
ci-cd

Direzione di ricerca

Apri claude-executor.yml e individua i passaggi claude-api e claude-bedrock, poi confronta con il controllo equivalente già unito in autodoc-executor.yml (#70). Aggiungi il passaggio di guardia dopo ogni passaggio Claude usando la stessa condizione di output skipped_due_to_workflow_validation_mismatch, scegliendo tra ::error::/exit 1 e ::warning:: in base alla nota sulle PR che modificano i workflow. Fatto significa che una esecuzione in cui l'action salta se stessa non viene più segnalata come verde.

Scritto dal modello di indicizzazione a partire dal testo della issue.

Descrizione

bug

claude-code-action can skip without running Claude and still report success. It does this when the workflow file that triggered the run differs from the default branch's copy, and it signals the skip only through the skipped_due_to_workflow_validation_mismatch output. claude-executor.yml never checks that output.

The "Report internal SDK failure" step added in #61 doesn't catch it either. It checks is_error in the execution file, and a skip never starts a Claude turn, so there's no error to find. If the skip leaves execution_file empty, the step's if: condition skips it outright. The result is that a consumer PR that edits its own Claude workflow can go green without Claude having run.

claude-executor.yml correctly doesn't pass github_token, because it needs the App token for comments and signed commits. That's fine; the gap is only the missing check on the output.

Fix: add a step after each Claude step, like the one in autodoc-executor.yml (#70):

- name: Fail if the action skipped itself
  if: steps.claude-api.outputs.skipped_due_to_workflow_validation_mismatch == 'true' || steps.claude-bedrock.outputs.skipped_due_to_workflow_validation_mismatch == 'true'
  run: |
    echo "::error::claude-code-action skipped (workflow validation) without running Claude"
    exit 1

If failing would block legitimate workflow-editing PRs, emit ::warning:: instead.

Raised in review of #70.

Lingua principale
Nessun dato sulla lingua
Stelle
1
Fork
0
Merge medio
16m
PR unite (30g)
1

Preparare l'ambiente

Questo progetto non fornisce container di sviluppo, Dockerfile né guida per i contributori, quindi l'ambiente è a tuo carico: parti dal suo README e consulta la nostra guida al primo contributo per i passaggi generali.

Come iniziare

  1. Leggi tutta la issue e poi la guida ai contributi del progetto.
  2. Commenta sulla issue per dire che te ne occupi tu — evita che due persone facciano lo stesso lavoro.
  3. Fai un fork del repository e lavora su un branch.
  4. Apri una pull request che faccia riferimento al numero della issue.

Altre issue di dotCMS/ai-workflows

Tutte le issue di dotCMS/ai-workflows

Issue simili

Altre issue su DevOps

Ricevi le nuove issue nella tua casella

Un breve riepilogo di issue GitHub adatte ai principianti.