-
Notifications
You must be signed in to change notification settings - Fork 55
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
Update dependency go modules for k8s v1.26.0 #123
Update dependency go modules for k8s v1.26.0 #123
Conversation
/release-note-none |
69992a9
to
45c7c68
Compare
The diffs are:
Seems like the type conversion in between changed from int to some doubles? |
Also noticed that the unit test is saying we should ignore the csi_sidecar_operations_seconds_sum metrics? |
/assign @Jiawei0227 Do you have any context on this? |
1.25.0 release is not broken, the breaking change started at 1.26.0: #124 |
45c7c68
to
348c028
Compare
I am not sure what the magic is but i copied the dependencies from the 1.25.0 pr and then ran go mod tidy/vendor etc. and now this pr is passing as well. |
/assign @xing-yang |
go.mod
Outdated
k8s.io/api v0.22.0 | ||
k8s.io/client-go v0.22.0 | ||
github.com/stretchr/testify v1.8.0 | ||
golang.org/x/net v0.3.1-0.20221206200815-1e63c2f08a10 |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Can you change this to v0.4.0? There's a CVE in earlier version.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Sure let me do that
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
You are going to update this to v0.4.0, right?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This one has been constantly downgraded again. Let me update.
k8s.io/component-base v0.22.0 | ||
k8s.io/klog/v2 v2.9.0 | ||
k8s.io/klog/v2 v2.80.1 |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
k8s.io/component-base v0.22.0?
Can this be updated to 0.26.0?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Update to 0.26.0 break the unit tests as we see above.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I see. Can you add a comment about this in the PR description?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I think we should update the component-base and fix the tests. I'm not sure if there will be any side effects if the sidecars and the library use two different versions of component-base: https://github.com/kubernetes-csi/external-provisioner/blob/master/go.mod#L24
go.mod
Outdated
@@ -1,23 +1,62 @@ | |||
module github.com/kubernetes-csi/csi-lib-utils | |||
|
|||
go 1.16 | |||
go 1.19 | |||
|
|||
require ( | |||
github.com/container-storage-interface/spec v1.5.0 |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Can you update this to 1.7.0?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Why 1.17? k8s 1.26.0 is at 1.19
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
github.com/container-storage-interface/spec v1.5.0 -> v1.7.0 which is the latest CSI spec release. This is not K8s release. Also not go version.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
this comment is about github.com/container-storage-interface/spec
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Then I need to fix the previous 1.25.0 first
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
But the go version for github.com/container-storage-interface is 1.18? https://github.com/container-storage-interface/spec/blob/release-1.7/go.mod
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This should be fine. It's not possible for all dependency libs to use the exact same go version.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I see this is still github.com/container-storage-interface/spec v1.5.0
. Is there any issue updating to github.com/container-storage-interface/spec v1.7.0
?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Oh sorry I somehow was thinking you want me to update the go version to 1.17.0, changing it now. And i am still trying to fix the component base.
2515761
to
4d068b7
Compare
go.mod
Outdated
@@ -1,34 +1,33 @@ | |||
module github.com/kubernetes-csi/csi-lib-utils | |||
|
|||
go 1.18 | |||
go 1.17 |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This should still be updated to go 1.19
.
4d068b7
to
5f590ee
Compare
go.mod
Outdated
@@ -1,34 +1,33 @@ | |||
module github.com/kubernetes-csi/csi-lib-utils | |||
|
|||
go 1.18 | |||
go 1.19 |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Please keep it at 1.18. 1.19 would indicate that the code in this repo needs 1.19, which isn't the case.
5f590ee
to
d827e9d
Compare
The error has changed from this line after upgraded to component-base 0.26.0
This results in the want split does not have the expected string to compare on this line The want string is:
We need to change the split rule to something without the ":":
This also ends up in certain situations the want string contains one line extra, so we need to remove that line so we can scan later:
|
/lgtm |
[APPROVALNOTIFIER] This PR is APPROVED This pull-request has been approved by: msau42, sunnylovestiramisu 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 |
Ran kubernetes-csi/csi-release-tools go-get-kubernetes.sh -p 1.26.0