question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

`ApiextensionsV1beta1Api()` not part of kubernetes 3.0.0

See original GitHub issue

I am trying to test CRD and I re-installed the kubernetes module, version3.0.0 . Using ipyton 2.7

)$ sudo pip install --upgrade kubernetes
The directory '/Users/sebgoa/Library/Caches/pip/http' or its parent directory is not owned by the current user and the cache has been disabled. Please check the permissions and owner of that directory. If executing pip with sudo, you may want sudo's -H flag.
The directory '/Users/sebgoa/Library/Caches/pip' or its parent directory is not owned by the current user and caching wheels has been disabled. check the permissions and owner of that directory. If executing pip with sudo, you may want sudo's -H flag.
Collecting kubernetes
  Downloading kubernetes-3.0.0-py2.py3-none-any.whl (815kB)
    100% |████████████████████████████████| 819kB 1.0MB/s 
Requirement already up-to-date: setuptools>=21.0.0 in /opt/local/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/site-packages (from kubernetes)
Requirement already up-to-date: requests in /opt/local/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/site-packages (from kubernetes)
Requirement already up-to-date: urllib3!=1.21,>=1.19.1 in /opt/local/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/site-packages (from kubernetes)
Requirement already up-to-date: google-auth>=1.0.1 in /opt/local/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/site-packages (from kubernetes)
Requirement already up-to-date: certifi>=14.05.14 in /opt/local/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/site-packages (from kubernetes)
Requirement already up-to-date: pyyaml>=3.12 in /opt/local/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/site-packages (from kubernetes)
Requirement already up-to-date: python-dateutil>=2.5.3 in /opt/local/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/site-packages (from kubernetes)
Requirement already up-to-date: websocket-client<=0.40.0,>=0.32.0 in /opt/local/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/site-packages (from kubernetes)
Requirement already up-to-date: six>=1.9.0 in /opt/local/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/site-packages (from kubernetes)
Requirement already up-to-date: ipaddress>=1.0.17 in /opt/local/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/site-packages (from kubernetes)
Requirement already up-to-date: idna<2.7,>=2.5 in /opt/local/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/site-packages (from requests->kubernetes)
Requirement already up-to-date: chardet<3.1.0,>=3.0.2 in /opt/local/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/site-packages (from requests->kubernetes)
Requirement already up-to-date: cachetools>=2.0.0 in /opt/local/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/site-packages (from google-auth>=1.0.1->kubernetes)
Requirement already up-to-date: pyasn1-modules>=0.0.5 in /opt/local/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/site-packages (from google-auth>=1.0.1->kubernetes)
Requirement already up-to-date: pyasn1>=0.1.7 in /opt/local/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/site-packages (from google-auth>=1.0.1->kubernetes)
Requirement already up-to-date: rsa>=3.1.4 in /opt/local/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/site-packages (from google-auth>=1.0.1->kubernetes)
Requirement already up-to-date: backports.ssl_match_hostname in /opt/local/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/site-packages (from websocket-client<=0.40.0,>=0.32.0->kubernetes)
Installing collected packages: kubernetes
Successfully installed kubernetes-3.0.0
sebimac:kkcd (master)$ ipython ./testcrd.py 
default
kube-public
kube-system
---------------------------------------------------------------------------
AttributeError                            Traceback (most recent call last)
/Users/sebgoa/Desktop/kkcd/testcrd.py in <module>()
      8      print ns.metadata.name
      9 
---> 10 crd = client.ApiextensionsV1beta1Api()
     11 

AttributeError: 'module' object has no attribute 'ApiextensionsV1beta1Api'

Issue Analytics

  • State:closed
  • Created 6 years ago
  • Comments:15 (8 by maintainers)

github_iconTop GitHub Comments

1reaction
mildebrandtcommented, Dec 12, 2017

Since we have 4.0.0 out of alpha, I agree we can “forget the past” as it were. I do have another bug with the 4.0.0 client and the 1.8.0 server concerning this same API which I’ll open shortly. Thanks for your help.

1reaction
mildebrandtcommented, Nov 7, 2017

You can install 4.0.0a1 via pip using this command:

pip install kubernetes==4.0.0a1 --upgrade

That’ll give you support for CRD. I agree it should be supported in 3.0.0, this is just a work around so you can continue with development.

Read more comments on GitHub >

github_iconTop Results From Across the Web

python/CHANGELOG.md at master · kubernetes-client/python
Official Python client library for kubernetes. Contribute to kubernetes-client/python development by creating an account on GitHub.
Read more >
Running Spark on Kubernetes - Spark 3.0.0-preview ...
A running Kubernetes cluster at version >= 1.6 with access configured to it using kubectl. If you do not already have a working...
Read more >
Index (client-java-api 1.0.0-beta1 API) - Javadoc.io
DeploymentCondition describes the state of a deployment at a certain point. AppsV1beta1DeploymentCondition() - Constructor for class io.kubernetes.client.models ...
Read more >
Well-Known Labels, Annotations and Taints - Kubernetes
A unique name identifying the instance of an application. To assign a non-unique name, use app.kubernetes.io/name. One of the recommended ...
Read more >
Ignite the Spark!. Running Apache Spark on Kubernetes…
Apache Mesos; Hadoop YARN. The Standalone cluster manager is the default one and is shipped with every version of Spark. It is a...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found