remarshal-project / remarshal

Convert between CBOR, JSON, MessagePack, TOML, and YAML

Home Page:https://pypi.org/project/remarshal/

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

ruamel-yaml as Yaml backend?

thorstenkampe opened this issue · comments

Have you considered switching the Yaml backend to ruamel-yaml (a fork of PyYAML which preserves comments and ordering of keys)?

ruamel-yaml looks promising. Thanks for letting me know about it.

My plan is to stick with PyYAML unless a dire need arises to switch. I have complains with it, but PyYAML is stable and the most likely to continue to be maintained. I have already added ordering support on top of vanilla PyYAML in #11. As for comments, preserving them would be neat, but only be useful for yaml2yaml. (JSON doesn't have comments and pytoml currently doesn't support them.) YAML reformatting is not a priority for me with Remarshal, so I won't implement this feature.