dasel
dasel copied to clipboard
Emoji is changed to Unicode in yaml
Describe the bug Emoji is changed to Unicode in yaml
To Reproduce
$ cat flag.json
{
"US": "πΊπΈ",
"CN": "π¨π³"
}
$ dasel -f flag.json -w yaml
US: "\U0001F1FA\U0001F1F8"
CN: "\U0001F1E8\U0001F1F3"
$ dasel -f flag.json -w toml
CN = 'π¨π³'
US = 'πΊπΈ'
Expected behavior Emoji remains unchanged in yaml
Desktop (please complete the following information):
- OS: Ubuntu 24.04
- Version: v2.8.1
- Terminal: Wezterm 20240203-110809-5046fc22
This is caused by the imported YAML parser: https://github.com/go-yaml/yaml/issues/737
It looks like there's a potential fix in https://github.com/go-yaml/yaml/pull/738, however it's still waiting for review and merge years later.
I've deleted the comment above because of safety concerns. It contained a phishing/malicious link.