Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

CLN: Remove mangle_dupe_cols argument #48037

Closed

Conversation

datapythonista
Copy link
Member

Addressing #47718 step by step. Here I remove the mangle_dupe_cols, which was never implemented. I directly remove it, instead of showing deprecation, because I don't think in practice this should be breaking code. For example, the next code:

pandas.read_csv(fname, mangle_dupe_cols=False)

Would raise an exception in all cases. So, I don't think making it showing a warning before raising the exception should be very useful. There could be the case of someone using:

pandas.read_csv(fname, mangle_dupe_cols=True)

Where the mangle_dupe_cols=True literally does nothing as it's the default. If people were doing this it'd make sense to show a FutureWarning, but I don't see any reason why anyone would do that. So, in practice, I think we'd just be overcomplicating things with the deprecation in this case, and I think it's better to simply delete it.

@datapythonista datapythonista added API Design IO CSV read_csv, to_csv IO Excel read_excel, to_excel Clean labels Aug 11, 2022
@mroeschke
Copy link
Member

We have deprecation in 1.5 for an unused argument in a function, so there's precedence for also adding a deprecation here too #47728. It would make this PR a little more complicated as you said (change default arg to lib.no_default and raise warning if True was passed)

Would this close #13262 and #8908 as well?

@datapythonista
Copy link
Member Author

Thanks for the feedback Matthew. Feels it may be a bit too much conservative in my opinion, but if this is what was agreed and what we've been doing, I'll better add the deprecation then. This should close the issues you mention too, thanks for the reminder.

I'll implement the deprecation in a separate branch, as there is not much that can be reused here. So, closing this PR.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
API Design Clean IO CSV read_csv, to_csv IO Excel read_excel, to_excel
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants