The novaclient Python API doc keystoneauth example fixed
The novaclient Python API document's keystoneauth session example is not working. AttributeError: 'Password' object has no attribute 'Password' is fixed with this patch Change-Id: I0c06279eed936619a770e84207bb02e79f42f6a7 Closes-Bug: #1552206
This commit is contained in:
@@ -26,10 +26,10 @@ session API::
|
||||
>>> from keystoneauth1 import session
|
||||
>>> from novaclient import client
|
||||
>>> loader = loading.get_plugin_loader('password')
|
||||
>>> auth = loader.Password(auth_url=AUTH_URL,
|
||||
... username=USERNAME,
|
||||
... password=PASSWORD,
|
||||
... project_id=PROJECT_ID)
|
||||
>>> auth = loader.load_from_options(auth_url=AUTH_URL,
|
||||
... username=USERNAME,
|
||||
... password=PASSWORD,
|
||||
... project_id=PROJECT_ID)
|
||||
>>> sess = session.Session(auth=auth)
|
||||
>>> nova = client.Client(VERSION, session=sess)
|
||||
|
||||
|
||||
Reference in New Issue
Block a user