Open
Description
I have some YAML with some values containing non-breaking spaces, correctly formatted according to the YAML spec's guidelines on escaped characters as "\_"
. Psych correctly loads these strings and converts them to non-breaking space characters (\u00A0
). The issue is that when dumping back to YAML, Psych does not correctly escape these non-printable characters as specified by the spec.
Example
Expected
irb(main):002:0> Psych.dump(Psych.load('"\\_"'))
=> "--- \"\\_\"\n"
Actual
irb(main):002:0> Psych.dump(Psych.load('"\\_"'))
=> "--- \" \"\n"
Metadata
Metadata
Assignees
Labels
No labels