ChangBo Guo(gcb) 3727b2d6e0 Explicitly raise ValueError in to_primitive
The problem in the current version of to_primitive function
from jsonutils module is in the situation when the function
doesn't know how to convert an object to primitive. In that
case the function simply returns the same object which causes
the following exception later in json.dumps:
ValueError: Circular reference detected. This exception is not
obvious and is quite misleading. So I think it would be better
to explicitly raise ValueError here.

Closes-Bug: #1593641

Change-Id: If9e8dd5cc2634168910d5f9f8d9302aeefa16097
2017-05-17 15:55:14 +08:00
2017-01-20 19:15:52 +00:00
2016-12-20 14:36:50 +11:00
2015-11-16 21:41:23 +08:00
2016-11-25 15:21:15 +01:00
2017-03-16 15:01:15 +00:00
2017-03-03 00:03:20 +00:00
2017-01-17 10:34:52 -08:00

Team and repository tags

image

oslo.serialization

Latest Version

Downloads

The oslo.serialization library provides support for representing objects in transmittable and storable formats, such as Base64, JSON and MessagePack.

Description
OpenStack library for serialization
Readme 3.2 MiB
Languages
Python 100%