{
  "id": "terraform/s3-backend-bucket-not-found",
  "signature": "Error: Failed to load state: S3 bucket \"my-terraform-state\" does not exist",
  "signature_zh": "错误：加载状态失败：S3 存储桶 \"my-terraform-state\" 不存在",
  "regex": "Failed to load state.*S3 bucket.*does not exist",
  "domain": "terraform",
  "category": "resource_error",
  "subcategory": null,
  "root_cause": "The S3 bucket specified in the backend configuration for state storage has not been created or has been deleted.",
  "root_cause_type": "generic",
  "root_cause_zh": "后端配置中指定的用于状态存储的S3存储桶尚未创建或已被删除。",
  "versions": [
    {
      "version": "Terraform v1.5.0",
      "introduced": null,
      "deprecated": null,
      "removed": null,
      "behavior_change": null,
      "status": "active"
    },
    {
      "version": "Terraform v1.6.0",
      "introduced": null,
      "deprecated": null,
      "removed": null,
      "behavior_change": null,
      "status": "active"
    },
    {
      "version": "Terraform v1.7.0",
      "introduced": null,
      "deprecated": null,
      "removed": null,
      "behavior_change": null,
      "status": "active"
    }
  ],
  "os_specific": {},
  "dead_ends": [
    {
      "action": "Run 'terraform init' with -migrate-state flag",
      "why_fails": "The bucket still doesn't exist; migrate requires an existing bucket.",
      "fail_rate": 0.95,
      "condition": "",
      "sources": []
    },
    {
      "action": "Change the bucket name in the backend block to a random new name",
      "why_fails": "The new bucket also doesn't exist unless created manually.",
      "fail_rate": 0.8,
      "condition": "",
      "sources": []
    },
    {
      "action": "Use local backend by removing the backend block",
      "why_fails": "This changes the state location and may lose remote state history.",
      "fail_rate": 0.7,
      "condition": "",
      "sources": []
    }
  ],
  "workarounds": [
    {
      "action": "Create the S3 bucket manually with the correct name and region: `aws s3api create-bucket --bucket my-terraform-state --region us-east-1 --create-bucket-configuration LocationConstraint=us-east-1`",
      "success_rate": 0.95,
      "how": "Create the S3 bucket manually with the correct name and region: `aws s3api create-bucket --bucket my-terraform-state --region us-east-1 --create-bucket-configuration LocationConstraint=us-east-1`",
      "condition": "",
      "sources": []
    },
    {
      "action": "Update the backend configuration to point to an existing bucket, then run 'terraform init -reconfigure'",
      "success_rate": 0.9,
      "how": "Update the backend configuration to point to an existing bucket, then run 'terraform init -reconfigure'",
      "condition": "",
      "sources": []
    }
  ],
  "workarounds_zh": [
    "Create the S3 bucket manually with the correct name and region: `aws s3api create-bucket --bucket my-terraform-state --region us-east-1 --create-bucket-configuration LocationConstraint=us-east-1`",
    "Update the backend configuration to point to an existing bucket, then run 'terraform init -reconfigure'"
  ],
  "transition_graph": {
    "leads_to": [],
    "preceded_by": [],
    "frequently_confused_with": []
  },
  "official_doc_url": "https://developer.hashicorp.com/terraform/language/settings/backends/s3",
  "official_doc_section": null,
  "error_code": null,
  "verification_tier": "ai_generated",
  "confidence": 0.87,
  "fix_success_rate": 0.9,
  "resolvable": "true",
  "first_seen": "2024-03-10",
  "last_confirmed": "2024-06-01",
  "last_updated": "2024-06-01",
  "evidence_count": 1,
  "tags": [],
  "locale": "en",
  "aliases": []
}