8000 DEP: Deprecate quote_args (from numpy.distutils.misc_util) by mwtoews · Pull Request #19811 · numpy/numpy · GitHub
[go: up one dir, main page]

Skip to content

DEP: Deprecate quote_args (from numpy.distutils.misc_util) #19811

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

Merged
merged 1 commit into from
Sep 2, 2021

Conversation

mwtoews
Copy link
Contributor
@mwtoews mwtoews commented Sep 2, 2021

The utility function quote_args was in-use until gh-12413, but this functions is no longer used in NumPy. It is not used by SciPy.

An alternative proposal is to simply remove the function.

Xref gh-19781 (comment), gh-12411 (comment) and gh-12892.

@charris
Copy link
Member
charris commented Sep 2, 2021

If we keep the function, a deprecation should be issued when it is called. It dates back to 2007 and I don't see it used in pandas, scipy, astropy, etc., so it is probably safe to remove it. It probably never really existed because it is undocumented :) The problem with _nt_quote_args looks to still be unsolved.

@mattip
Copy link
Member
mattip commented Sep 2, 2021

I think we should emit a deprecation warning like

warnings.warn('"quote_args" is deprecated.
                      DeprecationWarning, stacklevel=2)

@mwtoews
Copy link
Contributor Author
mwtoews commented Sep 2, 2021

Thanks, warning added.

The function is really basic, and I doubt there would be a huge loss to anyone if it was removed. Is there a procedure to remove a public function 8000 without prior deprecation? Otherwise, it should be removed after one or two release cycles.

@mattip mattip merged commit 3f6aaa9 into numpy:main Sep 2, 2021
@mattip
Copy link
Member
mattip commented Sep 2, 2021

Thanks @mwtoews. Yes, we have a policy of 2 releases (1 year). As a matter of fact, there are a few deprecations we could remove since they were deprecated before 1.20 and we are currently looking at releasing 1.22.

@mwtoews mwtoews deleted the dep-quote_args branch September 22, 2021 00:43
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants
0