Skip to main content

encode_v1

Function encode_v1 

Source
pub fn encode_v1(state: &Value) -> Result<Vec<u8>, StateError>
Expand description

Encode a state snapshot in the v1 wire format: compact JSON terminated by a newline. Equivalent to Python json.dumps(state).encode() + b"\n".