AutoArchive._infrastructure.utils

Common helpers.

Sub-Packages

Modules

constants

class AutoArchive._infrastructure.utils.constants.Constants[source]

Bases: object

Defines various “global” constants.

DEBUG = None

Debugging support.

error_handling

class AutoArchive._infrastructure.utils.error_handling.ErrorHandling[source]

Bases: object

classmethod fatalExit(msg, appName=None)[source]

Prints msg to standard error and exits with exit code 2.

classmethod printError(msg, appName=None)[source]

Prints msg as an error to standard error.

classmethod printWarning(msg, appName=None)[source]

Prints msg as a warning to standard error.

os_paths

OsPaths.

class AutoArchive._infrastructure.utils.os_paths.OsPaths[source]

Bases: object

Provides OS-specific paths

classmethod getSystemConfigDir() str[source]
classmethod getUserConfigDir() str[source]
classmethod getUserDataDir() str[source]

utils

class AutoArchive._infrastructure.utils.utils.Utils[source]

Bases: object

Various utility methods.

static effectiveAccess(path, mode)[source]
static getKeysForValue(value: __V, mapping: Mapping[__K, __V]) Iterable[__K][source]

Returns keys of mapping which has value equal to value

static isWindows()[source]
static uniq(decorated)[source]

Decorator that filters out duplicate elements from an iterable returned by decorated function.