pipedv1 Terraform plugin fails to parse plans that invoke actions

Aperta Adatta ai principianti
#7,676 0 commenti 0 reazioni 0 assegnatari Vedi su GitHub

I maintainer di solito rispondono entro 1 giorno

@abhiraj75 ci sta già lavorando.

Dal 27/11/2026.

  • #7677 di @abhiraj75 — aperta

Valutazione

Difficoltà
2/5
Tempo stimato
1-3 ore
Idoneità per principianti
78/100
Tipo di issue
Bug
Chiarezza
Specificata chiaramente
Stato di attività
Attiva
Stack tecnologico
go, terraform

Direzione di ricerca

Inizia da pkg/app/pipedv1/plugin/terraform/provider/terraform.go ed esamina planHasChangeRegex e parsePlanResult; poi trova i test correlati all’analisi dell’output del piano Terraform. Riproduci il malfunzionamento con una riga di riepilogo che includa Actions: 1 to invoke. e verifica che i riepiloghi vengano analizzati correttamente sia con sia senza questo suffisso.

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

Descrizione

What happened:

Since Terraform v1.14.0, a plan that triggers action blocks prints the summary as

Plan: 1 to add, 0 to change, 0 to destroy. Actions: 1 to invoke.

planHasChangeRegex in pkg/app/pipedv1/plugin/terraform/provider/terraform.go ends with to destroy\.$, so it does not match this line. parsePlanResult returns unable to parse plan output, and the TERRAFORM_PLAN stage and plan preview fail.

What you expected to happen:

The plan is parsed as before (1 to add), and the stage continues.

How to reproduce it:

  1. Use Terraform 1.14.0 or later with this config:
terraform {
  required_providers {
    local = { source = "hashicorp/local", version = "2.9.1" }
  }
}

action "local_command" "notify" {
  config {
    command   = "echo"
    arguments = ["deployed"]
  }
}

resource "terraform_data" "app" {
  input = "v1"
  lifecycle {
    action_trigger {
      events  = [after_create, after_update]
      actions = [action.local_command.notify]
    }
  }
}
  1. Run a TERRAFORM_PLAN stage, or call provider.Terraform.Plan on the directory. It fails with Failed to plan (unable to parse plan output).

Checked with 1.14.0 and 1.17.2. 1.13.5 prints no Actions: suffix and parses fine. pipedv0 has the same regex.

Environment:

  • piped version: pipedv1 at master (2080402c2)
  • control-plane version: not relevant
  • Others: Terraform v1.14.0+, hashicorp/local v2.9.1

I'd like to work on this. The fix is to allow an optional Actions: N to invoke. suffix in the regex, with test cases.

Lingua principale
Go
Stelle
1.4k
Fork
403
Merge medio
2g 9h
PR unite (30g)
40

Preparare l'ambiente

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 pipe-cd/pipecd

Tutte le issue di pipe-cd/pipecd

Issue simili

Altre issue su Go

Ricevi le nuove issue nella tua casella

Un breve riepilogo di issue GitHub adatte ai principianti.