Problem
Cost estimation fails with the error “Something on our end went wrong. We’ve been notified. Please try again later.”
Cause
This error can have several causes, including expired cloud provider credentials or a panic caused by a runtime error within the cost estimation engine.
Solution
To identify the specific cause of the failure, you can retrieve the detailed error message by using the Runs API endpoint with the cost_estimate include parameter.
Procedure
- Identify the Run ID of the failed run from the HCP Terraform or Terraform Enterprise UI.
- Prepare the API request. Replace
$TFEHOSTNAME,$RUNID, and$TOKENwith your organization's hostname, the Run ID from step 1, and a valid user or team API token. For HCP Terraform, the hostname isapp.terraform.io. -
Execute the following
curlcommand to query the API endpoint.$ curl \ --header "Authorization: Bearer $TOKEN" \ "https://$TFEHOSTNAME/api/v2/runs/$RUNID?include=cost_estimate"
-
Review the JSON response and locate the
includedsection. Theerror-messageattribute within thecost-estimatesobject contains the detailed error.Example error output:
{ "included": [ { "id": "ce-cGoqimyNs2Y8rczy", "type": "cost-estimates", "attributes": { "error-message": "panic: didn't find any prices for PremiumContainer Plan | PC2 in EU West\n\ngoroutine 19 [running]:\ngithub.com/hashicorp/cost-estimation/internal/pkg/azure.(*ASPlan).Price(...)\n##...", "status": "errored", "status-timestamps": { "queued-at": "...", "errored-at": "..." } } } ] } - Use the detailed error message to resolve the underlying issue, such as updating expired provider credentials.
Additional Information
If the error message indicates a panic, this may be a product bug. Please save the run detail output to provide when reporting the issue through official HashiCorp channels.