Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

`*` string gets rendered with a bang on front #113

roman opened this issue Jul 13, 2017 · 3 comments


Copy link

commented Jul 13, 2017

Hey Michael,

First of all, thank you for taking the time to read this ticket. I've been using your library to parse YAML files that I want to modify and re-render. I discovered this behavior when doing some template transformations:

λ YAML.encode (JSON.String "*")
"! '*'\n"
it :: ByteString

I'm having some templates that have the value '*' in their fields, and when doing a parsing -> rendering it adds that bang at the beginning of the string. I'm guessing this behavior doesn't come from this library but from the libYAML one. Is there a way to stop this behavior?

snoyberg added a commit that referenced this issue Jul 14, 2017

This comment has been minimized.

Copy link

commented Jul 14, 2017

Pleasure to read the ticket :)

This one seems pretty easy: just add * to the set of special strings that have explicit quoting rules applied. I've added this in aa7d64b. Would you be able to give that a shot and see if it addresses your problem?


This comment has been minimized.

Copy link

commented Jul 15, 2017

Hi @snoyberg,

Impressed by how quickly you addressed this, yup the commit seems does the trick, thank you very much sir.

Closing now.

@roman roman closed this Jul 15, 2017


This comment has been minimized.

Copy link

commented Jul 16, 2017

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
None yet
2 participants
You can’t perform that action at this time.