mirror of
https://github.com/python/cpython.git
synced 2025-08-04 17:08:35 +00:00
explicitly set UnsupportedOperation's module rather than relying on incorrect globals on startup (closes #14745)
This commit is contained in:
parent
106802547c
commit
bbf83933c5
1 changed files with 3 additions and 0 deletions
|
@ -67,6 +67,9 @@ from _io import (DEFAULT_BUFFER_SIZE, BlockingIOError, UnsupportedOperation,
|
|||
|
||||
OpenWrapper = _io.open # for compatibility with _pyio
|
||||
|
||||
# Pretend this exception was created here.
|
||||
UnsupportedOperation.__module__ = "io"
|
||||
|
||||
# for seek()
|
||||
SEEK_SET = 0
|
||||
SEEK_CUR = 1
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue