yahoo-eng-team team mailing list archive
-
yahoo-eng-team team
-
Mailing list archive
-
Message #02777
[Bug 1175414] Re: Circular reference serializing InstanceTypeNotFound
** Changed in: nova
Status: Fix Committed => Fix Released
** Changed in: nova
Milestone: None => havana-1
--
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/1175414
Title:
Circular reference serializing InstanceTypeNotFound
Status in OpenStack Compute (Nova):
Fix Released
Bug description:
During server creation, if an instance type is disabled an
InstanceTypeNotFound is raised. This is caught in
nova/api/openstack/compute/servers.py and the exception is stuffed
into a HTTPBadRequest. Because the exception is put in there and not
the exception message, when the wsgi layer tries to serialize it it
results in:
2013-05-02 01:24:20.157 DEBUG nova.api.openstack.wsgi [req-9e8649fa-902d-4edc-99ba-cf1f88291bac demo demo] Calling method <bound method Controller.create of <nova.api.openstack.compute.servers.Controller object at 0x3efb890>> from (pid=16849) _process_stack /opt/stack/nova/nova/api/openstack/wsgi.py:920
2013-05-02 01:24:20.172 INFO nova.api.openstack.wsgi [req-9e8649fa-902d-4edc-99ba-cf1f88291bac demo demo] HTTP exception thrown: Instance type 2 could not be found.
2013-05-02 01:24:20.172 DEBUG nova.api.openstack.wsgi [req-9e8649fa-902d-4edc-99ba-cf1f88291bac demo demo] Returning 400 to user: Instance type 2 could not be found. from (pid=16849) __call__ /opt/stack/nova/nova/api/openstack/wsgi.py:1173
2013-05-02 01:24:20.172 ERROR nova.api.openstack [req-9e8649fa-902d-4edc-99ba-cf1f88291bac demo demo] Caught error: Circular reference detected
2013-05-02 01:24:20.172 TRACE nova.api.openstack Traceback (most recent call last):
2013-05-02 01:24:20.172 TRACE nova.api.openstack File "/opt/stack/nova/nova/api/openstack/__init__.py", line 81, in __call__
2013-05-02 01:24:20.172 TRACE nova.api.openstack return req.get_response(self.application)
2013-05-02 01:24:20.172 TRACE nova.api.openstack File "/usr/local/lib/python2.7/dist-packages/webob/request.py", line 1296, in send
2013-05-02 01:24:20.172 TRACE nova.api.openstack application, catch_exc_info=False)
2013-05-02 01:24:20.172 TRACE nova.api.openstack File "/usr/local/lib/python2.7/dist-packages/webob/request.py", line 1260, in call_application
2013-05-02 01:24:20.172 TRACE nova.api.openstack app_iter = application(self.environ, start_response)
2013-05-02 01:24:20.172 TRACE nova.api.openstack File "/usr/local/lib/python2.7/dist-packages/webob/dec.py", line 144, in __call__
2013-05-02 01:24:20.172 TRACE nova.api.openstack return resp(environ, start_response)
2013-05-02 01:24:20.172 TRACE nova.api.openstack File "/opt/stack/python-keystoneclient/keystoneclient/middleware/auth_token.py", line 451, in __call__
2013-05-02 01:24:20.172 TRACE nova.api.openstack return self.app(env, start_response)
2013-05-02 01:24:20.172 TRACE nova.api.openstack File "/usr/local/lib/python2.7/dist-packages/webob/dec.py", line 144, in __call__
2013-05-02 01:24:20.172 TRACE nova.api.openstack return resp(environ, start_response)
2013-05-02 01:24:20.172 TRACE nova.api.openstack File "/usr/local/lib/python2.7/dist-packages/webob/dec.py", line 144, in __call__
2013-05-02 01:24:20.172 TRACE nova.api.openstack return resp(environ, start_response)
2013-05-02 01:24:20.172 TRACE nova.api.openstack File "/usr/local/lib/python2.7/dist-packages/webob/dec.py", line 144, in __call__
2013-05-02 01:24:20.172 TRACE nova.api.openstack return resp(environ, start_response)
2013-05-02 01:24:20.172 TRACE nova.api.openstack File "/usr/lib/python2.7/dist-packages/routes/middleware.py", line 131, in __call__
2013-05-02 01:24:20.172 TRACE nova.api.openstack response = self.app(environ, start_response)
2013-05-02 01:24:20.172 TRACE nova.api.openstack File "/usr/local/lib/python2.7/dist-packages/webob/dec.py", line 144, in __call__
2013-05-02 01:24:20.172 TRACE nova.api.openstack return resp(environ, start_response)
2013-05-02 01:24:20.172 TRACE nova.api.openstack File "/usr/local/lib/python2.7/dist-packages/webob/dec.py", line 144, in __call__
2013-05-02 01:24:20.172 TRACE nova.api.openstack return resp(environ, start_response)
2013-05-02 01:24:20.172 TRACE nova.api.openstack File "/usr/local/lib/python2.7/dist-packages/webob/dec.py", line 130, in __call__
2013-05-02 01:24:20.172 TRACE nova.api.openstack resp = self.call_func(req, *args, **self.kwargs)
2013-05-02 01:24:20.172 TRACE nova.api.openstack File "/usr/local/lib/python2.7/dist-packages/webob/dec.py", line 195, in call_func
2013-05-02 01:24:20.172 TRACE nova.api.openstack return self.func(req, *args, **kwargs)
2013-05-02 01:24:20.172 TRACE nova.api.openstack File "/opt/stack/nova/nova/api/openstack/wsgi.py", line 1195, in __call__
2013-05-02 01:24:20.172 TRACE nova.api.openstack self.wrapped_exc.body = serializer.serialize(fault_data)
2013-05-02 01:24:20.172 TRACE nova.api.openstack File "/opt/stack/nova/nova/api/openstack/wsgi.py", line 321, in serialize
2013-05-02 01:24:20.172 TRACE nova.api.openstack return self.dispatch(data, action=action)
2013-05-02 01:24:20.172 TRACE nova.api.openstack File "/opt/stack/nova/nova/api/openstack/wsgi.py", line 186, in dispatch
2013-05-02 01:24:20.172 TRACE nova.api.openstack return action_method(*args, **kwargs)
2013-05-02 01:24:20.172 TRACE nova.api.openstack File "/opt/stack/nova/nova/api/openstack/wsgi.py", line 331, in default
2013-05-02 01:24:20.172 TRACE nova.api.openstack return jsonutils.dumps(data)
2013-05-02 01:24:20.172 TRACE nova.api.openstack File "/opt/stack/nova/nova/openstack/common/jsonutils.py", line 149, in dumps
2013-05-02 01:24:20.172 TRACE nova.api.openstack return json.dumps(value, default=default, **kwargs)
2013-05-02 01:24:20.172 TRACE nova.api.openstack File "/usr/lib/python2.7/json/__init__.py", line 238, in dumps
2013-05-02 01:24:20.172 TRACE nova.api.openstack **kw).encode(obj)
2013-05-02 01:24:20.172 TRACE nova.api.openstack File "/usr/lib/python2.7/json/encoder.py", line 201, in encode
2013-05-02 01:24:20.172 TRACE nova.api.openstack chunks = self.iterencode(o, _one_shot=True)
2013-05-02 01:24:20.172 TRACE nova.api.openstack File "/usr/lib/python2.7/json/encoder.py", line 264, in iterencode
2013-05-02 01:24:20.172 TRACE nova.api.openstack return _iterencode(o, 0)
2013-05-02 01:24:20.172 TRACE nova.api.openstack ValueError: Circular reference detected
2013-05-02 01:24:20.172 TRACE nova.api.openstack
The exception has a format_message() method for this, it just needs to be used.
To manage notifications about this bug go to:
https://bugs.launchpad.net/nova/+bug/1175414/+subscriptions