Skip to content

Conversation

@arjunrn
Copy link
Contributor

@arjunrn arjunrn commented Jun 14, 2021

Depends on #598 and #597

This linter looks for common non-idiomatic patterns in code which can be simplified.

Result from linter:

pkg/cvo/sync_worker_test.go:88:5       gosimple  S1000: should use a simple channel send/receive instead of `select` with a single case
pkg/cvo/sync_worker_test.go:102:5      gosimple  S1000: should use a simple channel send/receive instead of `select` with a single case
pkg/cvo/sync_worker_test.go:141:4      gosimple  S1000: should use a simple channel send/receive instead of `select` with a single case
pkg/cvo/cvo_scenarios_test.go:418:12   gosimple  S1039: unnecessary use of fmt.Sprintf
pkg/cvo/cvo_scenarios_test.go:1081:12  gosimple  S1039: unnecessary use of fmt.Sprintf
pkg/cvo/cvo_scenarios_test.go:1332:12  gosimple  S1039: unnecessary use of fmt.Sprintf
pkg/cvo/sync_worker.go:1004:2          gosimple  S1011: should replace loop with `nested = append(nested, errs...)`

@openshift-ci openshift-ci bot added the do-not-merge/hold Indicates that a PR should not merge because someone has issued a /hold command. label Jun 14, 2021
@arjunrn arjunrn mentioned this pull request Jun 14, 2021
return nil
}

nested := make([]error, 0, len(errs))
Copy link
Contributor Author

Choose a reason for hiding this comment

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

This error slice was never used.

w.Report(tt.next)
close(w.w.report)
if tt.want {
select {
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 there is single channel to read from then a select-case to read is not required.

@arjunrn
Copy link
Contributor Author

arjunrn commented Jun 17, 2021

/hold cancel

@openshift-ci openshift-ci bot removed the do-not-merge/hold Indicates that a PR should not merge because someone has issued a /hold command. label Jun 17, 2021
@arjunrn
Copy link
Contributor Author

arjunrn commented Jun 18, 2021

/assign @LalatenduMohanty

@LalatenduMohanty
Copy link
Member

/override ci/prow/e2e-agnostic-upgrade

@openshift-ci
Copy link
Contributor

openshift-ci bot commented Jun 21, 2021

@LalatenduMohanty: Overrode contexts on behalf of LalatenduMohanty: ci/prow/e2e-agnostic-upgrade

Details

In response to this:

/override ci/prow/e2e-agnostic-upgrade

Instructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the kubernetes/test-infra repository.

@vrutkovs
Copy link

/retest

Copy link
Member

@LalatenduMohanty LalatenduMohanty left a comment

Choose a reason for hiding this comment

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

/lgtm

@openshift-ci openshift-ci bot added the lgtm Indicates that a PR is ready to be merged. label Jun 23, 2021
@openshift-ci
Copy link
Contributor

openshift-ci bot commented Jun 23, 2021

[APPROVALNOTIFIER] This PR is APPROVED

This pull-request has been approved by: arjunrn, LalatenduMohanty

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

The pull request process is described here

Details 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

@openshift-ci openshift-ci bot added the approved Indicates a PR has been approved by an approver from all required OWNERS files. label Jun 23, 2021
@LalatenduMohanty
Copy link
Member

/override ci/prow/e2e-agnostic-upgrade

@openshift-ci
Copy link
Contributor

openshift-ci bot commented Jun 23, 2021

@LalatenduMohanty: Overrode contexts on behalf of LalatenduMohanty: ci/prow/e2e-agnostic-upgrade

Details

In response to this:

/override ci/prow/e2e-agnostic-upgrade

Instructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the kubernetes/test-infra repository.

@openshift-merge-robot openshift-merge-robot merged commit 1cbdec5 into openshift:master Jun 23, 2021
@arjunrn arjunrn deleted the enable-gosimple branch June 23, 2021 07:11
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. lgtm Indicates that a PR is ready to be merged.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants