← Back to team overview

yahoo-eng-team team mailing list archive

[Bug 1244034] Re: v2/os-migrations failed

 

*** This bug is a duplicate of bug 1260249 ***
    https://bugs.launchpad.net/bugs/1260249

** This bug is no longer a duplicate of bug 1236821
   migration-list can't return correct information
** This bug has been marked a duplicate of bug 1260249
   migration-list: 'unicode' object has no attribute 'iteritems'

-- 
You received this bug notification because you are a member of Yahoo!
Engineering Team, which is subscribed to OpenStack Compute (nova).
https://bugs.launchpad.net/bugs/1244034

Title:
  v2/os-migrations failed

Status in OpenStack Compute (Nova):
  New

Bug description:
  The code commit-id: 8f62dd1f054475c0644c83031b86c8e622253ddc

  $ nova --debug migration-list
  ...
  RESP: [200] CaseInsensitiveDict({'date': 'Thu, 24 Oct 2013 03:25:56 GMT', 'content-length': '31', 'content-type': 'application/json', 'x-compute-request-id': 'req-dacff374-8230-4be1-9ddc-1f6eb1a3ed3f'})
  RESP BODY: {"migrations": {"objects": []}}

  DEBUG (shell:724) 'unicode' object has no attribute 'iteritems'
  Traceback (most recent call last):
    File "/opt/stack/python-novaclient/novaclient/shell.py", line 721, in main
      OpenStackComputeShell().main(map(strutils.safe_decode, sys.argv[1:]))
    File "/opt/stack/python-novaclient/novaclient/shell.py", line 657, in main
      args.func(self.cs, args)
    File "/opt/stack/python-novaclient/novaclient/v1_1/contrib/migrations.py", line 71, in do_migration_list
      args.cell_name))
    File "/opt/stack/python-novaclient/novaclient/v1_1/contrib/migrations.py", line 53, in list
      return self._list("/os-migrations%s" % query_string, "migrations")
    File "/opt/stack/python-novaclient/novaclient/base.py", line 78, in _list
      for res in data if res]
    File "/opt/stack/python-novaclient/novaclient/base.py", line 420, in __init__
      self._add_details(info)
    File "/opt/stack/python-novaclient/novaclient/base.py", line 443, in _add_details
      for (k, v) in six.iteritems(info):
    File "/usr/local/lib/python2.7/dist-packages/six.py", line 439, in iteritems
      return iter(getattr(d, _iteritems)(**kw))
  AttributeError: 'unicode' object has no attribute 'iteritems'
  ERROR: 'unicode' object has no attribute 'iteritems'
  ...

  In  doc/api_samples/os-migrations/migrations-get.json, I found the correct response json should be like:
  {  "migration": [] }. Actually extra nest dict named 'objects' was injected into response body.

To manage notifications about this bug go to:
https://bugs.launchpad.net/nova/+bug/1244034/+subscriptions