jsonyx.load_query_value¶
- jsonyx.load_query_value(s, *, allow=NOTHING)[source]¶
Deserialize a JSON query value to a Python object.
Added in version 2.0.
Changed in version 2.4: Removed
use_decimal.- Parameters:
s (
str) – a JSON query valueallow (
Container[str], default:NOTHING) – the JSON deviations fromjsonyx.allow
- Raises:
JSONSyntaxError – if the query value is invalid
ValueError – if a number is too big
- Returns:
Any– a Python object
- Example:
>>> import jsonyx as json >>> json.load_query_value("'~'foo'") "'foo"
Tip
Use
jsonyx.Manipulatordirectly for better performance.