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

Error switching context with no cached connection #3032

Open
driv opened this issue Dec 14, 2024 · 0 comments · May be fixed by #3033
Open

Error switching context with no cached connection #3032

driv opened this issue Dec 14, 2024 · 0 comments · May be fixed by #3033

Comments

@driv
Copy link

driv commented Dec 14, 2024




Describe the bug
There is some issue with switching context (or retrying) after a failed connection.

10:38AM ERR Fail to load global/context configuration error="the server could not find the requested resource\ncannot connect to context: not_working_context\nk8s connection failed for context: not_working_context"
10:38AM ERR Load cluster resources - No API server connection
10:38AM ERR failed to list contexts error="no connection"
10:38AM WRN Unable to dial discovery API error="no connection to dial"
10:38AM ERR can't connect to cluster error="the server could not find the requested resource"
10:38AM ERR Load cluster resources - No API server connection
10:38AM WRN Unable to dial discovery API error="no connection to dial"
10:38AM ERR Context switch failed error="no connection to cached dial"
10:38AM ERR no connection to cached dial
10:39AM ERR Context switch failed error="no connection to cached dial"
10:39AM ERR no connection to cached dial
10:39AM ERR Context switch failed error="no connection to cached dial"
10:39AM ERR no connection to cached dial
In that case I retried to connect to the working context 3 times.

To Reproduce
Steps to reproduce the behavior:

k9s --context not_working_context

Try to quickly switch to any other context and the error no connection to cached dial will appear.
After the default timeout (15s) it's possible to switch context.

Historical Documents
When applicable please include any supporting artifacts: k9s debug logs, configurations, resource manifests, ...

Expected behavior
A clear and concise description of what you expected to happen.

Screenshots
If applicable, add screenshots to help explain your problem.

Versions (please complete the following information):

  • OS: N/A
  • K9s: v0.32.7
  • K8s: N/A

Additional context
Add any other context about the problem here.

driv added a commit to driv/k9s that referenced this issue Dec 14, 2024
Fixes derailed#3032

It should not fail to invalidate the cache when there is not cached
connection.
@driv driv linked a pull request Dec 14, 2024 that will close this issue
driv added a commit to driv/k9s that referenced this issue Dec 14, 2024
Fixes derailed#3032

It should not fail to invalidate the cache when there is not cached
connection.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging a pull request may close this issue.

1 participant