MCPcopy Create free account
hub / github.com/piccolo-orm/piccolo / clean_value

Method clean_value

piccolo/query/operators/json.py:14–17  ·  view source on GitHub ↗
(self, value: Any)

Source from the content-addressed store, hash-verified

12class JSONQueryString(QueryString):
13
14 def clean_value(self, value: Any):
15 if not isinstance(value, (str, QueryString)):
16 value = dump_json(value)
17 return value
18
19 def __eq__(self, value) -> QueryString: # type: ignore[override]
20 value = self.clean_value(value)

Callers 2

__eq__Method · 0.95
__ne__Method · 0.95

Calls 1

dump_jsonFunction · 0.90

Tested by

no test coverage detected