Skip to content
New issue

Have a question about this project? # for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “#”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? # to your account

bug: Interdependence between plugins? #1127

Open
kronn opened this issue Dec 14, 2021 · 3 comments
Open

bug: Interdependence between plugins? #1127

kronn opened this issue Dec 14, 2021 · 3 comments
Labels

Comments

@kronn
Copy link

kronn commented Dec 14, 2021

Describe the Bug

> kubectl
No preset version installed for command kubectl
Please install a version by running one of the following:

asdf install oc 3.11.117

or add one of the following versions in your config file at /PATH/TO/REPO/.tool-versions
oc 4.8.0

> asdf install oc 3.11.117
oc 3.11.117 is already installed

Steps to Reproduce

I noticed that the calling kubectl (directly or indirectly through kubectx) broke after I installed oc 4.8.0. Uninstalling oc 4.8 fixes the issue.

I am however quite un-confident that this is the trigger. kubectl does not have any versions installed through asdf. There is only one version of it in the path that is too old (but needed) to be installable through asdf-kubectl.

Expected Behaviour

Plugins without installed version should not break things

Actual Behaviour

see above "Describe the bug"

Environment

OS:
Linux $USER-$COMPANY 5.8.0-63-generic #71~20.04.1-Ubuntu SMP Thu Jul 15 17:46:08 UTC 2021 x86_64 x86_64 x86_64 GNU/Linux

SHELL:
GNU bash, version 5.0.17(1)-release (x86_64-pc-linux-gnu)
Copyright (C) 2019 Free Software Foundation, Inc.
License GPLv3+: GNU GPL version 3 or later <http://gnu.org/licenses/gpl.html>

This is free software; you are free to change and redistribute it.
There is NO WARRANTY, to the extent permitted by law.

ASDF VERSION:
v0.8.1-a1ef92a

ASDF ENVIRONMENT VARIABLES:
ASDF_DIR=$HOME/.asdf

ASDF INSTALLED PLUGINS:
elixir                       https://github.com/asdf-vm/asdf-elixir.git
erlang                       https://github.com/asdf-vm/asdf-erlang.git
golang                       https://github.com/kennyp/asdf-golang.git
kubectl                      https://github.com/Banno/asdf-kubectl.git
kubectx                      https://gitlab.com/wt0f/asdf-kubectx.git
kubeval                      https://github.com/stefansedich/asdf-kubeval.git
kustomize                    https://github.com/Banno/asdf-kustomize.git
nodejs                       https://github.com/asdf-vm/asdf-nodejs.git
oc                           https://github.com/sqtran/asdf-oc.git
ruby                         https://github.com/asdf-vm/asdf-ruby.git
yarn                         https://github.com/twuni/asdf-yarn.git

asdf plugins affected (if relevant)

kubectl, kubectx, oc

OR maybe none of the above.

@kronn kronn added the bug label Dec 14, 2021
@jthegedus
Copy link
Contributor

Related to #804 & #196

@kronn
Copy link
Author

kronn commented Dec 16, 2021

Interesting, I wasn't aware that the order matters (though it does make sense and is certainly preferable to full-blown dependency-mangement...).

I will try to change the order in my global .tool-versions and see if the error persists.

@kronn
Copy link
Author

kronn commented Dec 20, 2021

Well, I have stopped using the kubectl-plugin which removes all the shim-magic and therefore my problem. Turns out that I currently only need one version of kubectl, which I can "manage" by putting it into my PATH.

I could not resolve the problem by ordering the entries in the .tool-versions, but this may be my error, as I did not spent a lot of time to test thoroughly. A quick test did not resolve it and I realised I do not have any version of kubectl aside from my system-version installed.

Should this ticket stay here open as a reminder?

# for free to join this conversation on GitHub. Already have an account? # to comment
Labels
Projects
None yet
Development

No branches or pull requests

2 participants