API JSON fields to support more than string and int values
Bug #1398350 reported by
Lucas Alvares Gomes
This bug affects 1 person
Affects | Status | Importance | Assigned to | Milestone | |
---|---|---|---|---|---|
Ironic |
Fix Released
|
Medium
|
Lucas Alvares Gomes |
Bug Description
Right now fields json fields like "extra", "properties", "driver_info" in our API only supports strings and integers. An attempt to post a float value for example would fail with:
[-] Client-side error: Invalid input for field/attribute value. Value: '0.123'. Wrong type. Expected '<type 'unicode'>', got '<type 'float'>' [1]
We should add support for all json primitives types to be supported on those fields, those are: bytes,
unicode, float, long, int, dict, list and bool.
Changed in ironic: | |
assignee: | nobody → Lucas Alvares Gomes (lucasagomes) |
importance: | Undecided → Medium |
Changed in ironic: | |
status: | New → In Progress |
Changed in ironic: | |
milestone: | none → kilo-2 |
status: | Fix Committed → Fix Released |
Changed in ironic: | |
milestone: | kilo-2 → 2015.1.0 |
To post a comment you must log in.
Reviewed: https:/ /review. openstack. org/137762 /git.openstack. org/cgit/ openstack/ ironic/ commit/ ?id=98d4bfd3ec2 14f941d2f99bc8b 5279bd0a9545ee
Committed: https:/
Submitter: Jenkins
Branch: master
commit 98d4bfd3ec214f9 41d2f99bc8b5279 bd0a9545ee
Author: Lucas Alvares Gomes <email address hidden>
Date: Fri Nov 28 11:06:05 2014 +0000
Extend API multivalue fields
This patch is creating a new JsonType type that accepts all the json
primitive types: bytes, unicode, float, long, int, dict, list, None
and bool.
Since the MultiType type is no longer used anywhere in the code it's
been deleted.
Closes-Bug: #1398350 789c2f60034c403 d28a5e2b9e8
Change-Id: I2d9e4f20419ca2