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

Bug: Changing the API and regenerating client-go does not add changes to code repo. #219

Closed
kannon92 opened this issue Jun 30, 2023 · 4 comments · Fixed by #221
Closed
Assignees
Labels
kind/bug Categorizes issue or PR as related to a bug.

Comments

@kannon92
Copy link
Contributor

When I modify the api and try to generate client-go, my client-go is generated and placed in my go src directory (ie /home/ec2-user/go/1.20.2/src/sigs.k8s.io/jobset/client-go/).

I think that it should go to client-go folder in the repo. Currently if I modify the API I would have to copy /home/ec2-user/go/1.20.2/src/sigs.k8s.io/jobset/client-go/ and rewrite the folder in client-go.

This is not ideal.

Any ideas on what is going wrong?

@kannon92
Copy link
Contributor Author

/kind bug

@k8s-ci-robot k8s-ci-robot added the kind/bug Categorizes issue or PR as related to a bug. label Jun 30, 2023
@danielvegamyhre
Copy link
Contributor

/assign

@danielvegamyhre
Copy link
Contributor

When originally developing this I found that generate-groups.sh script called by update-codegen.sh accepts an "output package" parameter, which I specified as sigs.k8s.io/jobset/client-go, and treats each thing between the / chars as a directory relative to $GOROOT/src. So in my case this writes to ~/go/src/sigs.k8s.io/jobset/client-go, and since my jobset repo is located at ~/go/src/sigs.k8s.io/jobset, this is the correct location.

However, I can reproduce this issue by cloning jobset in my /tmp directory and running make, it still writes the client-go to the same location relative to my Go root, not relative to my current working directory. I don't see an obvious way to change this in the script, as it only seems to accept an "output package" parameter, not a filesystem location of to create output files relative to.

I think maybe at the end of the script we just need to move the output client-go directory to the location relative to the current working directory.

@kannon92
Copy link
Contributor Author

kannon92 commented Jul 1, 2023

I think copying is fine. Ideally I’d like to get the this running in a container so I think we would copy the build out of co Rainer anyway.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
kind/bug Categorizes issue or PR as related to a bug.
Projects
None yet
Development

Successfully merging a pull request may close this issue.

3 participants