This issue tracker has been migrated to GitHub, and is currently read-only.
For more information, see the GitHub FAQs in the Python's Developer Guide.

Author vstinner
Recipients barry, eryksun, nanjekyejoannah, pitrou, vstinner
Date 2019-09-12.09:50:46
SpamBayes Score -1.0
Marked as misclassified Yes
Message-id <1568281846.37.0.13968232377.issue32847@roundup.psfhosted.org>
In-reply-to
Content
> Python's code base never specifically handles ENOTEMPTY.

Right, so this use case looks artificial to me.


> On the other hand, in terms of basic operations on files and directories, I think implementing DirectoryNotEmptyError follows naturally from the existing set: FileNotFoundError, FileExistsError, NotADirectoryError, and IsADirectoryError.

Again, I consider that we must not add one exception per errno, since the Python errno module contains 133 error codes on Linux. Many are very rare and don't deserve to add a new symbol to the builtins module.

I suggest to close this issue.

If later someone wants to get DirectoryNotEmptyError, please open a new issue with statistics of how many 3rd party projects use ENOTEMPTY.
History
Date User Action Args
2019-09-12 09:50:46vstinnersetrecipients: + vstinner, barry, pitrou, eryksun, nanjekyejoannah
2019-09-12 09:50:46vstinnersetmessageid: <1568281846.37.0.13968232377.issue32847@roundup.psfhosted.org>
2019-09-12 09:50:46vstinnerlinkissue32847 messages
2019-09-12 09:50:46vstinnercreate