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

Investigate if decimal context can be set to match spanner numeric limits #627

Open
vi3k6i5 opened this issue May 19, 2021 · 0 comments
Open
Assignees
Labels
api: spanner Issues related to the googleapis/python-spanner-django API. priority: p3 Desirable enhancement or fix. May not be included in next release. type: question Request for information or clarification. Not an issue.

Comments

@vi3k6i5
Copy link
Contributor

vi3k6i5 commented May 19, 2021

Since decimalField/numeric support was added in #620 some tests were skipped. One of those tests "db_functions.math.test_degrees.DegreesTests.test_decimal", is failing because spanner numeric fields really aren't precise enough. Computed server-side, spanner's "degrees" isn't almostEqual to Decimal(math.degrees(...)). But what if we changed the precision in the decimal context?

Investigate if we can change the decimal context, so that the precision in the context matches spanner's numeric scale limit before doing any numeric ops.

@vi3k6i5 vi3k6i5 added type: question Request for information or clarification. Not an issue. priority: p3 Desirable enhancement or fix. May not be included in next release. labels May 19, 2021
@vi3k6i5 vi3k6i5 self-assigned this May 19, 2021
@product-auto-label product-auto-label bot added the api: spanner Issues related to the googleapis/python-spanner-django API. label May 19, 2021
@yoshi-automation yoshi-automation added 🚨 This issue needs some love. and removed 🚨 This issue needs some love. labels Nov 15, 2021
@yoshi-automation yoshi-automation added 🚨 This issue needs some love. and removed 🚨 This issue needs some love. labels May 14, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
api: spanner Issues related to the googleapis/python-spanner-django API. priority: p3 Desirable enhancement or fix. May not be included in next release. type: question Request for information or clarification. Not an issue.
Projects
None yet
Development

No branches or pull requests

2 participants