Manuel Jacob <me@manueljacob.de> [Wed, 01 Jun 2022 01:30:48 +0200] rev 49320
commit: remove special handling of IOError (actually dead code)
In the past, IOError was used to mark a file as removed. The differentiation
between OSError and IOError in this place was introduced in e553a425751d, to
avoid that “normal” OSErrors / IOErrors accidentally mark files as removed.
This weird internal API was removed in 650b5b6e75ed. It seems like that
changeset should have removed the differentiation, at least I don’t see any
reason for keeping it.
On Python 3, OSError and IOError are aliased. Therefore the removed code was
actually dead.
Manuel Jacob <me@manueljacob.de> [Wed, 01 Jun 2022 02:21:41 +0200] rev 49319
py3: catch specific OSError subclasses instead of checking errno
On Python 3, the "not a directory" error is mapped to ENOTDIR instead of
EINVAL. Therefore, catching the NotADirectoryError subclass is sufficient.
Manuel Jacob <me@manueljacob.de> [Wed, 01 Jun 2022 00:47:25 +0200] rev 49318
py3: catch specific OSError subclasses instead of checking errno
Contrary to the previous changesets in this series, this covers cases where
errno was checked for multiple values.
EACCES -> PermissionError
ENOENT -> FileNotFoundError
ENOTDIR -> NotADirectoryError
EISDIR -> IsADirectoryError
Manuel Jacob <me@manueljacob.de> [Tue, 31 May 2022 23:45:33 +0200] rev 49317
py3: catch ProcessLookupError instead of checking errno == ESRCH
Manuel Jacob <me@manueljacob.de> [Tue, 31 May 2022 23:41:15 +0200] rev 49316
py3: catch PermissionError instead of checking errno == EPERM
Manuel Jacob <me@manueljacob.de> [Tue, 31 May 2022 23:38:51 +0200] rev 49315
py3: catch PermissionError instead of checking errno == EACCES
Manuel Jacob <me@manueljacob.de> [Tue, 31 May 2022 22:50:01 +0200] rev 49314
py3: catch FileNotFoundError instead of checking errno == ENOENT
Manuel Jacob <me@manueljacob.de> [Tue, 31 May 2022 21:16:17 +0200] rev 49313
py3: catch FileExistsError instead of checking errno == EEXIST
Manuel Jacob <me@manueljacob.de> [Tue, 31 May 2022 16:54:58 +0200] rev 49312
py3: catch BrokenPipeError instead of checking errno == EPIPE
Manuel Jacob <me@manueljacob.de> [Tue, 31 May 2022 04:18:22 +0200] rev 49311
py3: catch ChildProcessError instead of checking errno == ECHILD
Manuel Jacob <me@manueljacob.de> [Tue, 31 May 2022 04:11:34 +0200] rev 49310
py3: remove retry on EINTR errno
Since the implementation of PEP 475 (Python 3.5), Python retries system calls
failing with EINTR. Therefore we don’t need the logic that retries it in Python
code.
Manuel Jacob <me@manueljacob.de> [Tue, 31 May 2022 03:39:42 +0200] rev 49309
py3: stop catching TypeError that was raised on Python 2