-
Notifications
You must be signed in to change notification settings - Fork 748
PyObject.GetHashCode overflow bug #676
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
Comments
Yes, please, can you prepare a PR for this? |
I don't have the project set up. I can submit a blind untested PR if that helps. |
Sure, go ahead. It's anyways tricky to write tests for this as you need both a 64bit system and reliably force allocation above 2^32 for this patch to make a difference. |
The PR is there. Some build stuff failed. I have no idea what it means. I compiled and ran tests locally. |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
PyObject.GetHashCode()
can throw an OverflowException becauseIntPtr.ToInt32()
does throw. Seepythonnet/src/runtime/pyobject.cs
Line 912 in b8cb6c4
This happened to me when inserting into a dictionary using tensorflow objects as keys:
Environment
The text was updated successfully, but these errors were encountered: