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

chore: non-constant format string in call to fmt.Errorf #1579

Merged

Conversation

helen-frank
Copy link
Contributor

Fixes #N/A

Description
fix golangci-lint check error

❯ make verify
go mod tidy
go generate ./...
hack/validation/kubelet.sh
hack/validation/taint.sh
hack/validation/requirements.sh
hack/validation/labels.sh
hack/validation/resources.sh
hack/validation/status.sh
cp -r pkg/apis/crds kwok/charts
hack/kwok/requirements.sh
hack/kwok/conversion.sh
hack/dependabot.sh
hack/boilerplate.sh
go vet ./...
cd kwok/charts && helm-docs
INFO[2024-08-17T22:48:35+08:00] Found Chart directories [.]                  
INFO[2024-08-17T22:48:35+08:00] Generating README Documentation for chart .  
golangci-lint run
pkg/controllers/nodeclaim/consistency/controller.go:125:42: printf: non-constant format string in call to fmt.Errorf (govet)
                        log.FromContext(ctx).Error(fmt.Errorf(string(issue)), "consistency error")
                                                              ^
pkg/controllers/disruption/validation.go:166:40: printf: non-constant format string in call to fmt.Errorf (govet)
                return NewValidationError(fmt.Errorf(results.NonPendingPodSchedulingErrors()))
                                                     ^
make: *** [Makefile:113: verify] Error 1

How was this change tested?
make verify

By submitting this pull request, I confirm that my contribution is made under the terms of the Apache 2.0 license.

@k8s-ci-robot k8s-ci-robot added the cncf-cla: yes Indicates the PR's author has signed the CNCF CLA. label Aug 17, 2024
@k8s-ci-robot k8s-ci-robot added the size/XS Denotes a PR that changes 0-9 lines, ignoring generated files. label Aug 17, 2024
@coveralls
Copy link

Pull Request Test Coverage Report for Build 10433111364

Details

  • 1 of 2 (50.0%) changed or added relevant lines in 2 files are covered.
  • No unchanged relevant lines lost coverage.
  • Overall coverage increased (+0.06%) to 77.88%

Changes Missing Coverage Covered Lines Changed/Added Lines %
pkg/controllers/disruption/validation.go 0 1 0.0%
Totals Coverage Status
Change from base Build 10407510370: 0.06%
Covered Lines: 8925
Relevant Lines: 11460

💛 - Coveralls

Copy link
Member

@jonathan-innis jonathan-innis left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

/lgtm
/approve

@k8s-ci-robot k8s-ci-robot added the lgtm "Looks good to me", indicates that a PR is ready to be merged. label Aug 20, 2024
@jonathan-innis jonathan-innis changed the title cleanup: non-constant format string in call to fmt.Errorf chore: non-constant format string in call to fmt.Errorf Aug 20, 2024
@k8s-ci-robot
Copy link
Contributor

[APPROVALNOTIFIER] This PR is APPROVED

This pull-request has been approved by: helen-frank, jonathan-innis

The full list of commands accepted by this bot can be found here.

The pull request process is described here

Needs approval from an approver in each of these files:

Approvers can indicate their approval by writing /approve in a comment
Approvers can cancel approval by writing /approve cancel in a comment

@k8s-ci-robot k8s-ci-robot added the approved Indicates a PR has been approved by an approver from all required OWNERS files. label Aug 20, 2024
@k8s-ci-robot k8s-ci-robot merged commit 2941c7f into kubernetes-sigs:main Aug 20, 2024
11 checks passed
@helen-frank helen-frank deleted the cleanup/errorsNewString branch August 20, 2024 02:08
BEvgeniyS pushed a commit to BEvgeniyS/karpenter that referenced this pull request Sep 16, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
approved Indicates a PR has been approved by an approver from all required OWNERS files. cncf-cla: yes Indicates the PR's author has signed the CNCF CLA. lgtm "Looks good to me", indicates that a PR is ready to be merged. size/XS Denotes a PR that changes 0-9 lines, ignoring generated files.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants