logging.LogRecord¶
-
class
logging.LogRecord(name, level, pathname, lineno, msg, args, exc_info, func=None)[source]¶ A LogRecord instance represents an event being logged.
LogRecord instances are created every time something is logged. They contain all the information pertinent to the event being logged. The main information passed in is in msg and args, which are combined using str(msg) % args to create the message field of the record. The record also includes information such as when the record was created, the source line where the logging call was made, and any exception information to be logged.
Methods¶
__format__ |
default object formatter |
__init__(name, level, pathname, lineno, msg, ...) |
Initialize a logging record with interesting information. |
__new__((S, ...) |
|
__reduce__ |
helper for pickle |
__reduce_ex__ |
helper for pickle |
__sizeof__(() -> int) |
size of object in memory, in bytes |
__str__() |
|
__subclasshook__ |
Abstract classes can override this to customize issubclass(). |
getMessage() |
Return the message for this LogRecord. |