Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion .go-version
Original file line number Diff line number Diff line change
@@ -1 +1 @@
1.23
1.24
2 changes: 1 addition & 1 deletion go.mod
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
module github.com/hashicorp/terraform-provider-google-beta

go 1.23.0
go 1.24.0

require (
cloud.google.com/go/auth v0.16.5
Expand Down
2 changes: 1 addition & 1 deletion google-beta/acctest/diff_utils.go
Original file line number Diff line number Diff line change
Expand Up @@ -213,7 +213,7 @@ func writeOutputFileDeferFunction(tempOutputFile *os.File, failed bool) {
fmt.Fprintf(os.Stdout, "%s Breaking Change Detected] \n", diffTag)
fmt.Fprintf(diffFailureFile, "%s %s\n", diffTag, testOutput)
} else {
fmt.Fprintf(regularFailureFile, testOutput)
fmt.Fprintf(regularFailureFile, "%s", testOutput)
fmt.Fprintf(regularFailureFile, "FAILED --- %s\n", testOutput)
}
}
Expand Down
2 changes: 1 addition & 1 deletion google-beta/services/container/container_operation.go
Original file line number Diff line number Diff line change
Expand Up @@ -60,7 +60,7 @@ func (w *ContainerOperationWaiter) Error() error {
}

if w.Op.StatusMessage != "" {
return fmt.Errorf(w.Op.StatusMessage)
return fmt.Errorf("%s", w.Op.StatusMessage)
}

return nil
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -561,7 +561,7 @@ func testAccCheckDataprocJobAttrMatch(n, jobType string, job *dataproc.Job) reso

for _, attrs := range jobTests {
if c := checkMatch(attributes, attrs.tf_attr, attrs.gcp_attr); c != "" {
return fmt.Errorf(c)
return fmt.Errorf("%s", c)
}
}

Expand Down
2 changes: 1 addition & 1 deletion google-beta/services/kms/kms_utils.go
Original file line number Diff line number Diff line change
Expand Up @@ -128,7 +128,7 @@ type kmsCryptoKeyVersionId struct {
}

func (s *kmsCryptoKeyVersionId) cryptoKeyVersionId() string {
return fmt.Sprintf(s.Name)
return s.Name
}

func (s *kmsCryptoKeyVersionId) TerraformId() string {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -72,7 +72,7 @@ func TestAccDataSourceGoogleServiceAccounts_basic(t *testing.T) {
resource.TestCheckResourceAttr("data.google_service_accounts.with_regex", "accounts.0.email", fmt.Sprintf("%s@%s.iam.gserviceaccount.com", sa_1, project)),

// Check if the account_id matches the prefix
resource.TestCheckResourceAttr("data.google_service_accounts.with_prefix_and_regex", "accounts.0.account_id", fmt.Sprintf(sa_1)),
resource.TestCheckResourceAttr("data.google_service_accounts.with_prefix_and_regex", "accounts.0.account_id", sa_1),

// Check if the email matches the regex
resource.TestCheckResourceAttr("data.google_service_accounts.with_prefix_and_regex", "accounts.0.email", fmt.Sprintf("%s@%s.iam.gserviceaccount.com", sa_1, project)),
Expand Down Expand Up @@ -118,17 +118,19 @@ data "google_service_accounts" "with_prefix" {

data "google_service_accounts" "with_regex" {
project = local.project_id
regex = ".*${google_service_account.sa_one.account_id}.*@.*\\.gserviceaccount\\.com"
regex = ".*%s.*@.*\\.gserviceaccount\\.com"
}

data "google_service_accounts" "with_prefix_and_regex" {
prefix = google_service_account.sa_one.account_id
project = local.project_id
regex = ".*${google_service_account.sa_one.account_id}.*@.*\\.gserviceaccount\\.com"
regex = ".*%s.*@.*\\.gserviceaccount\\.com"
}
`,
context["project"].(string),
context["sa_1"].(string),
context["sa_2"].(string),
context["sa_1"].(string),
context["sa_1"].(string),
)
}
2 changes: 1 addition & 1 deletion google-beta/services/storage/storage_operation.go
Original file line number Diff line number Diff line change
Expand Up @@ -50,7 +50,7 @@ func (w *StorageOperationWaiter) QueryOp() (interface{}, error) {
}

// Returns the proper get.
url := fmt.Sprintf(w.SelfLink)
url := w.SelfLink

return transport_tpg.SendRequest(transport_tpg.SendRequestOptions{
Config: w.Config,
Expand Down
2 changes: 1 addition & 1 deletion google-beta/sweeper/hashi_sweeper_fork.go
Original file line number Diff line number Diff line change
Expand Up @@ -483,7 +483,7 @@ func validateParentSweepers(sweepers map[string]*Sweeper) error {
// If any validation errors were found, return them
if len(validationErrors) > 0 {
if len(validationErrors) == 1 {
return fmt.Errorf(validationErrors[0])
return fmt.Errorf("%s", validationErrors[0])
}
return fmt.Errorf("multiple parent validation issues: %s", strings.Join(validationErrors, "; "))
}
Expand Down
2 changes: 1 addition & 1 deletion google-beta/transport/batcher_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -169,7 +169,7 @@ func TestRequestBatcher_errInSend(t *testing.T) {
log.Printf("[DEBUG] sendBatch body: %+v", body)
for _, v := range body.([]int) {
if v == failIdx {
return nil, fmt.Errorf(expectedErrMsg)
return nil, fmt.Errorf("%s", expectedErrMsg)
}
}
return nil, nil
Expand Down
2 changes: 1 addition & 1 deletion google-beta/transport/retry_transport_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -307,7 +307,7 @@ func testRetryTransport_checkBody(t *testing.T, resp *http.Response, expectedMsg

expectedBody := fmt.Sprintf("Request Body: %s", expectedMsg)
if !strings.HasSuffix(string(actualBody), expectedBody) {
t.Fatalf(expectedBody)
t.Fatalf("%s", expectedBody)
}
}

Expand Down
2 changes: 1 addition & 1 deletion scripts/go.mod
Original file line number Diff line number Diff line change
@@ -1,3 +1,3 @@
module github.com/hashicorp/terraform-provider-google-beta/scripts

go 1.23
go 1.24
Loading