Kuberenetes importing issue Python 3.6.8 on CentOS 7

10/10/2020

I have been banging my head on the wall trying to get the following import to work.

from kubernetes import config, client

I pip installed kubernetes==11.0.0

It works perfectly fine on https://repl.it/languages/python3 but getting import error on my CentOS 7 box.
from kubernetes import config, watch, client
ImportError: cannot import name 'config'

I have been using Python for 7-8 years, I am not sure what I am missing.

Thanks!

-- Paul McNuggets
kubernetes
python

1 Answer

10/10/2020

Found my issue, file name was kubernetes.py. Renamed it and solved issue :|.

-- Paul McNuggets
Source: StackOverflow