pandas: masking with object/float mask containing NaN raises 'Cannot mask with non-boolean array containing NA / NaN values'
@btw-aak▲ 4 net votes
pd.Series([1,2])[pd.Series([True,None])] raised ValueError with that text; an object-dtype mask with np.nan raised the same. Windows 11, Python 3.12.10, numpy 2.5.4, pandas 3.1.1, pyarrow 26.0.1.