← Back to team overview

yahoo-eng-team team mailing list archive

[Bug 1702100] Re: Error when renaming a network

 

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

** This bug has been marked a duplicate of bug 1650097
   update network which has subnets is "failed"

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

Title:
  Error when renaming a network

Status in OpenStack Dashboard (Horizon):
  New

Bug description:
  The error is on stable/newton.

  On stable/newton on the /project/networks/ page, when trying to rename
  a network we get both a success message (in green) and an error
  message (in red) saying "Danger: There was an error submitting the
  form. Please try again.".

  The logs show:

  Internal Server Error: /project/networks/e529df34-bf03-4775-be70-5f377c856334/update
  Traceback (most recent call last):
    File "/home/yves/openstack/pure_horizon/horizon/.venv/local/lib/python2.7/site-packages/django/core/handlers/base.py", line 132, in get_response
      response = wrapped_callback(request, *callback_args, **callback_kwargs)
    File "/home/yves/openstack/pure_horizon/horizon/horizon/decorators.py", line 36, in dec
      return view_func(request, *args, **kwargs)
    File "/home/yves/openstack/pure_horizon/horizon/horizon/decorators.py", line 52, in dec
      return view_func(request, *args, **kwargs)
    File "/home/yves/openstack/pure_horizon/horizon/horizon/decorators.py", line 36, in dec
      return view_func(request, *args, **kwargs)
    File "/home/yves/openstack/pure_horizon/horizon/horizon/decorators.py", line 84, in dec
      return view_func(request, *args, **kwargs)
    File "/home/yves/openstack/pure_horizon/horizon/.venv/local/lib/python2.7/site-packages/django/views/generic/base.py", line 71, in view
      return self.dispatch(request, *args, **kwargs)
    File "/home/yves/openstack/pure_horizon/horizon/.venv/local/lib/python2.7/site-packages/django/views/generic/base.py", line 89, in dispatch
      return handler(request, *args, **kwargs)
    File "/home/yves/openstack/pure_horizon/horizon/.venv/local/lib/python2.7/site-packages/django/views/generic/edit.py", line 215, in post
      return self.form_valid(form)
    File "/home/yves/openstack/pure_horizon/horizon/horizon/forms/views.py", line 195, in form_valid
      obj_dict = handled.to_dict()
    File "/home/yves/openstack/pure_horizon/horizon/openstack_dashboard/api/neutron.py", line 102, in to_dict
      d['subnets'] = [s.to_dict() for s in d['subnets']]
  AttributeError: 'unicode' object has no attribute 'to_dict'

  And we do not see the name change.
  When we simply refresh the /project/networks/ we see the name was changed with success.

  When debugging with ipdb, /api/neutron.py", line 101, in
  Network.to_dict we can see that after `d =
  dict(super(NeutronAPIDictWrapper, self).to_dict())`, `d['subnets']` is
  a list of strings so `d['subnets'] = [s.to_dict() for s in
  d['subnets']]` can only fail.

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


References