-
Notifications
You must be signed in to change notification settings - Fork 39
AssertionError when Table is part of a list #235
Comments
I noticed the above example is actually raising yet another, different
Also I noticed a
|
Implementing array.boolmask(maskedwhen=True).any() # True if it contains `None` If you don't have a MaskedArray, BitMaskedArray, or IndexedMaskedArray, the value can never be |
I'm not sure if I understand your answer correctly. |
Oh, I did misunderstand. Checking for >>> None in [numpy.array([[1, 2], [3, 4]]), None]
Traceback (most recent call last):
File "<stdin>", line 1, in <module>
ValueError: The truth value of an array with more than one element is ambiguous. Use a.any() or a.all() Awkward should fail as gracefully as that. To solve your problem, though, you'll want something like any(None is x for x in that_list) |
Ah, you are right. I was testing it on numpy with
which works. |
I have a list of elements and I need to see if
None
is part of that list, so I doBut if elements contains an awkward.Table I get an
AssertionError
:I would like to be able to use
in
even for lists sometimes containing Tables.The text was updated successfully, but these errors were encountered: