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

JsonWire - Improve serialisation of Double NaN and Infinity #982

Closed
tgd opened this issue Jan 1, 2025 · 1 comment
Closed

JsonWire - Improve serialisation of Double NaN and Infinity #982

tgd opened this issue Jan 1, 2025 · 1 comment
Assignees

Comments

@tgd
Copy link
Contributor

tgd commented Jan 1, 2025

Historically JsonWire in some cases would emit 'null' for Double.NaN' and the unquoted strings InfinityforDouble.Infinite`. In the latter case this token was not represented as a JSON string literal in double quotes so would create parse errors when that JSON was re-parsed down the line.

This ticket does the following:

  • Maps Double.NaN, Double.POSITIVE_INFINITY, Double.NEGATIVE_INFINITY to the JSON strings "NaN", "Infinity", "-Infinity"
  • Implements the same logic for float
@tgd tgd self-assigned this Jan 1, 2025
tgd added a commit that referenced this issue Jan 1, 2025
Includes fixes for Double.NaN, Double.POSITIVE_INFINITY, Double.NEGATIVE_INFINITY.
tgd added a commit that referenced this issue Jan 1, 2025
Includes fixes for Double.NaN, Double.POSITIVE_INFINITY, Double.NEGATIVE_INFINITY.
@hft-team-city
Copy link
Collaborator

Released in Chronicle-Wire-2.27ea2, BOM-2.27ea11

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

No branches or pull requests

2 participants