Skip to content
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

Corrected Misspelled constant _IGNORED_ERRORS #29686

Closed
wants to merge 1 commit into from
Closed
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Corrected Misspelled constant _IGNORED_ERRORS
Corrected Misspelled _IGNORED_ERROS in Lib/pathlib.py to _IGNORED_ERRORS 
issue : https://bugs.python.org/issue45853
  • Loading branch information
badal8381 committed Nov 21, 2021
commit 9b36d2e74c369b8a405ab90a148f78e5c4693965
4 changes: 2 additions & 2 deletions Lib/pathlib.py
Original file line number Diff line number Diff line change
Expand Up @@ -28,15 +28,15 @@
_WINERROR_CANT_RESOLVE_FILENAME = 1921 # broken symlink pointing to itself

# EBADF - guard against macOS `stat` throwing EBADF
_IGNORED_ERROS = (ENOENT, ENOTDIR, EBADF, ELOOP)
_IGNORED_ERRORS = (ENOENT, ENOTDIR, EBADF, ELOOP)

_IGNORED_WINERRORS = (
_WINERROR_NOT_READY,
_WINERROR_INVALID_NAME,
_WINERROR_CANT_RESOLVE_FILENAME)

def _ignore_error(exception):
return (getattr(exception, 'errno', None) in _IGNORED_ERROS or
return (getattr(exception, 'errno', None) in _IGNORED_ERRORS or
getattr(exception, 'winerror', None) in _IGNORED_WINERRORS)


Expand Down