Unclear how to handle error "Provider dependency changes detected"
- 主要言語
- Go
- スター
- 26
- フォーク
- 7
- 平均マージ
- 1日 1時間
- マージ済み PR(30日)
- 1
説明
### TL;DR
TF prints "Error: Provider dependency changes detected" and suggests running "terraform init" but it's not clear how to do that. Should I do it locally and send a PR with an updated lockfile? Or should Guardian do it and generate its own commit?
### Expected behavior
Get a normal plan. Alternatively, get actionable instructions on how to resolve the error.
### Observed behavior
I got this error:
```
Error: Provider dependency changes detected
Changes to the required provider dependencies were detected, but the lock
file is read-only. To use and record these requirements, run "terraform init"
without the "-lockfile=readonly" flag.
```
### Environment Details
```markdown
GUARDIAN_VERSION: 1.0.5
GUARDIAN_TERRAFORM_VERSION: 1.5.4
```
### Additional information
I was able to work around this by ensuring I had the same version of Terraform locally, then running `terraform init` which updated the lockfile, and adding that commit to my PR.
コントリビューションガイド
調査の方向性
Look at the Guardian project's Terraform configuration files, likely in the root or a terraform/ directory. The issue is about the provider lockfile (e.g., .terraform.lock.hcl). Run terraform init locally to update the lockfile and see what changes. The fix is to document whether contributors should update the lockfile in their PRs or if the CI system handles it.
索引モデルが issue の本文から書いたものです。
評価
- 技術スタック
- terraform
- 領域
- devops, infrastructure, tooling
- issue の種類
- ドキュメント
- 難易度
- 2/5
- 見積もり時間
- 1〜3時間
- 活発さ
- 停滞
- 明瞭さ
- 明確に書かれている
- 初心者へのやさしさ
- 65/100