-
Notifications
You must be signed in to change notification settings - Fork 4.7k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Error parsing azurerm_cosmosdb_account resource id #24811
Comments
Works with 3.88. In 3.89 there was an enhancement I don't see any cosmosdb changes in the release notes for 3.90.1, so assuming the issue is still there in that version. |
FYI, not working for me with version 3.88 either.
|
hey @ajaffie @leowaisblatt @bramvdklinkenberg Taking a look through here it appears that the CosmosDB Account was imported previously using a Resource ID which differs from the casing we’re expecting for a CosmosDB Account, which is why this parsing is failing. Unfortunately there’s not enough information in the issue to confirm that for sure (it could also be coming from an associated resource, we'd need debug logs/a terraform configuration to confirm otherwise) - but you should be able to validate this using Once that’s confirmed, you should be able to use As per the documentation for this resource and the error message being returned here, the expected Resource ID for a CosmosDB Account is:
However since there isn’t a repro for this in the description for this issue, or any debug logs attached - unfortunately that’s all we’ve got to go on here - and as such this appears to be an issue with the Resource that’s been imported previously. As updating the Resource ID for the Resource will resolve that issue - I believe this’ll resolve that and so I’m going to close this issue for the moment - but if this doesn’t resolve this for you then if you can attach some debug logs, a Terraform Configuration and the output from Thanks! |
@tombuildsstuff your suggestion of removing the resource from the state and importing it back did work well. Thanks a lot! |
I'm going to lock this issue because it has been closed for 30 days ⏳. This helps our maintainers find and focus on the active issues. |
Is there an existing issue for this?
Community Note
Terraform Version
1.6
AzureRM Provider Version
3.90
Affected Resource(s)/Data Source(s)
azurerm_cosmosdb_account
Terraform Configuration Files
# Anything with a azurerm_cosmosdb_account
Debug Output/Panic Output
Expected Behaviour
It should not have trouble parsing the resource id.
Actual Behaviour
It could not parse the resource id.
Steps to Reproduce
No response
Important Factoids
It is not an issue on 3.85, I haven't tested any versions in between.
References
No response
The text was updated successfully, but these errors were encountered: