question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Negative numbers not quoted correctly wrt `ALWAYS_QUOTE_NUMBERS_AS_STRINGS`

See original GitHub issue

When initializing a YamlFactory as follows, negative numbers are not quoted correctly.

YAMLFactory factory = new YAMLFactory();
factory.enable(YAMLGenerator.Feature.MINIMIZE_QUOTES);
factory.enable(YAMLGenerator.Feature.ALWAYS_QUOTE_NUMBERS_AS_STRINGS);

Serializing 60 currently results in "60". Serializing -14 currently results in 14.

Issue Analytics

  • State:closed
  • Created 4 years ago
  • Comments:5 (5 by maintainers)

github_iconTop GitHub Comments

1reaction
cowtowncodercommented, Mar 17, 2020

@dpbevin Thank you very much for reporting this, contributing fix! Backported in 2.10 so it’ll be in 2.10.4 as well as 2.11.0.

0reactions
cowtowncodercommented, Mar 17, 2020

@dpbevin that’s perfectly fine, I should have waited couple of minutes 😃

(just happened to go through my email when notification just arrived)

Read more comments on GitHub >

github_iconTop Results From Across the Web

Negative numbers aren't showing with parentheses in Excel
Negative numbers not showing with parentheses? This article will explain how to fix this problem in Windows 10.
Read more >
Negative Numbers in Excel
Negative numbers are typed into Excel by using a hyphen - symbol and the number. Example: negative 3 is typed “-3†without the...
Read more >
Why can't R handle inequalities between negative numbers in ...
A "number in quotes" is not a number at all, it is a string of characters. Those characters happen to be displayed with...
Read more >
We have a decimal field created that contains negative ...
In the Classic UI the field sorts correctly showing negative numbers smaller than their counterparts. In the new UI the sort does not...
Read more >
Quote Line Editor does not show negative ... - Salesforce CPQ
In CPQ Version 220 with multi-currency enabled currency fields will not display negative values correctly- instead they will show as positive.
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found