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

Added support for environments where the FloatOperation signal is trapped in the Decimal library #391

Open
wants to merge 1 commit into
base: main
Choose a base branch
from

Conversation

guspix
Copy link

@guspix guspix commented Feb 15, 2025

From Python's Decimal module Quick-start Tutorial:

If the FloatOperation signal is trapped, accidental mixing of decimals and floats in constructors or ordering comparisons raises an exception

This is used to prevent loss of precision by using floats before converting to Decimal. This was happening in a couple of places in this library, which prevented me from using it in such an environment. The fix is pretty simple, presumably without changing any functionality for anyone.

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.

1 participant