-
Notifications
You must be signed in to change notification settings - Fork 94
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
filter.Expresson.find() does not handle 'None' values correctly #153
Comments
Minor correction above. Instead of , |
Is there any chance this will be fixed? Or is there a chance that PRs addressing this will be merged and released? Is this library still maintained at all? This part of the code is at least part of the issue since True/False are instances of int, that whole conditional block is broken and it works for actual booleans by chance. |
Hi guys! I made an adjustment to this PR #189 by removing the conditional for boolean values because I didn't find any scenario that requires conversion to bool.
The int type in Python can be represented by an integer (0, 1), bool is a subclass of int. So to only handle integers, I changed the isinstance condition to type. This way it rejects subclasses. If anyone finds a scenario that requires conversion to bool, I can add it to the unit test. |
find()
doesn't seem to be able to handleNone
values.Example:
Causes the following error:
The text was updated successfully, but these errors were encountered: