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

cannot modify kube context using kubectl to change the default namespace in the context #116

Open
kishoregv opened this issue Oct 5, 2020 · 6 comments
Labels
kind/bug Something isn't working priority/awaiting-more-information This is the lowest priority. More information is needed to think about working on it. priority/important Should be worked on soon. Higher priority than backlog
Milestone

Comments

@kishoregv
Copy link

Describe the solution you'd like:
When running kubectl/kubens command to change the default namespace to something else an error is thrown.

kubectl config set-context --namespace kube-public --current 
error: converting  to : type names don't match (Unknown, RawExtension), and no conversion 'func (runtime.Unknown, runtime.RawExtension) error' registered.

kubens kube-public
error: converting  to : type names don't match (Unknown, RawExtension), and no conversion 'func (runtime.Unknown, runtime.RawExtension) error' registered.
error getting current namespace

Why do you want this feature:
It will be convenient to skip namespace flag to every kubectl command by allowing to modify the default namespace in the current kube context

@kishoregv kishoregv added the kind/feature A new feature request label Oct 5, 2020
@rajarajanpsj rajarajanpsj added kind/bug Something isn't working priority/important Should be worked on soon. Higher priority than backlog and removed kind/feature A new feature request labels Oct 5, 2020
@richardcase
Copy link
Contributor

Thanks for raising this @kishoregv .

What version of kubectl are you using?

@richardcase richardcase added the priority/awaiting-more-information This is the lowest priority. More information is needed to think about working on it. label Oct 5, 2020
@richardcase richardcase self-assigned this Oct 5, 2020
@richardcase
Copy link
Contributor

richardcase commented Oct 5, 2020

I am able to run kubectl config set-context --namespace kube-public --current without getting the error. I will try kubens

@kishoregv
Copy link
Author

kubectl version

k version --short
Client Version: v1.16.0

@richardcase
Copy link
Contributor

@kishoregv - i have done some testing and this is an issue with clients prior to v1.17.0. If you use kubectl (or anything that relies on client-go) from 1.17.0 onwards this will work.

@richardcase
Copy link
Contributor

@kishoregv @rajarajanpsj - do you think we should do a version check within kconnect? Perhaps we could have a kconnect doctor or somethign similar that checks things like that?

@richardcase richardcase added this to Backlog in kconnect planning via automation Nov 3, 2020
@richardcase richardcase added this to the Future milestone Nov 3, 2020
@richardcase
Copy link
Contributor

This should be handled by #222 and #223

@richardcase richardcase removed their assignment Jan 6, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
kind/bug Something isn't working priority/awaiting-more-information This is the lowest priority. More information is needed to think about working on it. priority/important Should be worked on soon. Higher priority than backlog
Projects
kconnect planning
  
Backlog
Development

No branches or pull requests

3 participants