Skip to content

Monkey patch Hypothesis to work around st.floats() bug #43

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

Closed
wants to merge 1 commit into from

Conversation

honno
Copy link
Member

@honno honno commented Nov 17, 2021

Resolves #42 by monkey patching the relevant hypothesis.extra.array_api internals to work around HypothesisWorks/hypothesis#3153. This is done by filtering the original from_dtype() strategy to throw away the bad floats inbetween the smallest representable non-zero number and zero.

@asmeurer
Copy link
Member

Looks fine, although if this is going to be fixed upstream soon it's not necessary to work around it here.

@honno
Copy link
Member Author

honno commented Dec 3, 2021

Closing as #45 achieved the goals of this PR.

@honno honno closed this Dec 3, 2021
@honno honno deleted the float-width-patch branch February 28, 2024 13:19
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.

Subnormals make testing flush-to-zero libs/builds impractical
2 participants