REDROOM
PHP 8.2.30
Path:
Logout
Edit File
Size: 1.49 KB
Close
/proc/thread-self/root/opt/cloudlinux/venv/lib64/python3.11/site-packages/flake8_polyfill/stdin.py
Text
Base64
"""Monkey-patching for pep8 and pycodestyle.""" try: import pep8 except ImportError: pep8 = None try: import pycodestyle except ImportError: pycodestyle = None from flake8_polyfill import version __all__ = ('monkey_patch',) modules = { 'pep8': [pep8], 'pycodestyle': [pycodestyle], 'all': [pep8, pycodestyle], } def monkey_patch(which): """Monkey-patch the specified module with the appropriate stdin. On Flake8 2.5 and lower, Flake8 would would monkey-patch ``pep8.stdin_get_value`` for everyone. This avoided problems where stdin might be exhausted. On Flake8 2.6, Flake8 stopped patching ``pep8`` and started monkey-patching ``pycodestyle.stdin_get_value``. On Flake8 3.x, Flake8 has no need to monkey patch either ``pep8`` or ``pycodestyle``. This function accepts three parameters: - pep8 - pycodestyle - all "all" is a special value that will monkey-patch both "pep8" and "pycodestyle". :param str which: The name of the module to patch. :returns: Nothing. :rtype: NoneType """ if (2, 0) <= version.version_info < (3, 0): from flake8.engine import pep8 as _pep8 stdin_get_value = _pep8.stdin_get_value elif (3, 0) <= version.version_info < (4, 0): from flake8 import utils stdin_get_value = utils.stdin_get_value for module in modules[which]: if module is None: continue module.stdin_get_value = stdin_get_value
Save
Close
Exit & Reset
Text mode: syntax highlighting auto-detects file type.
Directory Contents
Dirs: 1 × Files: 4
Delete Selected
Select All
Select None
Sort:
Name
Size
Modified
Enable drag-to-move
Name
Size
Perms
Modified
Actions
__pycache__
DIR
-
drwxr-xr-x
2026-02-06 08:01:08
Edit
Download
Rename
Chmod
Change Date
Delete
OK
Cancel
recursive
OK
Cancel
recursive
OK
Cancel
options.py
3.42 KB
lrw-r--r--
2026-01-20 13:01:48
Edit
Download
Rename
Chmod
Change Date
Delete
OK
Cancel
recursive
OK
Cancel
recursive
OK
Cancel
stdin.py
1.49 KB
lrw-r--r--
2026-01-20 13:01:48
Edit
Download
Rename
Chmod
Change Date
Delete
OK
Cancel
recursive
OK
Cancel
recursive
OK
Cancel
version.py
249 B
lrw-r--r--
2026-01-20 13:01:48
Edit
Download
Rename
Chmod
Change Date
Delete
OK
Cancel
recursive
OK
Cancel
recursive
OK
Cancel
__init__.py
150 B
lrw-r--r--
2026-01-20 13:01:48
Edit
Download
Rename
Chmod
Change Date
Delete
OK
Cancel
recursive
OK
Cancel
recursive
OK
Cancel
Zip Selected
If ZipArchive is unavailable, a
.tar
will be created (no compression).