yahoo-eng-team team mailing list archive
-
yahoo-eng-team team
-
Mailing list archive
-
Message #01887
[Bug 1119790] Re: Circular reference detected ValueError due to JSONDictSerializer
Reviewed: https://review.openstack.org/25922
Committed: http://github.com/openstack/quantum/commit/46af52f24de13ce535a81573210d1a4f1bd93d96
Submitter: Jenkins
Branch: milestone-proposed
commit 46af52f24de13ce535a81573210d1a4f1bd93d96
Author: He Jie Xu <xuhj@xxxxxxxxxxxxxxxxxx>
Date: Wed Mar 27 07:42:20 2013 +0800
Return unicode for object in json and xml serializer
Fix bug 1160644
Fix bug 1119790
When try to serialize an exception object as json, it failed
with 'ValueError: Circular reference detected' that is same error
as bug 119790. So this patch fixes bug 119790 too.
Change-Id: I0da2616f4ec59da31be054b8be2f7a140f59d63a
(cherry picked from commit 26dca9ff02dc9eb9b431ea66ec60fb828b4ae0a5)
** Changed in: quantum
Status: Fix Committed => Fix Released
--
You received this bug notification because you are a member of Yahoo!
Engineering Team, which is subscribed to quantum.
https://bugs.launchpad.net/bugs/1119790
Title:
Circular reference detected ValueError due to JSONDictSerializer
Status in OpenStack Quantum (virtual network service):
Fix Released
Bug description:
While running the unit tests I am seeing this error (and more like
this):
======================================================================
ERROR: test_create_network_with_portsecurity_false (quantum.tests.unit.nicira.test_nicira_plugin.TestNiciraPortSecurity)
----------------------------------------------------------------------
Traceback (most recent call last): File "quantum/quantum/tests/unit/test_extension_portsecurity.py", line 198, in test_create_network_with_portsecurity_false
port_security_enabled=False)
File "quantum/quantum/tests/unit/test_db_plugin.py", line 225, in _create_network
return network_req.get_response(self.api)
File "quantum/.venv/local/lib/python2.7/site-packages/webob/request.py", line 1296, in send
application, catch_exc_info=False)
File "quantum/.venv/local/lib/python2.7/site-packages/webob/request.py", line 1260, in call_application
app_iter = application(self.environ, start_response)
File "quantum/.venv/local/lib/python2.7/site-packages/webob/dec.py", line 144, in __call__
return resp(environ, start_response)
File "quantum/.venv/local/lib/python2.7/site-packages/routes/middleware.py", line 131, in __call__
response = self.app(environ, start_response)
File "quantum/.venv/local/lib/python2.7/site-packages/webob/dec.py", line 144, in __call__
return resp(environ, start_response)
File "quantum/.venv/local/lib/python2.7/site-packages/webob/dec.py", line 130, in __call__
resp = self.call_func(req, *args, **self.kwargs)
File "quantum/.venv/local/lib/python2.7/site-packages/webob/dec.py", line 195, in call_func
return self.func(req, *args, **kwargs)
File "quantum/quantum/api/v2/resource.py", line 109, in resource
body = serializer.serialize(result)
File "quantum/quantum/wsgi.py", line 228, in serialize
return self.dispatch(data, action=action)
File "quantum/quantum/wsgi.py", line 218, in dispatch
return action_method(*args, **kwargs)
File "quantum/quantum/wsgi.py", line 238, in default
return jsonutils.dumps(data)
File "quantum/quantum/openstack/common/jsonutils.py", line 130, in dumps
return json.dumps(value, default=default, **kwargs)
File "/usr/lib/python2.7/json/__init__.py", line 238, in dumps
**kw).encode(obj)
File "/usr/lib/python2.7/json/encoder.py", line 201, in encode
chunks = self.iterencode(o, _one_shot=True)
File "/usr/lib/python2.7/json/encoder.py", line 264, in iterencode
return _iterencode(o, 0)
ValueError: Circular reference detected
OSLO seems to have fixed this in it's wsgi version:
https://review.openstack.org/#/c/18877
Proposing to port this as a defensive fix.
To manage notifications about this bug go to:
https://bugs.launchpad.net/quantum/+bug/1119790/+subscriptions