From 4eae556d128fe1cd5583c40800e02689426ebbb1 Mon Sep 17 00:00:00 2001 From: Dan Prince Date: Sat, 2 Mar 2013 10:11:30 -0500 Subject: Don't LOG.error on max_depth (by default). Reverts part of a94b9b4 which added an extra LOG.error statement when max_depth is hit. This is causing spurious errors to get logged in some of our projects which have adopted this changed. Related to: https://bugs.launchpad.net/nova/+bug/1140133 Change-Id: Ie7939e41797da000dd8b269f905f351df0b7116d --- openstack/common/jsonutils.py | 6 ------ 1 file changed, 6 deletions(-) (limited to 'openstack/common/jsonutils.py') diff --git a/openstack/common/jsonutils.py b/openstack/common/jsonutils.py index 1ea7755..04ffba0 100644 --- a/openstack/common/jsonutils.py +++ b/openstack/common/jsonutils.py @@ -38,14 +38,10 @@ import functools import inspect import itertools import json -import logging import xmlrpclib -from openstack.common.gettextutils import _ from openstack.common import timeutils -LOG = logging.getLogger(__name__) - def to_primitive(value, convert_instances=False, convert_datetime=True, level=0, max_depth=3): @@ -85,8 +81,6 @@ def to_primitive(value, convert_instances=False, convert_datetime=True, return 'mock' if level > max_depth: - LOG.error(_('Max serialization depth exceeded on object: %d %s'), - level, value) return '?' # The try block may not be necessary after the class check above, -- cgit