We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
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
If you compare Bn to anything that is not a Bn...
Bn(42) == "something"
...petlib falls into a recursive death:
Output: AttributeError Traceback (most recent call last) ~/Workspace/zkc/venv/lib/python3.6/site-packages/petlib/bn.py in __inner_cmp__(self, other) 283 try: --> 284 sig = int(_C.BN_cmp(self.bn, other.bn)) 285 return sig AttributeError: 'NotImplementedType' object has no attribute 'bn' During handling of the above exception, another exception occurred: RecursionError Traceback (most recent call last) <ipython-input-2-ea31e540b152> in <module>() ----> 1 Bn(42) == "statast" ~/Workspace/zkc/venv/lib/python3.6/site-packages/petlib/bn.py in __eq__(self, other) 294 295 def __eq__(self, other): --> 296 return self.__inner_cmp__(other) == 0 297 298 def __ne__(self, other): ~/Workspace/zkc/venv/lib/python3.6/site-packages/petlib/bn.py in __inner_cmp__(self, other) 285 return sig 286 except AttributeError: --> 287 return self.__inner_cmp__(Bn.from_num(other)) 288 289 def __lt__(self, other): ... last 1 frames repeated, from the frame below ... ~/Workspace/zkc/venv/lib/python3.6/site-packages/petlib/bn.py in __inner_cmp__(self, other) 285 return sig 286 except AttributeError: --> 287 return self.__inner_cmp__(Bn.from_num(other)) 288 289 def __lt__(self, other): RecursionError: maximum recursion depth exceeded while calling a Python object
The text was updated successfully, but these errors were encountered:
Nice one!
Sorry, something went wrong.
I ran into the same issue and created this PR to fix it: #26
Just merged the fix -- thanks @ravirahman
bogdan-kulynych
No branches or pull requests
If you compare Bn to anything that is not a Bn...
...petlib falls into a recursive death:
The text was updated successfully, but these errors were encountered: