10 releases

new 0.2.4 Dec 10, 2024
0.2.3 Nov 14, 2024
0.2.1 Mar 21, 2024
0.1.8 Oct 11, 2023
0.1.4 Mar 8, 2022

#165 in Encoding

Download history 3433/week @ 2024-08-21 3252/week @ 2024-08-28 3164/week @ 2024-09-04 3492/week @ 2024-09-11 3409/week @ 2024-09-18 3402/week @ 2024-09-25 3240/week @ 2024-10-02 2880/week @ 2024-10-09 2647/week @ 2024-10-16 2694/week @ 2024-10-23 2568/week @ 2024-10-30 2431/week @ 2024-11-06 3437/week @ 2024-11-13 3575/week @ 2024-11-20 3109/week @ 2024-11-27 2831/week @ 2024-12-04

13,347 downloads per month

MIT/Apache

575KB
14K SLoC

serde_json_lenient   Build Status Latest Version Rustc Version 1.36+

This is a lenient JSON parser forked from the serde_json crate that is that is designed to parse JSON written by humans (e.g., JSON config files). This means that it supports:

  • /* and // style comments.
  • Trailing commas for object and array literals.
  • \v and \xDD literal escapes (for vertical tab and two-digit hexadecimal characters)
  • [planned] Unquoted object keys (precise spec TBD).

Each such feature is switchable.

Earlier work to make serde_json more lenient was performed by Michael Bolin as the crate serde_jsonrc. This crate builds on his work and updates to more recent [serde_json].

Why not make serde_json more lenient?

The maintainer wanted to keep the scope of serde_json limited to strict JSON, so we respectfully agreed that forking was the way to go.

License

Because serde_json_lenient is a fork of serde_json, it maintains the original licence, which means it is licensed under either of

at your option.

Contribution

Unless you explicitly state otherwise, any contribution intentionally submitted for inclusion in serde_json_lenient by you, as defined in the Apache-2.0 license, shall be dual licensed as above, without any additional terms or conditions.

Dependencies

~0.3–0.8MB
~15K SLoC