Skip to content
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

snowflake_current_account not able to fetch the account url correctly in account spanning multiple regions #2067

Open
mhmcdonald opened this issue Sep 22, 2023 · 0 comments
Labels
bug Used to mark issues with provider's incorrect behavior category:data_source data_source:current_account Issue connected to the snowflake_current_account data source

Comments

@mhmcdonald
Copy link
Contributor

mhmcdonald commented Sep 22, 2023

Provider Version
0.68.2

Terraform Version
1.2.5

Describe the bug
If you're in an account that spans multiple regions, the data source snowflake_current_account is not able to fetch the account's url correctly. The reason for this is related to this AccountURL() function.

When you're in an account in an organization that spans multiple region groups, and you call current_region(), the value returned is prefixed with PUBLIC.. It's documented here. However, in the current implementation of the data source is not expecting the PUBLIC. string prefix.

Expected behavior
Regardless of the account you're in, using the snowflake_current_account data source should return a valid URL for the account, and should not raise this error.

Code samples and commands

Please add code examples and commands that were run to cause the problem.

data "snowflake_current_account" "this" {
}

resource "resource_name" "thing" {
     url  = data.snowflake_current_account.this.url
}

Add any other context about the problem here.

@mhmcdonald mhmcdonald added the bug Used to mark issues with provider's incorrect behavior label Sep 22, 2023
@sfc-gh-jcieslak sfc-gh-jcieslak added category:data_source data_source:current_account Issue connected to the snowflake_current_account data source labels May 20, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Used to mark issues with provider's incorrect behavior category:data_source data_source:current_account Issue connected to the snowflake_current_account data source
Projects
None yet
Development

No branches or pull requests

2 participants