pub fn pyobject_to_value(obj: &Bound<'_, PyAny>) -> PyResult<Value>Expand description
Convert a Python object back into a serde_json::Value.
bytes are encoded as a JSON object { "__bytes__": [...] } so the
host can recover them via a custom serde adapter (today only used by
internal error paths — typed bytes go through #[wire(raw)] instead).