devctrl.utility.log.PackageFilter#

class PackageFilter(name='')[source]#

Bases: Filter

Allows you to enable debug logs only for certain packages

Initialize a filter.

Initialize with the name of the logger which, together with its children, will have its events allowed through the filter. If no name is specified, allow every event.

Methods

filter

Determine if the specified record is to be logged.

Attributes

DEBUG_FOR_PKG

THRESHOLD_OTHER

filter(record: LogRecord) bool[source]#

Determine if the specified record is to be logged.

Returns True if the record should be logged, or False otherwise. If deemed appropriate, the record may be modified in-place.