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 upup/tools/generators/pkg/codegen staticcheck failures #8203

Merged
merged 1 commit into from
Dec 27, 2019

Conversation

johngmyers
Copy link
Member

Ref:#7800

upup/tools/generators/pkg/codegen/parse.go:40:2: field typeName is unused (U1000)
upup/tools/generators/pkg/codegen/parse.go:113:35: importer.For is deprecated: Use ForCompiler, which populates a FileSet with the positions of objects created by the importer.  (SA1019)

@k8s-ci-robot k8s-ci-robot added cncf-cla: yes Indicates the PR's author has signed the CNCF CLA. needs-ok-to-test Indicates a PR that requires an org member to verify it is safe to test. labels Dec 26, 2019
@k8s-ci-robot
Copy link
Contributor

Hi @johngmyers. Thanks for your PR.

I'm waiting for a kubernetes member to verify that this patch is reasonable to test. If it is, they should reply with /ok-to-test on its own line. Until that is done, I will not automatically test new commits in this PR, but the usual testing commands by org members will still work. Regular contributors should join the org to skip this step.

Once the patch is verified, the new status will be reflected by the ok-to-test label.

I understand the commands that are listed here.

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.

@k8s-ci-robot k8s-ci-robot added the size/XS Denotes a PR that changes 0-9 lines, ignoring generated files. label Dec 26, 2019
@tanjunchen
Copy link
Member

/ok-to-test

@k8s-ci-robot k8s-ci-robot added ok-to-test Indicates a non-member PR verified by an org member that is safe to test. and removed needs-ok-to-test Indicates a PR that requires an org member to verify it is safe to test. labels Dec 26, 2019
@tanjunchen
Copy link
Member

/lgtm
Thanks

@k8s-ci-robot k8s-ci-robot added the lgtm "Looks good to me", indicates that a PR is ready to be merged. label Dec 26, 2019
@tanjunchen
Copy link
Member

/cc @rifelpet

@johngmyers
Copy link
Member Author

/retest

@johngmyers
Copy link
Member Author

Is Prow running those jobs with Go 1.11? I believe our minimum requirement is Go 1.12.

@rifelpet
Copy link
Member

interesting, you're right.

https://github.com/kubernetes/test-infra/blob/c628c3674eb0c9292812d760232afcdbb7c79c99/config/jobs/kubernetes/kops/kops-config.yaml#L378

That repo has a tool that automatically bumps image tags as they get periodically rebuilt but it seems the image we're using hasn't been updated since January so there is probably a better image we should be using. I'll do some investigation.

rifelpet added a commit to rifelpet/test-infra that referenced this pull request Dec 26, 2019
The old image has not been updated in almost a year [0] and is still running Go 1.11:

```
docker run --entrypoint=/usr/local/go/bin/go gcr.io/k8s-testimages/gcloud-in-go:v20190125-cc5d6ecff3 version
go version go1.11.5 linux/amd64
```

We have open PRs [1] which are not compatible with go 1.11 which is causing their presubmits to fail.
This switches those jobs to use the same kubekins image as the E2E jobs.
I see other projects using the same kubekins-e2e image for non-e2e jobs as well [2].

The new image has Go 1.13 as we expect:

```
docker run --entrypoint=/usr/local/go/bin/go gcr.io/k8s-testimages/kubekins-e2e:v20191219-72db7a6-experimental version
go version go1.13.4 linux/amd64
```

[0] https://console.cloud.google.com/gcr/images/k8s-testimages/GLOBAL/gcloud-in-go?gcrImageListsize=30
[1] kubernetes/kops#8203
[2] https://github.com/kubernetes/test-infra/blob/c628c3674eb0c9292812d760232afcdbb7c79c99/config/jobs/kubernetes-sigs/cluster-api-provider-aws/cluster-api-provider-aws-presubmits.yaml#L23
rifelpet added a commit to rifelpet/test-infra that referenced this pull request Dec 26, 2019
The old image has not been updated in almost a year [0] and is still running Go 1.11:

```
docker run --entrypoint=/usr/local/go/bin/go gcr.io/k8s-testimages/gcloud-in-go:v20190125-cc5d6ecff3 version
go version go1.11.5 linux/amd64
```

We have open PRs [1] which are not compatible with go 1.11 which is causing their presubmits to fail.
This switches those jobs to use the same kubekins image as the E2E jobs.
I see other projects using the same kubekins-e2e image for non-e2e jobs as well [2].

The new image has Go 1.13 as we expect:

```
docker run --entrypoint=/usr/local/go/bin/go gcr.io/k8s-testimages/kubekins-e2e:v20191219-72db7a6-experimental version
go version go1.13.4 linux/amd64
```

[0] https://console.cloud.google.com/gcr/images/k8s-testimages/GLOBAL/gcloud-in-go?gcrImageListsize=30
[1] kubernetes/kops#8203
[2] https://github.com/kubernetes/test-infra/blob/c628c3674eb0c9292812d760232afcdbb7c79c99/config/jobs/kubernetes-sigs/cluster-api-provider-aws/cluster-api-provider-aws-presubmits.yaml#L23
@rifelpet
Copy link
Member

FWIW i ran the generator using both the master branch and this branch and the output was identical, so
/lgtm

hopefully kubernetes/test-infra#15691 will get merged soon

@rifelpet
Copy link
Member

/retest

@rifelpet
Copy link
Member

There we go!
/approve
/lgtm

@k8s-ci-robot
Copy link
Contributor

[APPROVALNOTIFIER] This PR is APPROVED

This pull-request has been approved by: johngmyers, rifelpet

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 Dec 27, 2019
@k8s-ci-robot k8s-ci-robot merged commit 0377b58 into kubernetes:master Dec 27, 2019
@johngmyers johngmyers deleted the codegen-staticcheck branch December 27, 2019 18:12
@k8s-ci-robot
Copy link
Contributor

@johngmyers: The following test failed, say /retest to rerun them all:

Test name Commit Details Rerun command
pull-kops-e2e-kubernetes-aws 3f35e26 link /test pull-kops-e2e-kubernetes-aws

Full PR test history. Your PR dashboard. Please help us cut down on flakes by linking to an open issue when you hit one in your PR.

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. I understand the commands that are listed here.

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. ok-to-test Indicates a non-member PR verified by an org member that is safe to test. 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

4 participants