{"record":{"id":"1d0e864c796a6f32","repo":"hashicorp/terraform","slug":"operation-timed-out","errorCode":null,"errorMessage":"operation timed out","messagePattern":"operation timed out","errorType":"console","errorClass":null,"httpStatus":null,"severity":"error","filePath":"internal/backend/remote/backend_plan.go","lineNumber":292,"sourceCode":"\t\tcase <-cancelCtx.Done():\n\t\t\tlog.Printf(\"[TRACE] backend/remote: operation cancelled while waiting for configuration status\")\n\t\t\treturn nil, context.Canceled\n\t\tcase <-time.After(planConfigurationVersionsPollInterval):\n\t\t\tlog.Printf(\"[TRACE] backend/remote: reading configuration status\")\n\t\t\tcv, err = b.client.ConfigurationVersions.Read(stopCtx, cv.ID)\n\t\t\tif err != nil {\n\t\t\t\treturn nil, generalError(\"Failed to retrieve configuration version\", err)\n\t\t\t}\n\n\t\t\tif cv.Status == tfe.ConfigurationUploaded {\n\t\t\t\tuploaded = true\n\t\t\t}\n\t\t}\n\t}\n\n\tif !uploaded {\n\t\treturn nil, generalError(\n\t\t\t\"Failed to upload configuration files\", errors.New(\"operation timed out\"))\n\t}\n\n\tlog.Printf(\"[TRACE] backend/remote: configuration uploaded and ready\")\n\trunOptions := tfe.RunCreateOptions{\n\t\tConfigurationVersion: cv,\n\t\tRefresh:              tfe.Bool(op.PlanRefresh),\n\t\tWorkspace:            w,\n\t}\n\n\tswitch op.PlanMode {\n\tcase plans.NormalMode:\n\t\t// okay, but we don't need to do anything special for this\n\tcase plans.RefreshOnlyMode:\n\t\trunOptions.RefreshOnly = tfe.Bool(true)\n\tcase plans.DestroyMode:\n\t\trunOptions.IsDestroy = tfe.Bool(true)\n\tdefault:\n\t\t// Shouldn't get here because we should update this for each new","sourceCodeStart":274,"sourceCodeEnd":310,"githubUrl":"https://github.com/hashicorp/terraform/blob/d32a084675427f5ac3f7d2868578ef8b2c1dc525/internal/backend/remote/backend_plan.go#L274-L310","documentation":"Returned by the remote backend plan path (backend_plan.go:292) when the uploaded configuration version never reaches tfe.ConfigurationUploaded status within the polling loop. The backend uploads the config then polls ConfigurationVersions.Read; if uploaded is still false after all iterations, it wraps a plain 'operation timed out' error in generalError with the message 'Failed to upload configuration files'. The cause is usually TFE never acknowledging the upload (network, large config, slow/overloaded server), not an explicit wall-clock timeout.","triggerScenarios":"Running terraform plan with the 'remote' backend against a TFE/HCP server where the configuration-version upload completes the HTTP request but the server fails to flip the CV to ConfigurationUploaded within the poll window (the upload-then-poll loop in backend_plan.go).","commonSituations":"Very large config bundles that take longer than the poll budget to ingest. TFE sidecar/worker backpressure or outages. Network proxies that complete the upload but drop the status-read. A stale upload URL or an interrupted connection between upload and status read.","solutions":["Retry terraform plan — transient server/network issues are the most common cause.","Check the TFE/HCP workspace UI for the configuration version status and any ingest errors.","Reduce config size or use .terraformignore to skip large vendored files, then retry.","Verify connectivity and proxies between your runner and the TFE hostname."],"exampleFix":null,"handlingStrategy":"retry","validationCode":null,"typeGuard":null,"tryCatchPattern":"cv, err := b.uploadConfig(...)\nif err != nil {\n    if strings.Contains(err.Error(), \"operation timed out\") {\n        // TFE did not acknowledge the upload in time; retry with backoff\n        return retryUpload()\n    }\n    return err\n}","preventionTips":["Keep the config bundle small via .terraformignore.","Verify TFE/HCP health and network connectivity before planning.","Retry plan after transient ingest failures."],"tags":["terraform","remote-backend","tfe","configuration-upload","network","timeout","plan"],"backgroundTag":null,"analyzedSha":"d32a084675427f5ac3f7d2868578ef8b2c1dc525","analyzedAt":"2026-08-11T18:43:52.779Z","contentChangedAt":null,"schemaVersion":2},"datasetVersion":"2026-09-23T08:17:48.524Z"}