You cannot select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
juur 107221fd9e
Update cli.py to support custom loggers (#1906)
* Update cli.py to support custom loggers

Allows a config.py file (via rq worker --config) to support things like this for logfmt logging:

DICT_CONFIG = {
        "version": 1,
        "formatters": {"logfmt": {
            "()": "logfmter.Logfmter",
            "keys": ["level","when","pid"],
            "mapping": {"level":"levelname","when":"asctime","pid":"process"},
            "datefmt": "%Y-%m-%dT%H:%M:%S%z"
            }},
        "handlers": {"console": {"class": "logging.StreamHandler","formatter": "logfmt" }},
        "loggers": {
            "root": {"handlers":["console"], "level": "INFO"},
            "rq":   {"handlers":["console"], "level": "INFO", "propagate": False},
            }
        }

* added simple test and documentation for DICT_CONFIG

* further attempt to get testing right for dictConfig

* move import to correct location

* fix

* remove meaningless options.get() usage

* linting checks and added missing test config file
2 years ago
..
_includes Added anchor.js to docs 6 years ago
_layouts Add chat page (#1474) 4 years ago
chat Add chat page (#1474) 4 years ago
contrib Update linting configuration (#1915) 2 years ago
css #1733 Typography (#1734) 2 years ago
design Add docs folder. 7 years ago
docs Update cli.py to support custom loggers (#1906) 2 years ago
img Add docs folder. 7 years ago
patterns Update index.md (#1858) 2 years ago
CNAME Add docs folder. 7 years ago
_config.yml Add chat page (#1474) 4 years ago
favicon.png Add docs folder. 7 years ago
index.md Replace highlight tag in docs (#1600) 3 years ago