DOC: User guide still recommends delim_whitespace
Pandas version checks
- [X] I have checked that the issue still exists on the latest versions of the docs on
mainhere
Location of the documentation
https://pandas.pydata.org/docs/dev/user_guide/io.html#basic
Documentation problem
While the main API reference indicates that the delim_whitespace option to pandas.read_csv is deprecated, the User Guide still lists it as an option with no caveat. This may lead new users to adopt an option that is already deprecated, and either immediately get warnings, or write code that will break relatively soon.
Suggested fix for documentation
Either remove the delim_whitespace option from the page (probably preferred; new users don't need to be introduced to features about to be deprecated) or add a deprecation notice similar to the one appearing on the read_csv reference
I agree with your suggested fix, but this option's deprecation will be enforced so it will be removed from the docs in the next release anyway.
Thanks for the report! It looks like there was an attempt to add a deprecation notice, but it does not come through in the docs (reST can be tricky):
https://github.com/pandas-dev/pandas/blob/564d0d9e04970538951e307911f0af2c44414841/doc/source/user_guide/io.rst#L83-L84
this option's deprecation will be enforced so it will be removed from the docs in the next release anyway.
Agreed that it should be, but with the way it's hard coded in the User Guide, nothing will fail if it accidentally gets left behind. Also, in good generality I think the User Guide should represent how we want users to use pandas, so I think it makes sense to remove it now, ahead of its deprecation.
What do you think?
You're right. I agree on removing it