np.cumsum([1, 2, 3, np.nan, 4, 5, 6]) will return nan for every value after the first np.nan. Moreover, it will do the same for any generator. However, np.cumsum(df['column']) will not. What does np.cumsum(...) do, such that dataframes are treated specially?
In [2]: df = pd.DataFrame({'column': [1, 2, 3, np.nan, 4, 5, 6]})
In [3]: np.cumsum(df['column'])
Out[3]:
0 1.0
1 3.0
2 6.0
3 NaN
4 10.0
5 15.0
6 21.0
Name: column, dtype: float64