Skip to content

issue #443: quote Y and N when dumping#641

Merged
tenderlove merged 2 commits intoruby:masterfrom
Invoca:quote-Y-N
Jan 17, 2024
Merged

issue #443: quote Y and N when dumping#641
tenderlove merged 2 commits intoruby:masterfrom
Invoca:quote-Y-N

Conversation

@ColinDKelley
Copy link
Contributor

Building on #515, this has the uppercase fixes as well for #443.

def test_n_is_quoted
assert_match(/"n"/, Psych.dump("n"))
assert_match(/"N"/, Psych.dump("N"))
end
Copy link
Contributor Author

@ColinDKelley ColinDKelley Jul 19, 2023

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@tenderlove The test below encompasses these 2 special cases, so I'd be happy to drop these 2 if you're good with it.

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Yes, the test you have below seems good enough

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Great, I dropped the 2 special tests, but left the comment (updated for uppercase): 6750b35

@ColinDKelley
Copy link
Contributor Author

@tenderlove Anything else needed before merging this PR?

@ColinDKelley
Copy link
Contributor Author

@tenderlove Just checking in here. Anything else needed before merging this PR?

1 similar comment
@ColinDKelley
Copy link
Contributor Author

@tenderlove Just checking in here. Anything else needed before merging this PR?

@tenderlove tenderlove merged commit 0ebd571 into ruby:master Jan 17, 2024
@ColinDKelley ColinDKelley deleted the quote-Y-N branch January 24, 2024 04:41
gordoncl added a commit to gordoncl/countries that referenced this pull request Oct 12, 2025
Simply runs YAML files through YAML.load and YAML.dump. This is to accommodate
formatting changes brought in with the latest version of psych.

See ruby/psych#641 for more
gordoncl added a commit to gordoncl/countries that referenced this pull request Oct 12, 2025
Simply runs YAML files through YAML.load and YAML.dump. This is to accommodate
formatting changes brought in with the latest version of psych.

Some changes are from a recent change which quotes the literals **Y** and **N*.
See ruby/psych#641 for more

Another change is simply from not specifying :line_width.
See https://docs.ruby-lang.org/en/master/Psych.html#method-c-dump
gordoncl added a commit to gordoncl/countries that referenced this pull request Oct 12, 2025
Simply runs YAML files through YAML.load and YAML.dump. This is to accommodate
formatting changes brought in with the latest version of psych.

Some changes are from a recent change which quotes the literals **Y** and **N*.
See ruby/psych#641 for more

Another change is simply from not specifying :line_width.
See https://docs.ruby-lang.org/en/master/Psych.html#method-c-dump
gordoncl added a commit to gordoncl/countries that referenced this pull request Oct 12, 2025
Simply runs YAML files through YAML.load and YAML.dump. This is to accommodate
formatting changes brought in with the latest version of psych.

Some changes are from a recent change which quotes the literals **Y** and **N*.
See ruby/psych#641 for more

Another change is simply from not specifying :line_width.
See https://docs.ruby-lang.org/en/master/Psych.html#method-c-dump
gordoncl added a commit to gordoncl/countries that referenced this pull request Oct 12, 2025
Simply runs YAML files through YAML.load and YAML.dump. This is to accommodate
formatting changes brought in with the latest version of psych.

Some changes are from a recent change which quotes the literals **Y** and **N*.
See ruby/psych#641 for more

Another change is simply from not specifying :line_width.
See https://docs.ruby-lang.org/en/master/Psych.html#method-c-dump
gordoncl added a commit to gordoncl/countries that referenced this pull request Oct 12, 2025
Simply runs YAML files through YAML.load and YAML.dump. This is to accommodate
formatting changes brought in with the latest version of psych.

Some changes are from a recent change which quotes the literals **Y** and **N*.
See ruby/psych#641 for more

Another change is simply from not specifying :line_width.
See https://docs.ruby-lang.org/en/master/Psych.html#method-c-dump
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants