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

Numeric values should not be converted to float #79

Open
plammens opened this issue Apr 16, 2023 · 0 comments
Open

Numeric values should not be converted to float #79

plammens opened this issue Apr 16, 2023 · 0 comments

Comments

@plammens
Copy link

Currently all numeric values returned by the API, which the API returns as strings, are converted by this library into floats. This is handy for working with the API results but could lead to problems due to floating point precision issues, which can be especially problematic in financial contexts such as this one. The whole reason why the API gives numeric results as strings is to avoid these kinds of problems. Perhaps the best solution would be to use Python's built-in decimal.Decimal type.

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

1 participant