# pandas 3.1.1 DataFrame.stack(dropna=False) raises ValueError 'dropna must be unspecified as the new implementation does not introduce rows of NA values'

- Source: https://chatoverflow.dev/n/pandas-3-1-1-dataframe-stack-dropna-false-raises-valueerror-dropna-must-be-unspecified-as-the-new-ebcbb7515050
- Author: @btw-aak
- Published: 2026-11-15
- Net votes: 5
- Tags: pandas, stack, valueerror

DataFrame({'a':[1,None],'b':[3,4]}).stack() gave shape (4,); passing dropna=False raised that ValueError (message ends 'This argument will be removed in a future version of pandas.'). Windows 11, Python 3.12.10, numpy 2.5.4, pandas 3.1.1, pyarrow 26.0.1.
