keystoneclient call to get users for tenant yields 500

Bug #932238 reported by Anthony Young
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
OpenStack Identity (keystone)
Fix Released
High
Dean Troyer

Bug Description

Steps to reproduce:

> keystone --debug --username admin --password secrete --tenant_name admin --auth-url http://127.0.0.1:5000/v2.0/ user-list admin

Expected:

List of users in the admin tenant

Actual:

keystone --debug --username admin --password secrete --tenant_name admin --auth-url http://127.0.0.1:5000/v2.0/ user-list admin
connect: (127.0.0.1, 5000)
send: 'POST /v2.0/tokens HTTP/1.1\r\nHost: 127.0.0.1:5000\r\nContent-Length: 102\r\ncontent-type: application/json\r\naccept-encoding: gzip, deflate\r\nuser-agent: python-keystoneclient\r\n\r\n{"auth": {"tenantName": "admin", "passwordCredentials": {"username": "admin", "password": "secrete"}}}'
reply: 'HTTP/1.1 200 OK\r\n'
header: Content-Type: application/json; charset=UTF-8
header: Content-Length: 1980
header: Date: Tue, 14 Feb 2012 18:28:25 GMT
connect: (192.168.2.10, 35357)
send: u'GET /v2.0/tenants/admin/users?fresh=1329244105.63 HTTP/1.1\r\nHost: 192.168.2.10:35357\r\nx-auth-token: d205b1cba9e940939559d7a9db9fe864\r\naccept-encoding: gzip, deflate\r\nuser-agent: python-keystoneclient\r\n\r\n'
reply: 'HTTP/1.1 500 Internal Server Error\r\n'
header: Content-Type: text/plain
header: Content-Length: 4095
header: Date: Tue, 14 Feb 2012 18:28:25 GMT
header: Connection: close
No handlers could be found for logger "keystoneclient.client"
Traceback (most recent call last):
  File "/usr/local/bin/keystone", line 9, in <module>
    load_entry_point('python-keystoneclient==2012.1', 'console_scripts', 'keystone')()
  File "/opt/stack/python-keystoneclient/keystoneclient/shell.py", line 237, in main
    OpenStackIdentityShell().main(sys.argv[1:])
  File "/opt/stack/python-keystoneclient/keystoneclient/shell.py", line 197, in main
    args.func(self.cs, args)
  File "/opt/stack/python-keystoneclient/keystoneclient/v2_0/shell.py", line 30, in do_user_list
    users = kc.users.list(tenant_id=args.tenant)
  File "/opt/stack/python-keystoneclient/keystoneclient/v2_0/users.py", line 120, in list
    "users")
  File "/opt/stack/python-keystoneclient/keystoneclient/base.py", line 65, in _list
    resp, body = self.api.get(url)
  File "/opt/stack/python-keystoneclient/keystoneclient/client.py", line 182, in get
    return self._cs_request(url, 'GET', **kwargs)
  File "/opt/stack/python-keystoneclient/keystoneclient/client.py", line 150, in _cs_request
    **kwargs)
  File "/opt/stack/python-keystoneclient/keystoneclient/client.py", line 130, in request
    raise exceptions.from_response(resp, body)
