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

fix: don't display decimals in scientific notation in CLI #4723

Merged

Conversation

big-andy-coates
Copy link
Contributor

@big-andy-coates big-andy-coates commented Mar 6, 2020

Description

fixes: #4722

This change sees decimals being returned by the rest api avoiding use of scientific notation. For example, a decimal such as 100 will be returned as 100 and not 1e+2.

The CLI just displays what it given.

Note: this does not affect how data in persistent queries is written. I believe the json serializer will still prefer scientific notation.

NOTE: This is targeted at 5.4.x at the moment. It's a minor change that can be included in the new point release for 5.4 and in 5.5.

Testing done

added unit test.

Reviewer checklist

  • Ensure docs are updated if necessary. (eg. if a user visible feature is being added or changed).
  • Ensure relevant issues are linked (description should include text like "Fixes #")

fixes: confluentinc#4722

This change sees decimals being returned by the rest api avoiding use of scientific notation. For example, a decimal such as `100` will be returned as `100` and not `1e+2`.

The CLI just displays what it given.
@big-andy-coates big-andy-coates requested a review from a team as a code owner March 6, 2020 10:45
Copy link
Contributor

@agavra agavra left a comment

Choose a reason for hiding this comment

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

Happy with this :)

@big-andy-coates big-andy-coates merged commit 3626f42 into confluentinc:5.4.x Mar 10, 2020
@big-andy-coates big-andy-coates deleted the decimal_none_scientific branch March 10, 2020 11:04
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