Open harukitake opened 4 days ago
Hi @harukitake 👋
Please use uppercase type "SCHEMA"
for now. We'll make the object types case insensitive.
Hi @sfc-gh-jmichalak .
It fails if I use uppercase type "SCHEMA"
.
It works well until v0.96.0, but after upgrading to v0.99.0 it has failed with the above error.
Could you provide provider logs with TF_LOG=DEBUG
?
```tf
2024-11-28T18:28:41.389+0900 [DEBUG] provider.terraform-provider-snowflake_v0.99.0: 2024/11/28 18:28:41 [DEBUG] sql-conn-query: [query SELECT CURRENT_ACCOUNT() as CURRENT_ACCOUNT err
I can't reproduce the issue for "SCHEMA"
. From your logs, it looks like "schema"
is still in the configuration.
@sfc-gh-jmichalak This state was created with v0.96.0. It might be the cause of the issue.
{
"version": 4,
"terraform_version": "1.7.5",
"serial": 3,
"lineage": "65303413-352e-8c89-d724-e86bb1ffc396",
"outputs": {},
"resources": [
{
"mode": "data",
"type": "terraform_remote_state",
"name": "vision_mindstone",
"provider": "provider[\"terraform.io/builtin/terraform\"]",
"instances": [
{
"schema_version": 0,
"attributes": {
"backend": "s3",
"config": {
"value": {
"bucket": "bucket",
"key": "/terraform.tfstate"
},
"type": [
"object",
{
"bucket": "string",
"key": "string"
}
]
},
"defaults": null,
"outputs": {
"value": {
"cost_tag_id": "VISION_MINDSTONE|TAG|OWNER"
},
"type": [
"object",
{
"cost_tag_id": "string"
}
]
},
"workspace": null
},
"sensitive_attributes": []
}
]
},
{
"mode": "managed",
"type": "snowflake_tag_association",
"name": "schema_fivetran_log",
"provider": "provider[\"registry.terraform.io/snowflake-labs/snowflake\"]",
"instances": [
{
"schema_version": 0,
"attributes": {
"id": "VISION_MINDSTONE|TAG|OWNER",
"object_identifier": [
{
"database": "RAW",
"name": "FIVETRAN_LOG",
"schema": ""
}
],
"object_name": null,
"object_type": "schema",
"skip_validation": true,
"tag_id": "VISION_MINDSTONE|TAG|OWNER",
"tag_value": "aaaaa",
"timeouts": null
},
"sensitive_attributes": [],
"dependencies": [
"data.terraform_remote_state.vision_mindstone"
]
}
]
},
{
"mode": "managed",
"type": "snowflake_tag_association",
"name": "schema_github_zucks",
"provider": "provider[\"registry.terraform.io/snowflake-labs/snowflake\"]",
"instances": [
{
"schema_version": 0,
"attributes": {
"id": "VISION_MINDSTONE|TAG|OWNER",
"object_identifier": [
{
"database": "RAW",
"name": "GITHUB_ZUCKS",
"schema": ""
}
],
"object_name": null,
"object_type": "schema",
"skip_validation": true,
"tag_id": "VISION_MINDSTONE|TAG|OWNER",
"tag_value": "@g_vision_developers",
"timeouts": null
},
"sensitive_attributes": [],
"dependencies": [
"data.terraform_remote_state.vision_mindstone"
]
}
]
}
],
"check_results": null
}
I will try the following step.
"schema"
-> "SCHEMA"
with v0.96.0 # snowflake_tag_association.schema_zucks_vision_sandbox_snowpipe must be replaced
-/+ resource "snowflake_tag_association" "schema_zucks_vision_sandbox_snowpipe" {
~ id = "VISION_MINDSTONE|TAG|OWNER" -> (known after apply)
~ object_type = "schema" -> "SCHEMA" # forces replacement
# (3 unchanged attributes hidden)
# (1 unchanged block hidden)
}
I fixed "schema"
-> "SCHEMA"
with v0.96.0 and upgraded to v0.99.0.
The plan was successful.
Terraform CLI Version
1.9.5
Terraform Provider Version
0.99.0
Company Name
No response
Terraform Configuration
Category
category:resource
Object type(s)
No response
Expected Behavior
successful plan and apply
Actual Behavior
Error: tagging for object type schema is not supported
Steps to Reproduce
How much impact is this issue causing?
High
Logs
No response
Additional Information
No response
Would you like to implement a fix?