pipedv1 Terraform plugin fails to parse plans that invoke actions
メンテナーはふだん 1 日以内に返信
評価
- 難易度
- 2/5
- 見積もり時間
- 1〜3時間
- 初心者へのやさしさ
- 78/100
- issue の種類
- バグ
- 明瞭さ
- 明確に書かれている
- 活発さ
- 活発
- 技術スタック
- go, terraform
- 領域
- devops, infrastructure
調査の方向性
pkg/app/pipedv1/plugin/terraform/provider/terraform.goから始めて、planHasChangeRegexとparsePlanResultを調べます。次に、Terraformのplan出力の解析に関連するテストを探します。Actions: 1 to invoke.を含むサマリー行で失敗を再現し、この接尾辞がある場合とない場合の両方でサマリーが正常に解析されることを確認します。
索引モデルが issue の本文から書いたものです。
説明
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:
- 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]
}
}
}
- Run a TERRAFORM_PLAN stage, or call
provider.Terraform.Planon the directory. It fails withFailed 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:
pipedversion: pipedv1 at master (2080402c2)control-planeversion: 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.
- 主要言語
- Go
- スター
- 1.4k
- フォーク
- 403
- 平均マージ
- 2日 9時間
- マージ済み PR(30日)
- 40
環境構築
- Dockerfile・Docker Compose ファイルなし
- プルリクエストのテンプレートあり
- コントリビューションガイドを読む
はじめの一歩
- issue を最後まで読み、次にプロジェクトのコントリビューションガイドを読みます。
- 着手することを issue にコメントします — 二人が同じ作業をするのを防げます。
- リポジトリをフォークし、ブランチを切って変更します。
- issue 番号を参照したプルリクエストを送ります。
pipe-cd/pipecd のほかの issue
-
kind/bug
難易度 2/5 1〜3時間 初心者へのやさしさ 74/100
メンテナーはふだん 1 日以内に返信
-
Add a community meetings calendar to the website対応中かも @Dhirenderchoudhary が 8 日前に担当しました。 オープンarea/docs community good first issue
難易度 2/5 半日 初心者へのやさしさ 65/100
pipe-cd/pipecd#7648 · コメント 4 件 · 担当者 1 名 ·
メンテナーはふだん 1 日以内に返信
-
難易度 2/5 1〜3時間 初心者へのやさしさ 82/100
pipe-cd/pipecd#7643 · コメント 1 件 ·
メンテナーはふだん 1 日以内に返信
-
pipedv1: stopSignal handler panics on closed channel upon concurrent or duplicate signal calls再び着手できるかも @darshpatel1052 が 11 日前に担当しましたが、オープン中のプルリクエストはありません。 オープン
難易度 2/5 1〜3時間 初心者へのやさしさ 72/100
pipe-cd/pipecd#7642 · コメント 2 件 ·
メンテナーはふだん 1 日以内に返信
-
pipedv1: deployment remains stuck in PENDING when deploy source preparation fails in planner対応中かも @vikash7485 が 9 日前に担当しました。 オープン
難易度 2/5 1〜3時間 初心者へのやさしさ 80/100
pipe-cd/pipecd#7641 · コメント 1 件 ·
メンテナーはふだん 1 日以内に返信
似ている issue
-
hive
難易度 1/5 1時間未満 初心者へのやさしさ 82/100
メンテナーはふだん 1 日以内に返信
-
/v1/chat/completions logprobs leave out top_logprobs when none are requested対応中かも @Shizoqua が今日担当しました。 オープンbug
難易度 2/5 1〜3時間 初心者へのやさしさ 78/100
メンテナーはふだん 1 日以内に返信
-
service stage:spec
難易度 2/5 1〜3時間 初心者へのやさしさ 78/100
メンテナーはふだん 1 日以内に返信
-
難易度 2/5 1〜3時間 初心者へのやさしさ 74/100
メンテナーはふだん 1 日以内に返信
-
bug(terraform): a `kubernetes_manifest` the scan can't fully read is dropped and nothing says so対応中かも このイシューにリンクされたプルリクエストがオープン中、またはマージ済みです。 オープン
難易度 2/5 1〜3時間 初心者へのやさしさ 78/100
メンテナーはふだん 1 日以内に返信