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
The current implementation of eq, cmp in SphinxProxy violates symmetry. For instance, suppose you have
a = Object() b = SphinxProxy( a )
You have b==a return True, but a==b return False, and even b==b return False.
This makes it awkward to use SphinxProxy object directly in further queries, such as
get_object_or_404( id = b )
will fail because it is trying to use the eq operator treating b as the second argument.
Any way to improve this behavior?
The text was updated successfully, but these errors were encountered:
No branches or pull requests
The current implementation of eq, cmp in SphinxProxy violates symmetry. For instance, suppose you have
a = Object()
b = SphinxProxy( a )
You have b==a return True, but a==b return False, and even b==b return False.
This makes it awkward to use SphinxProxy object directly in further queries, such as
get_object_or_404( id = b )
will fail because it is trying to use the eq operator treating b as the second argument.
Any way to improve this behavior?
The text was updated successfully, but these errors were encountered: