BUG: Improve Error Message for Multi-Char Sep + Quotes in Python Engine by gfyoung · Pull Request #14582 · pandas-dev/pandas (original) (raw)

@gfyoung It's quite possible your proposed change is the sensible thing to do, but I think you need to try to explain your changes and its consequences a bit better (in this case "Title is self-explanatory" is not really true .. :-))

As I understand it now, the consequence of your proposed change is that when somebody now does (on a file that does not necessarily contain quotes):

pd.read_csv(file, sep='\s+', engine='python')

this will raise an error now (so breaking code). To resolve this error, the user needs to add quoting=csv.QUOTE_NONE (as this is not the default).
Is this correct?

In this case, for me this is a trade-off between having to provide an extra (unneeded) keyword in the simple case (no quotes in file) vs having a wrong error message in case of quotes + sep present in quotes (current behaviour that you are trying to fix).