mirror of
https://github.com/python/cpython.git
synced 2025-11-25 04:34:37 +00:00
gh-112645: remove deprecation warning for use of onerror in shutil.rmtree (#112659)
This commit is contained in:
parent
162d3d428a
commit
97857ac058
4 changed files with 9 additions and 19 deletions
|
|
@ -721,11 +721,6 @@ def rmtree(path, ignore_errors=False, onerror=None, *, onexc=None, dir_fd=None):
|
|||
If both onerror and onexc are set, onerror is ignored and onexc is used.
|
||||
"""
|
||||
|
||||
if onerror is not None:
|
||||
import warnings
|
||||
warnings.warn("onerror argument is deprecated, use onexc instead",
|
||||
DeprecationWarning, stacklevel=2)
|
||||
|
||||
sys.audit("shutil.rmtree", path, dir_fd)
|
||||
if ignore_errors:
|
||||
def onexc(*args):
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue