You are viewing a plain text version of this content. The canonical link for it is here.
Posted to github@arrow.apache.org by GitBox <gi...@apache.org> on 2021/04/19 13:00:03 UTC

[GitHub] [arrow] jorisvandenbossche commented on a change in pull request #10099: ARROW-12466: [Python] Avoid AttributeError crash when comparing with None

jorisvandenbossche commented on a change in pull request #10099:
URL: https://github.com/apache/arrow/pull/10099#discussion_r615825723



##########
File path: python/pyarrow/tests/test_array.py
##########
@@ -2615,6 +2615,8 @@ def __arrow_array__(self, type=None):
     expected = pa.array([1, 2, 3], type=pa.float64())
     assert result.equals(expected)
 
+    assert (result == None) is False

Review comment:
       I think this test is otherwise unrelated, so I would rather add this to `test_array_eq` (or maybe as a new test adjacent to that one). At once, you could maybe also add a test for other scalars like `result == 1` (that will also always return False)




-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
users@infra.apache.org