Cannot create a baymodel in Mitaka

Bug #1604532 reported by Abhishek Chanda
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
Magnum
Fix Committed
Undecided
Abhishek Chanda

Bug Description

Trying to create a baymodel using the Mitaka branch. I get this error in API logs

Traceback (most recent call last):
  File "/usr/lib/python2.7/site-packages/wsmeext/pecan.py", line 84, in callfunction
    result = f(self, *args, **kwargs)
  File "<string>", line 2, in post
  File "/usr/lib/python2.7/site-packages/magnum/api/validation.py", line 96, in wrapper
    return func(*args, **kwargs)
  File "<string>", line 2, in post
  File "/usr/lib/python2.7/site-packages/magnum/api/validation.py", line 131, in wrapper
    return func(*args, **kwargs)
  File "/usr/lib/python2.7/site-packages/magnum/api/controllers/v1/baymodel.py", line 315, in post
    attr_validator.validate_os_resources(context, baymodel_dict)
  File "/usr/lib/python2.7/site-packages/magnum/api/attr_validator.py", line 91, in validate_os_resources
    validate_method(cli, baymodel[attr])
  File "/usr/lib/python2.7/site-packages/magnum/api/attr_validator.py", line 66, in validate_external_network
    networks = cli.neutron().list_networks()
  File "/usr/lib/python2.7/site-packages/magnum/common/exception.py", line 170, in wrapped
    return func(*args, **kw)
  File "/usr/lib/python2.7/site-packages/magnum/common/clients.py", line 254, in neutron
    region_name=region_name)
  File "/usr/lib/python2.7/site-packages/magnum/common/clients.py", line 135, in url_for
    return self.keystone().client.service_catalog.url_for(**kwargs)
  File "/usr/lib/python2.7/site-packages/magnum/common/keystone.py", line 78, in client
    self._client = self._get_ks_client()
  File "/usr/lib/python2.7/site-packages/magnum/common/keystone.py", line 143, in _get_ks_client
    return kc_v3.Client(**kwargs)
  File "/usr/lib/python2.7/site-packages/keystoneclient/v3/client.py", line 190, in __init__
    super(Client, self).__init__(**kwargs)
  File "/usr/lib/python2.7/site-packages/debtcollector/renames.py", line 45, in wrapper
    return f(*args, **kwargs)
  File "/usr/lib/python2.7/site-packages/debtcollector/renames.py", line 45, in wrapper
    return f(*args, **kwargs)
  File "/usr/lib/python2.7/site-packages/positional/__init__.py", line 94, in inner
    return func(*args, **kwargs)
  File "/usr/lib/python2.7/site-packages/keystoneclient/httpclient.py", line 299, in __init__
    self.auth_token_from_user = self.auth_ref.auth_token
  File "/usr/lib/python2.7/site-packages/keystoneclient/access.py", line 141, in auth_token
    return self['auth_token']
KeyError: 'auth_token'

This env has both keystone v2 and v3, Magnum is of course configured using the v3 endpoint. Versions

# rpm -qa | grep keystone
python-keystoneauth1-2.2.0-1.3.noarch
python-keystonemiddleware-4.0.0-3.1.noarch
openstack-keystone-9.0.2~a0~dev1-1.1.noarch
python-keystoneclient-2.3.1-1.1.noarch
python-keystone-9.0.2~a0~dev1-1.1.noarch

This patch fixes this https://review.openstack.org/#/c/333127/

Ton Ngo (ton-i)
Changed in magnum:
assignee: nobody → Abhishek Chanda (abhishek-i)
Wenzhi Yu (yuywz)
Changed in magnum:
status: New → In Progress
Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix merged to magnum (stable/mitaka)

Reviewed: https://review.openstack.org/333127
Committed: https://git.openstack.org/cgit/openstack/magnum/commit/?id=c41470da2165a3a019b4a6fc12cdc1af406fbe77
Submitter: Jenkins
Branch: stable/mitaka

commit c41470da2165a3a019b4a6fc12cdc1af406fbe77
Author: Abhishek Chanda <email address hidden>
Date: Wed Jun 22 23:29:39 2016 -0700

    Pass auth_token in auth_ref

    In our env, keystone was looking for auth_token inside auth_ref
    while trying to construct the client. This resulted in an exception.
    This patch fixed the problem.

    Closes-Bug: #1604532

    Change-Id: I101cf72f61dd824cb62f7f2b6d42ade6e7f3b1c3

tags: added: in-stable-mitaka
Changed in magnum:
status: In Progress → Fix Committed
Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix included in openstack/magnum 2.1.0

This issue was fixed in the openstack/magnum 2.1.0 release.

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.