YAML roundtrip parsing /u/eztab Python Education

Hi everyone,

I’m wondering if anyone knows a way to read in YAML files, read and change some options, and then safe them back, preserving comments, indentation and block styles?

I know YAML is kind of known for not having any parsers that support all of the (sometimes obscure) features. There seem to be quite a few libraries with various states of being maintained, but I haven’t seen any that are somewhat roundtrip capable, since the convert the loaded object to a dict.

I also need that functionality for TOML, where I am currently planning to use TOML Kit. So any accounts of experiences with that are also welcome.

submitted by /u/eztab
[link] [comments]

​r/learnpython Hi everyone, I’m wondering if anyone knows a way to read in YAML files, read and change some options, and then safe them back, preserving comments, indentation and block styles? I know YAML is kind of known for not having any parsers that support all of the (sometimes obscure) features. There seem to be quite a few libraries with various states of being maintained, but I haven’t seen any that are somewhat roundtrip capable, since the convert the loaded object to a dict. I also need that functionality for TOML, where I am currently planning to use TOML Kit. So any accounts of experiences with that are also welcome. submitted by /u/eztab [link] [comments] 

Hi everyone,

I’m wondering if anyone knows a way to read in YAML files, read and change some options, and then safe them back, preserving comments, indentation and block styles?

I know YAML is kind of known for not having any parsers that support all of the (sometimes obscure) features. There seem to be quite a few libraries with various states of being maintained, but I haven’t seen any that are somewhat roundtrip capable, since the convert the loaded object to a dict.

I also need that functionality for TOML, where I am currently planning to use TOML Kit. So any accounts of experiences with that are also welcome.

submitted by /u/eztab
[link] [comments] 

Leave a Reply

Your email address will not be published. Required fields are marked *