AttributeError: 'Namespace' object has no attribute 'os_domain_id' (part 2)

Bug #1734945 reported by Eric Harney
30
This bug affects 6 people
Affects Status Importance Assigned to Milestone
python-cinderclient
Fix Released
High
Zhao Chao

Bug Description

It's bug 1695054 again.

Seems to be introduced by "ce1013d Fix OS_AUTH_TYPE env var usage".

The same workaround there of unsetting OS_AUTH_TYPE will work around this issue.

[python-cinderclient] $ git rev-parse HEAD
40cb90d12c1bdf20cbf081569c6a94aead0b9f39

$ source ~/devstack/openrc
WARNING: setting legacy OS_TENANT_NAME to support cli tools.

$ cinder --debug list
DEBUG (shell:973) 'Namespace' object has no attribute 'os_domain_id'
Traceback (most recent call last):
  File "/opt/stack/python-cinderclient/cinderclient/shell.py", line 968, in main
    for item in sys.argv[1:]])
  File "/opt/stack/python-cinderclient/cinderclient/shell.py", line 645, in main
    self.options)
  File "/usr/lib/python2.7/site-packages/keystoneauth1/loading/cli.py", line 102, in load_from_argparse_arguments
    return plugin.load_from_options_getter(_getter, **kwargs)
  File "/usr/lib/python2.7/site-packages/keystoneauth1/loading/base.py", line 182, in load_from_options_getter
    val = getter(opt)
  File "/usr/lib/python2.7/site-packages/keystoneauth1/loading/cli.py", line 100, in _getter
    return getattr(namespace, 'os_%s' % opt.dest)
AttributeError: 'Namespace' object has no attribute 'os_domain_id'
DEBUG:cinderclient.shell:'Namespace' object has no attribute 'os_domain_id'
Traceback (most recent call last):
  File "/opt/stack/python-cinderclient/cinderclient/shell.py", line 968, in main
    for item in sys.argv[1:]])
  File "/opt/stack/python-cinderclient/cinderclient/shell.py", line 645, in main
    self.options)
  File "/usr/lib/python2.7/site-packages/keystoneauth1/loading/cli.py", line 102, in load_from_argparse_arguments
    return plugin.load_from_options_getter(_getter, **kwargs)
  File "/usr/lib/python2.7/site-packages/keystoneauth1/loading/base.py", line 182, in load_from_options_getter
    val = getter(opt)
  File "/usr/lib/python2.7/site-packages/keystoneauth1/loading/cli.py", line 100, in _getter
    return getattr(namespace, 'os_%s' % opt.dest)
AttributeError: 'Namespace' object has no attribute 'os_domain_id'
ERROR: 'Namespace' object has no attribute 'os_domain_id'

$ git revert ce1013d
[master f456b08] Revert "Fix OS_AUTH_TYPE env var usage"
 2 files changed, 2 insertions(+), 24 deletions(-)

$ cinder list
+----+--------+------+------+-------------+----------+-------------+
| ID | Status | Name | Size | Volume Type | Bootable | Attached to |
+----+--------+------+------+-------------+----------+-------------+
+----+--------+------+------+-------------+----------+-------------+

Revision history for this message
Eric Harney (eharney) wrote :

Setting importance to High since this is basically an immediate failure for someone using devstack.

Changed in python-cinderclient:
importance: Undecided → High
Changed in python-cinderclient:
status: New → Confirmed
Changed in python-cinderclient:
assignee: nobody → Abijitha Nadagouda (abijithanadagouda)
Changed in python-cinderclient:
assignee: Abijitha Nadagouda (abijithanadagouda) → Zhao Chao (zhaochao1984)
status: Confirmed → In Progress
Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix merged to python-cinderclient (master)

Reviewed: https://review.openstack.org/532217
Committed: https://git.openstack.org/cgit/openstack/python-cinderclient/commit/?id=77143d43dc50c9609651d227c7571fcd57565ef8
Submitter: Zuul
Branch: master

commit 77143d43dc50c9609651d227c7571fcd57565ef8
Author: Zhao Chao <email address hidden>
Date: Tue Jan 9 15:43:11 2018 +0800

    Migrate to keystoneauth identity cli opts.

    Use keystoneauth1 to parse keystone authentication arguments. Previously
    these arguments are parsed in the different service clients seperately.
    Use keystoneauth1 instead will make this consistent across projects and
    less error-prone.

    This change is inspired by NovaClient.

    Co-Authored-By: Morgan Fainberg <email address hidden>
    Co-Authored-By: David Hu <email address hidden>
    Co-Authored-By: Monty Taylor <email address hidden>

    Closes-Bug: #1734945

    Change-Id: I3c5141eeddd3747ff542e95b04e4848470ad9508
    Signed-off-by: Zhao Chao <email address hidden>

Changed in python-cinderclient:
status: In Progress → Fix Released
Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix included in openstack/python-cinderclient 3.5.0

This issue was fixed in the openstack/python-cinderclient 3.5.0 release.

To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Duplicates of this bug

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.