-
-
Notifications
You must be signed in to change notification settings - Fork 398
Description
What Happened
We bumped the version of staticcheck (v0.4.0) in Kubernetes to incorporate go1.20 related changes. PR: kubernetes/kubernetes#115537
We are also using go1.20 on master (ref: kubernetes/kubernetes#114502)
Due to improvements to linters, a few things were flagged, out of which one of the flagged instances seems to be a false positive.
Here are the failure logs from the failed run: https://prow.k8s.io/view/gs/kubernetes-jenkins/pr-logs/pull/115537/pull-kubernetes-verify/1622491177255178240
Here is part of the code that was flagged:
Before adding the comments to exclude the warnings, from the logs:
test/integration/apiserver/discovery/discovery_test.go:55:6: type `kubeClientSet` is unused (unused)
[1015](https://prow.k8s.io/view/gs/kubernetes-jenkins/pr-logs/pull/115537/pull-kubernetes-verify/1622491177255178240#1:build-log.txt%3A1015)
type kubeClientSet = kubernetes.Interface
[1016](https://prow.k8s.io/view/gs/kubernetes-jenkins/pr-logs/pull/115537/pull-kubernetes-verify/1622491177255178240#1:build-log.txt%3A1016)
^
Considering that the type aliases are in fact used, is this warning valid or is it a false positive? Please note that this warning did not surface on a version before v0.4.0.