[New-bugs-announce] [issue44347] Unclear documentation for shutil.copytree()

Tilman Vogel report at bugs.python.org
Tue Jun 8 05:17:12 EDT 2021


New submission from Tilman Vogel <tilman.vogel at gmail.com>:

I donot understand this sentence:

"dirs_exist_ok dictates whether to raise an exception in case dst or any 
missing parent directory already exists."

How can a "missing parent directory already exist"?

My understanding would be that an existing `dst` would be OK (and copied into) but missing parent directories are just the ones above `dst` that also don't exist. 

Until 3.7, missing parent directories were documented to be auto-created (`mkdir -p`-style) according to the documentation ("The destination directory, named by dst, must not already exist; it will be created as well as missing parent directories."). Was this feature really removed? If not, then this part was accidentally (?) dropped from documentation?

What am I missing? I think, the documentation should be amended to make that clear.

----------
assignee: docs at python
components: Documentation
messages: 395315
nosy: docs at python, tilman.vogel
priority: normal
severity: normal
status: open
title: Unclear documentation for shutil.copytree()
type: enhancement
versions: Python 3.10, Python 3.8, Python 3.9

_______________________________________
Python tracker <report at bugs.python.org>
<https://bugs.python.org/issue44347>
_______________________________________


More information about the New-bugs-announce mailing list