keystoneclient.exceptions.ClientException: Unable to communicate with identity service: Traceback (most recent call last):
  File "/usr/lib/python2.7/dist-packages/eventlet/wsgi.py", line 336, in handle_one_response
    result = self.application(self.environ, start_response)
  File "/usr/lib/python2.7/dist-packages/paste/urlmap.py", line 203, in __call__
    return app(environ, start_response)
  File "/usr/lib/python2.7/dist-packages/webob/dec.py", line 147, in __call__
    resp = self.call_func(req, *args, **self.kwargs)
  File "/usr/lib/python2.7/dist-packages/webob/dec.py", line 208, in call_func
    return self.func(req, *args, **kwargs)
  File "/opt/stack/keystone/keystone/common/wsgi.py", line 284, in __call__
    response = req.get_response(self.application)
  File "/usr/lib/python2.7/dist-packages/webob/request.py", line 1053, in get_response
    application, catch_exc_info=False)
  File "/usr/lib/python2.7/dist-packages/webob/request.py", line 1022, in call_application
    app_iter = application(self.environ, start_response)
  File "/usr/lib/python2.7/dist-packages/webob/dec.py", line 147, in __call__
    resp = self.call_func(req, *args, **self.kwargs)
  File "/usr/lib/python2.7/dist-packages/webob/dec.py", line 208, in call_func
    return self.func(req, *args, **kwargs)
  File "/opt/stack/keystone/keystone/common/wsgi.py", line 284, in __call__
    response = req.get_response(self.application)
  File "/usr/lib/python2.7/dist-packages/webob/request.py", line 1053, in get_response
    application, catch_exc_info=False)
  File "/usr/lib/python2.7/dist-packages/webob/request.py", line 1022, in call_application
    app_iter = application(self.environ, start_response)
  File "/usr/lib/python2.7/dist-packages/webob/dec.py", line 147, in __call__
    resp = self.call_func(req, *args, **self.kwargs)
  File "/usr/lib/python2.7/dist-packages/webob/dec.py", line 208, in call_func
    return self.func(req, *args, **kwargs)
  File "/opt/stack/keystone/keystone/common/wsgi.py", line 284, in __call__
    response = req.get_response(self.application)
  File "/usr/lib/python2.7/dist-packages/webob/request.py", line 1053, in get_response
    application, catch_exc_info=False)
  File "/usr/lib/python2.7/dist-packages/webob/request.py", line 1022, in call_application
    app_iter = application(self.environ, start_response)
  File "/usr/lib/python2.7/dist-packages/webob/dec.py", line 147, in __call__
    resp = self.call_func(req, *args, **self.kwargs)
  File "/usr/lib/python2.7/dist-packages/webob/dec.py", line 208, in call_func
    return self.func(req, *args, **kwargs)
  File "/opt/stack/keystone/keystone/common/wsgi.py", line 307, in __call__
    resp = req.get_response(self.application)
  File "/usr/lib/python2.7/dist-packages/webob/request.py", line 1053, in get_response
    application, catch_exc_info=False)
  File "/usr/lib/python2.7/dist-packages/webob/request.py", line 1022, in call_application
    app_iter = application(self.environ, start_response)
  File "/usr/lib/python2.7/dist-packages/webob/dec.py", line 159, in __call__
    return resp(environ, start_response)
  File "/usr/lib/pymodules/python2.7/routes/middleware.py", line 131, in __call__
    response = self.app(environ, start_response)
  File "/usr/lib/python2.7/dist-packages/webob/dec.py", line 159, in __call__
    return resp(environ, start_response)
  File "/usr/lib/python2.7/dist-packages/webob/dec.py", line 159, in __call__
    return resp(environ, start_response)
  File "/usr/lib/pymodules/python2.7/routes/middleware.py", line 131, in __call__
    response = self.app(environ, start_response)
  File "/usr/lib/python2.7/dist-packages/webob/dec.py", line 159, in __call__
    return resp(environ, start_response)
  File "/usr/lib/python2.7/dist-packages/webob/dec.py", line 147, in __call__
    resp = self.call_func(req, *args, **self.kwargs)
  File "/usr/lib/python2.7/dist-packages/webob/dec.py", line 208, in call_func
    return self.func(req, *args, **kwargs)
  File "/opt/stack/keystone/keystone/common/wsgi.py", line 173, in __call__
    method = getattr(self, action)
AttributeError: 'UserController' object has no attribute 'get_tenant_users'
. (HTTP 500)

Tags: redux
Joseph Heck (heckj)
Changed in keystone:
importance: Undecided → High
Joseph Heck (heckj)
Changed in keystone:
status: New → Confirmed
Dean Troyer (dtroyer)
Changed in keystone:
assignee: nobody → Dean Troyer (dtroyer)
status: Confirmed → In Progress
Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix proposed to keystone (master)

Fix proposed to branch: master
Review: https://review.openstack.org/4343

Revision history for this message
Dean Troyer (dtroyer) wrote :

the proposed branch was abandoned as this appears to have been fixed in https://review.openstack.org/4383

Changed in keystone:
status: In Progress → Fix Committed
Thierry Carrez (ttx)
Changed in keystone:
milestone: none → essex-4
status: Fix Committed → Fix Released
Thierry Carrez (ttx)
Changed in keystone:
milestone: essex-4 → 2012.1
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

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