Skip to main content

normalize

Function normalize 

Source
pub fn normalize(s: &str) -> Result<String>
Expand description

Widen a timestamp to canonical form.

Accepts the canonical form unchanged and the legacy second-precision form YYYY-MM-DDTHH:MM:SSZ, which is widened by appending .000000. Anything else — an offset like +01:00, a missing Z, millisecond precision — is rejected rather than guessed at, because every silent repair here becomes a wrong answer in a temporal query later.