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

Fix golint failures pkg/kubelet/util/cache #73990

Merged
merged 1 commit into from
Feb 15, 2019

Conversation

xichengliudui
Copy link
Contributor

@xichengliudui xichengliudui commented Feb 13, 2019

What type of PR is this?
/kind cleanup

What this PR does / why we need it:
Fix golint failures

Which issue(s) this PR fixes:

Ref #68026

Special notes for your reviewer:

Does this PR introduce a user-facing change?:

NONE

update pull request

update pull request
@k8s-ci-robot k8s-ci-robot added release-note-none Denotes a PR that doesn't merit a release note. size/XS Denotes a PR that changes 0-9 lines, ignoring generated files. needs-kind Indicates a PR lacks a `kind/foo` label and requires one. needs-sig Indicates an issue or PR lacks a `sig/foo` label and requires one. needs-priority Indicates a PR lacks a `priority/foo` label and requires one. cncf-cla: yes Indicates the PR's author has signed the CNCF CLA. labels Feb 13, 2019
@k8s-ci-robot k8s-ci-robot added area/kubelet sig/node Categorizes an issue or PR as relevant to SIG Node. and removed needs-sig Indicates an issue or PR lacks a `sig/foo` label and requires one. labels Feb 13, 2019
@xichengliudui
Copy link
Contributor Author

/assign @SataQiu @vishh

@xichengliudui
Copy link
Contributor Author

/retest

1 similar comment
@xichengliudui
Copy link
Contributor Author

/retest

@xichengliudui
Copy link
Contributor Author

@vishh I think it is wrong to modify in this way. May I ask how can I modify?

@xichengliudui
Copy link
Contributor Author

/assign @BenTheElder

@xichengliudui xichengliudui changed the title Fix golint failures Fix golint failures pkg/kubelet/util/cache Feb 13, 2019
@xichengliudui
Copy link
Contributor Author

/retest

1 similar comment
@xichengliudui
Copy link
Contributor Author

/retest

@@ -46,7 +46,7 @@ func TestAddAndGet(t *testing.T) {
val: "bar",
}
objectCache := NewFakeObjectCache(func() (interface{}, error) {
return nil, fmt.Errorf("Unexpected Error: updater should never be called in this test!")
return nil, fmt.Errorf("Unexpected Error: updater should never be called in this test! ")
Copy link
Member

Choose a reason for hiding this comment

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

This doesn't seem right.

Copy link
Contributor Author

Choose a reason for hiding this comment

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

golint has not found any error in running, please tell me what is wrong and I will fix it!

Copy link
Member

Choose a reason for hiding this comment

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

why did we put a space here?

Copy link
Contributor Author

Choose a reason for hiding this comment

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

if no space are added, run golint detection: pkg/kubelet/util/cache/object_cache_test.go:49:26: error strings should not be capitalized or end with punctuation or a newline

Copy link
Contributor Author

Choose a reason for hiding this comment

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

you can also choose to delete ! or do you have a better idea?

Copy link
Member

Choose a reason for hiding this comment

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

removing the "!" seems better than skirting the lint by adding a space to the end :^)

Copy link
Contributor Author

Choose a reason for hiding this comment

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

I agree with!

@xichengliudui
Copy link
Contributor Author

/retest

1 similar comment
@xichengliudui
Copy link
Contributor Author

/retest

@xichengliudui
Copy link
Contributor Author

/retest

1 similar comment
@xichengliudui
Copy link
Contributor Author

/retest

@xichengliudui
Copy link
Contributor Author

/skip

@BenTheElder
Copy link
Member

/kind cleanup
/sig node

@k8s-ci-robot k8s-ci-robot added kind/cleanup Categorizes issue or PR as related to cleaning up code, process, or technical debt. and removed needs-kind Indicates a PR lacks a `kind/foo` label and requires one. labels Feb 14, 2019
@BenTheElder
Copy link
Member

/assign @yujuhong

@yujuhong
Copy link
Contributor

/approve

@BenTheElder
Copy link
Member

/assign @fejta

Copy link
Contributor

@fejta fejta 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 Feb 15, 2019
@fejta
Copy link
Contributor

fejta commented Feb 15, 2019

/retest

@k8s-ci-robot
Copy link
Contributor

[APPROVALNOTIFIER] This PR is APPROVED

This pull-request has been approved by: fejta, xichengliudui, yujuhong

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 Feb 15, 2019
@xichengliudui
Copy link
Contributor Author

/retest

@k8s-ci-robot k8s-ci-robot merged commit bf20886 into kubernetes:master Feb 15, 2019
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. area/kubelet cncf-cla: yes Indicates the PR's author has signed the CNCF CLA. kind/cleanup Categorizes issue or PR as related to cleaning up code, process, or technical debt. lgtm "Looks good to me", indicates that a PR is ready to be merged. needs-priority Indicates a PR lacks a `priority/foo` label and requires one. release-note-none Denotes a PR that doesn't merit a release note. sig/node Categorizes an issue or PR as relevant to SIG Node. 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.

None yet

5 participants