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

Remove direct dependency on k8s.io/kubernetes #907

Merged
merged 1 commit into from
Sep 13, 2023

Conversation

xing-yang
Copy link
Collaborator

@xing-yang xing-yang commented Sep 13, 2023

What type of PR is this?
/kind cleanup

What this PR does / why we need it:
This PR removes direct dependency on kubernetes which is not recommended.
Copied https://github.com/kubernetes/kubernetes/blob/v1.29.0-alpha.0/pkg/apis/admission/fuzzer/fuzzer.go to external-snapshotter so that we can get rid of the direct dependency on k8s.io/kubernetes.

Which issue(s) this PR fixes:
Fixes #

Special notes for your reviewer:
Getting the following errors when generating release notes:

INFO Setting up repository github.com/kubernetes-csi/external-snapshotter  file="modiff/modiff.go:59"
INFO Retrieving modules of fcb21dc5b138e87e8dc16ed49d5215d896d1ceea  file="modiff/modiff.go:230"
INFO Retrieving modules of bb29899ca37369fe7c3bc3c861d3186b50e2fc65  file="modiff/modiff.go:230"
ERRO unable to run cmd: go list -mod=readonly -m all, workdir: /tmp/go-modiff331102065, stdout: , stderr: go: k8s.io/[email protected]: invalid version: unknown revision v0.0.0
, error: exit status 1  file="modiff/modiff.go:251"
FATA generating dependency report: getting dependency changes: unable to run cmd: go list -mod=readonly -m all, workdir: /tmp/go-modiff331102065, stdout: , stderr: go: k8s.io/[email protected]: invalid version: unknown revision v0.0.0
, error: exit status 1  file="release-notes/main.go:390"

According to the following issue, depending on kubernetes directly will cause this problem.
kubernetes/kubernetes#79384

Does this PR introduce a user-facing change?:

NONE

@k8s-ci-robot k8s-ci-robot added release-note-none Denotes a PR that doesn't merit a release note. kind/cleanup Categorizes issue or PR as related to cleaning up code, process, or technical debt. cncf-cla: yes Indicates the PR's author has signed the CNCF CLA. approved Indicates a PR has been approved by an approver from all required OWNERS files. labels Sep 13, 2023
@k8s-ci-robot k8s-ci-robot added the size/XS Denotes a PR that changes 0-9 lines, ignoring generated files. label Sep 13, 2023
@xing-yang xing-yang closed this Sep 13, 2023
@xing-yang xing-yang changed the title Remove direct dependency on kubernetes WIP: Remove direct dependency on kubernetes Sep 13, 2023
@k8s-ci-robot k8s-ci-robot added the do-not-merge/work-in-progress Indicates that a PR should not merge because it is a work in progress. label Sep 13, 2023
@xing-yang xing-yang reopened this Sep 13, 2023
@k8s-ci-robot k8s-ci-robot added size/L Denotes a PR that changes 100-499 lines, ignoring generated files. and removed size/XS Denotes a PR that changes 0-9 lines, ignoring generated files. labels Sep 13, 2023
@xing-yang xing-yang changed the title WIP: Remove direct dependency on kubernetes Remove direct dependency on kubernetes Sep 13, 2023
@k8s-ci-robot k8s-ci-robot removed the do-not-merge/work-in-progress Indicates that a PR should not merge because it is a work in progress. label Sep 13, 2023
@xing-yang xing-yang changed the title Remove direct dependency on kubernetes Remove direct dependency on k8s.io/kubernetes Sep 13, 2023
@xing-yang
Copy link
Collaborator Author

/assign @msau42

@msau42
Copy link
Collaborator

msau42 commented Sep 13, 2023

/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 Sep 13, 2023
@k8s-ci-robot
Copy link
Contributor

[APPROVALNOTIFIER] This PR is APPROVED

This pull-request has been approved by: msau42, xing-yang

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 merged commit f7cc9e3 into kubernetes-csi:master Sep 13, 2023
2 checks passed
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. 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. release-note-none Denotes a PR that doesn't merit a release note. size/L Denotes a PR that changes 100-499 lines, ignoring generated files.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants