diff --git a/.github/renovate.json b/.github/renovate.json index 65083e8fa..efd17ea12 100644 --- a/.github/renovate.json +++ b/.github/renovate.json @@ -22,6 +22,26 @@ "gomodTidy", "gomodUpdateImportPaths" ], + "regexManagers": [ + { + "fileMatch": ["^Makefile$"], + "matchStrings": ["CONTROLLER_TOOLS_VERSION \\?= (?v[\\d.]+)"], + "depNameTemplate": "sigs.k8s.io/controller-tools", + "datasourceTemplate": "go" + }, + { + "fileMatch": ["^Makefile$"], + "matchStrings": ["GOLANGCI_LINT_VERSION \\?= (?v[\\d.]+)"], + "depNameTemplate": "github.com/golangci/golangci-lint/v2", + "datasourceTemplate": "go" + }, + { + "fileMatch": ["^Makefile$"], + "matchStrings": ["GOTESTSUM_VERSION \\?= (?v[\\d.]+)"], + "depNameTemplate": "gotest.tools/gotestsum", + "datasourceTemplate": "go" + } + ], "packageRules": [ { "matchPackageNames": [ diff --git a/internal/scheduling/reservations/commitments/api_change_commitments.go b/internal/scheduling/reservations/commitments/api_change_commitments.go index 5c2436267..8fc4c075f 100644 --- a/internal/scheduling/reservations/commitments/api_change_commitments.go +++ b/internal/scheduling/reservations/commitments/api_change_commitments.go @@ -294,9 +294,9 @@ ProcessLoop: // Build rejection reason from failed commitments if len(failedCommitments) > 0 { var reasonBuilder strings.Builder - reasonBuilder.WriteString(fmt.Sprintf("%d commitment(s) failed to apply: ", len(failedCommitments))) + fmt.Fprintf(&reasonBuilder, "%d commitment(s) failed to apply: ", len(failedCommitments)) for commitmentUUID, reason := range failedCommitments { - reasonBuilder.WriteString(fmt.Sprintf("\n- commitment %s: %s", commitmentUUID, reason)) + fmt.Fprintf(&reasonBuilder, "\n- commitment %s: %s", commitmentUUID, reason) } resp.RejectionReason = reasonBuilder.String() } diff --git a/internal/scheduling/reservations/commitments/state.go b/internal/scheduling/reservations/commitments/state.go index 61ca1ff10..1bfd47691 100644 --- a/internal/scheduling/reservations/commitments/state.go +++ b/internal/scheduling/reservations/commitments/state.go @@ -194,7 +194,7 @@ func FromChangeCommitmentTargetState( smallestFlavorMemoryBytes := int64(smallestFlavor.MemoryMB) * 1024 * 1024 //nolint:gosec // flavor memory from specs, realistically bounded // Amount represents multiples of the smallest flavor in the group - totalMemoryBytes := int64(amountMultiple) * smallestFlavorMemoryBytes //nolint:gosec // commitment amount from Limes API, bounded by quota limits + totalMemoryBytes := int64(amountMultiple) * smallestFlavorMemoryBytes //nolint:gosec // commitment amount from Limes API, realistically bounded return &CommitmentState{ CommitmentUUID: string(commitment.UUID), diff --git a/tools/logs/parser.go b/tools/logs/parser.go index 6540e78b3..2b32401d7 100644 --- a/tools/logs/parser.go +++ b/tools/logs/parser.go @@ -450,7 +450,7 @@ func formatWeightMapFullColorized(weights map[string]float64, indent int) string if i%4 == 0 { sb.WriteString(indentStr) } - sb.WriteString(fmt.Sprintf("%s: %.4f", colorizeHost(hw.host), hw.weight)) + fmt.Fprintf(&sb, "%s: %.4f", colorizeHost(hw.host), hw.weight) if i < len(sorted)-1 { sb.WriteString(", ") }